Getting Salesforce Client_ID and Client_Secret Values
When you configure the Coveo Salesforce security provider and Salesforce source, you must know the Client_ID and Client_Secret token values for the Salesforce organization that you want to index.
To get the Salesforce Client_ID and Client_Secret values
-
Using and administrator account, log into the Salesforce organization that you want to index.
-
On the User Menu, select Setup.
-
In the navigation menu on the left, under App Setup, expand Create, and then click Apps.
-
In the Apps page, in the Connected Application section, click New to create a new application that will use OAuth2 to gain access to the organization.
-
In the New Connected App page:
-
In the Basic Information section:
-
Enter meaningful names in the Connected App Name and API Name boxes.
-
Enter your email in the Contact Email box so that you can receive messages from this application.
-
-
In the API (Enable OAuth Settings) section:
-
Select the Enable OAuth Settings check box.
-
In the Callback URL box, since a callback URL will not be used for this application, enter a dummy but valid secured URL (https://) such as https://login.salesforce.com/services/oauth2/callback.
-
In the Available OAuth Scopes list, select the following items:
-
Access and manage your data (api)
-
Full access (full)
-
Perform requests on your behalf at any time (refresh_token, offline_access)
and click Add for each so that they appear in the Selected OAuth Scopes list.
-
-
-
Click Save.
-
-
In the page that appears for your new connected app, in the API (Enable OAuth Settings) section:
-
Copy the Consumer Key value and paste it in a secure reference document of your choice.
The Consumer Key is the client_id.
-
Next to Consumer secret, click Click to reveal, copy the value that appears, and then paste it in your secure reference document.
The Consumer secret is the client_secret.
-
Save your reference document.
Note: You can always come back to this Salesforce page (Setup > App Setup > Create > Apps, and clicking the application name in the Connected Apps list).
-
-
Create a Salesforce permission set dedicated to the Coveo crawler and assign it to your dedicated app and user:
-
In the Setup page, select Manage Users > Permission Sets.
-
In the Permission Sets page, click New.
-
In the Create page, in the Label and API Name boxes, enter significant names, and then click Save.
-
In the page for the new permission set:
-
Click Manage Assignments, and then add the dedicated user you created earlier for the Coveo crawler (see Creating a Dedicated Salesforce Crawling Account).
-
In the Apps section, click Assigned Connected Apps.
-
In the Assigned Connected Apps section, click Edit, add the connected app you just created to the Enabled Connected Apps list, and then click Save.
-
-
What's Next?
Create an ObjectsToGet Configuration file (see Salesforce ObjectsToGet Configuration File).