Skip to main content
This is the standard user authentication flow delivered by the Onboard and Authenticate User with Social Account Process Process. An anonymous user authenticates into to Storefront Gateway using an already-associated social account. At the end of this flow, the user will be authenticated to Storefront Gateway, dependent on a successful response from the chosen social provider.

Initial Request

Your client calls the Process Start API to initialize the Process:

Response

The Process responds with a request to specify a social provider. The response includes an array of available providers:

Next Request: Choose Provider

Your client calls the Process Step API, and passes the selected provider to Process.
Google is the provider in this example, but the steps are the same regardless of the chosen provider.
This method is useful when social provider badges are displayed on a UI (for end users to click and immediately begin the onboarding or authentication Process for that specific provider).

Response: Redirect URL

The Process responds with a redirect for the client to follow:

Next Step: Redirect to Social Provider

Your client must then redirect to the location provided in the requestUrl parameter. This URL redirects to the selected social provider (in this example, Google), and includes the request for certain “scopes” or user resources as defined by OAuth 2.0 authorization framework. The user then authenticates with the provider, and grants the provider permission to share basic information (their name, email address, etc) with Storefront Gateway. Redirect back to Storefront Gateway The social provider then redirects back to Storefront Gateway and makes this call to provide Storefront Gateway with an authorization code:
Storefront Gateway independently redeems the authorization code with the social provider through a secure backend call.

Process Complete

Storefront Gateway then authenticates and Storefront Gateway then redirects back to the client application, and returns a 200 HTTP status:
In some cases, the user already has an open session with the social provider in the same browser, so they will not be prompted to sign-in with the provider. From the user’s perspective, they simply click the “Sign In with {Social Provider}” badge and, within a few seconds, they are automatically redirected to the authenticated view of your client application. Parent topic:Onboard and Authenticate User with Social Account Process