Contains information about a website user.
The current user is available as a global user
variable throughout the CMS. It is also available in most email and SMS templates and in fulfillment templates where it represents the user that created the order being fulfilled.
Returns the unique ID of the user.
Returns true
if the user is anonymous, otherwise returns false
.
The reverse of user.is_anonymous
.
Note that this returns true
if user is logged in as a guest user.
Returns true
if user is a guest user, otherwise returns false
.
Returns true
if the user is an admin, otherwise returns false
.
Returns the user's external_id, or nil
if external_id is not set.
Deprecated: use user.external_id
instead.