Step 2: Create an External Client App
Datatrax connects to your Salesforce org using a Connected App (called an External Client App in newer API versions). You create this in your own org, which gives you full control over the OAuth credentials. This step takes about five minutes.
One ECA per org.
If you plan to connect both a production org and a sandbox, repeat this
step in each org separately. Credentials from a production ECA will not
work for a sandbox org, and vice versa.
Open External Client Apps in Setup
- In Salesforce, click the gear icon → Setup.
- In the Quick Find box, type External Client Apps and select it.
- Click New External Client App.
Don't see External Client Apps?
Your org may use the older "Connected Apps" UI. Search for
App Manager instead and click New Connected App.
The fields are the same.
Fill in the app details
Complete the form fields below exactly as shown.
External Client App Name
Any name you like — e.g.
Datatrax.
This is the internal API name; spaces will be replaced with underscores.
Label
The display name users see. Use
Datatrax or
Datatrax Integration.
Description
Optional. E.g. "OAuth app for Datatrax data loader integration."
Distribution State
Local — this app is only for your org, not shared.
Enable OAuth settings
- Check Enable OAuth Settings. The OAuth configuration panel will expand.
-
In the Callback URL field enter the URL below (same for production and sandbox):
https://www.getdatatrax.com/auth/salesforce/callback
-
Under Selected OAuth Scopes, add the following two scopes
(use the arrows or double-click to move them to the selected list):
- Manage user data via APIs (api)
- Perform requests at any time (refresh_token, offline_access)
-
Scroll down to the Security section. Check both:
- Require secret for Web Server flow
- Require secret for Refresh Token Flow
- Leave all other settings at their defaults and click Create.
Allow 2–10 minutes after saving.
Salesforce takes a few minutes to activate a new External Client App.
If you get an "invalid_client" error when connecting, wait a few minutes and try again.
Copy your Consumer Key and Consumer Secret
- After clicking Create, you're on the Manage External Client Apps page. Click the Settings tab.
- Scroll down to OAuth Settings and click to expand it.
- Click on Consumer Key and Secret. Salesforce will prompt you to enter an access code that was emailed to you.
- Enter the access code and click Verify. You'll be routed to the Consumer Details page.
- Copy the Consumer Key and save it securely — you'll paste this into Datatrax in the next step.
- Copy the Consumer Secret and save it securely. You'll also paste this into Datatrax in the next step.
Keep your Consumer Secret private.
Treat it like a password. Do not commit it to source control, share it in Slack,
or store it in a spreadsheet. If it is ever exposed, return to the External Client App Settings,
scroll to OAuth Settings, and rotate it.