Version 2025-07 is the last API version to support React-based UI components. Later versions use web components, native UI elements with built-in accessibility, better performance, and consistent styling with Shopify's design system. Check out the migration guide to upgrade your extension.
Authentication State API
The Authentication State API provides the buyer's current authentication status in customer accounts. Use it to conditionally render content based on whether the buyer is fully signed in or viewing through a tokenized link.
Anchor to Use casesUse cases
- Conditional content rendering: Show different UI depending on whether the buyer is fully authenticated or viewing the page through a pre-authenticated link.
- Prompt for sign-in: Detect when a buyer is pre-authenticated and display a message encouraging them to sign in for a richer experience.
- Protect sensitive data: Only display detailed customer information when the buyer is fully authenticated.
Supported targets
- customer-account.
order-status. announcement. render - customer-account.
order-status. block. render - customer-account.
order-status. cart-line-item. render-after - customer-account.
order-status. cart-line-list. render-after - customer-account.
order-status. customer-information. render-after - customer-account.
order-status. fulfillment-details. render-after - customer-account.
order-status. payment-details. render-after - customer-account.
order-status. return-details. render-after - customer-account.
order-status. unfulfilled-items. render-after - customer-account.
order. page. render
Supported targets
- customer-account.
order-status. announcement. render - customer-account.
order-status. block. render - customer-account.
order-status. cart-line-item. render-after - customer-account.
order-status. cart-line-list. render-after - customer-account.
order-status. customer-information. render-after - customer-account.
order-status. fulfillment-details. render-after - customer-account.
order-status. payment-details. render-after - customer-account.
order-status. return-details. render-after - customer-account.
order-status. unfulfilled-items. render-after - customer-account.
order. page. render
Anchor to PropertiesProperties
The Authentication State API object provides the buyer's authentication state. Access the following properties on the API object to read authentication data.
- Anchor to authenticationStateauthenticationStateauthenticationStateStatefulRemoteSubscribable<AuthenticationState>StatefulRemoteSubscribable<AuthenticationState>requiredrequired
The buyer's current authentication state on the Order status page. The value is either
(the buyer is logged in) or(the buyer is viewing through a tokenized link).
AuthenticationState
The buyer’s authentication state on the **Order status** page: - `'fully_authenticated'`: The buyer has logged in to their customer account. - `'pre_authenticated'`: The buyer accessed the page through a tokenized link without logging in.
'fully_authenticated' | 'pre_authenticated'Anchor to Best practicesBest practices
- Gate sensitive actions behind full authentication: Use the authentication state to restrict actions like editing order details to fully authenticated buyers.
- Provide fallback content for pre-authenticated buyers: Pre-authenticated buyers access the page through a tokenized link. Show limited information and offer a sign-in prompt for additional actions.
Anchor to LimitationsLimitations
- The authentication state is read-only. You can't change the buyer's authentication level directly — use the Require Login API to prompt them to log in.
- Pre-authenticated buyers may have limited access to protected customer data, which can cause some API properties to return
undefined.