Skip to main content

System Variables

System variables are a special class of predefined variables, which are already defined by the system, and values are assigned by the system it self. These variables are read-only. They contain values that cannot or should not be changed by the user.

These variables are used to refer to common information like the email id of the logged in user, or the email id of the app admin, the current date, and so on.

Current Scope Variables#

VariableReturns
currentUserCurrent logged-in user object
currentOrgCurrent logged-in organization object

Example#

The following snippet print the current user properties.

log currentUser.name;
log currentUser.email;
log currentUser.id;
log currentUser;

The following snippet print the current org properties.

log currentOrg.name;
log currentOrg;