Skill
Write code snippet that gets the session user details:
Solution
String userId = UserInfo.getUserId();
String userName = UserInfo.getName();
String userEmail = UserInfo.getUserEmail();
String profileId = UserInfo.getProfileId();
String sessionId = UserInfo.getSessionId();
String organizationId = UserInfo.getOrganizationId();
System.debug('User Id: ' + userId);
System.debug('User Name: ' + userName);
System.debug('User Email: ' + userEmail);
System.debug('Profile Id: ' + profileId);
System.debug('Session Id: ' + sessionId);
System.debug('Organization Id (Org Id): ' + organizationId);
Video
Video does not exists.