Create an External Client App for the OAuth 2.0 Client Credentials Flow
Before you implement the client credentials flow, configure these settings and access policies for your external client app.
- From Setup, in the Quick Find box, enter
External Client Apps, and then select Settings under External Client Apps. - Turn on
Allow creation of connected appsif it’s turned off. - Click New Connected App.
- Enter the basic information.
- Enter the name of your connected app.
- Keep the default API name, which is automatically filled based on the connected app name.
- Enter your email address.
- Under API (Enable OAuth Settings), select Enable OAuth Settings.
- If the Callback URL isn’t auto-populated, enter a URL where Salesforce can send OAuth2 responses. For example,
https://login.salesforce.com/services/oauth2/success. - Add the Manage user data via APIs (api) scope to the Selected OAuth Scopes list.
- Select Enable Client Credentials Flow.
- Read the information about the risks and click the warning.
- Click Continue to save the new connected app.
- On the new connected app, click Manage.
- Click Edit Policies.
- Under Client Credentials Flow, for Run As, click
and select the user that you want to assign the client credentials flow to. - Save your changes.
See Also