Configure a Salesforce Connected Application to Work with SLAS
Learn how the Shopper Login and API Access Service (SLAS) can work with Salesforce as an identity provider (IDP) using OpenID Connect.
- Log in to your Salesforce org.
- From Setup, in the Quick Find box, enter
App
, and then select App Manager. - Click New Connected App.
- Enter the connected app’s name. The name must be unique within the org.
- Enter the API name used when referring to your app from a program. It defaults to a version of the name without spaces. Only letters, numbers, and underscores are allowed. If the original app name contains any other characters, edit the default name.
- Enter a contact email.
- Click Enable OAuth Settings.
- Enter the Callback URL. Example URL:
https://$SHORTCODE.api.commercecloud.salesforce.com/shopper/auth/v1/idp/callback/salesforce
- Add the following OAuth Scopes to the list:
- Access the identity URL service (id, profile, email, address, phone)
- Access unique user identifiers (openid)
- Full access (full)
- Manage user data via Web browsers (web)
- Perform requests at any time (refresh_token, offline_access)
- Click Save.
- Click Continue.
- Wait while the connected app is deployed.
- For Consumer Secret, click Manage Consumer Details.
- Copy the Consumer Key and Consumer Secret and save them in a password manager or other secure location.
Now you can create an IDP in SLAS for the Salesforce Connected app. Have the Consumer Key and Consumer Secret that you copied earlier handy.
Using the SLAS Admin UI or the SLAS Admin API, create a Salesforce IDP in SLAS. For more information about the API, see Authorization for Admin APIs and the SLAS Admin API reference.
Example request: