User
The User API lets you asynchronously retrieve information about the currently logged-in user.
The API returns a Promise, which contains user information, and the payload varies based on whether the user is logged into the Shopify admin or Shopify POS.
Anchor to Admin UserAdmin User()
Admin User()
The user API, which is available on the shopify global, asynchronously retrieves information about the user that's logged into the Shopify admin.
Anchor to Admin User-returnsReturns
Promise<AdminUser>Promise<AdminUser>
AdminUser
- accountAccess
The account access level of the logged-in user
string
Anchor to POS UserPOS User()
POS User()
The user API, which is available on the shopify global, asynchronously retrieves information about the current user logged into Shopify POS.
Anchor to POS User-returnsReturns
Promise<POSUser>Promise<POSUser>
POSUser
- accountAccess
The account access level of the logged-in user
string - accountType
The user's account type.
string - email
The user's email address.
string - firstName
The user's first name.
string - id
The ID of the user's staff.
number - lastName
The user's last name.
string
Examples
await shopify.user();
Examples
User
Default
await shopify.user();
Was this page helpful?