SalesForce Authentication

Enjoy uninterrupted connectivity with your SalesForce database

SalesForce integration can now be found with all of your API integrations on the API dashboard!

It is mandatory to set up a SalesForce Connected App in order for this integration to work seamlessly. Please use our official documentation learn more about how this can be set up.

Here’s how to set it up:-

Save existing information within SalesForce Authentication Nodes

This node will be deprecated in the coming weeks, we recommend copying all the information already stored in the existing authentication nodes within your agent to a safe place before the node is removed

Once you have safely stored all of the integration information, click on the “Update SalesForce Authentication” button which will redirect you back to the API dashboard to set up the integration.

Set up Integration on the API Dashboard

Once re-directed, select the SalesForce Integration card to create your first SalesForce Integration.

If you do not have access to the integrations page on the API Dashboard, please ask your account admin or account manager to enable it for you.

You will then be prompted to enter your integration details, this is where you can use your previously saved details as follows:-

Name: Appropriately name your integration, if you have multiple environments you can name them as follows: Production Env, UAT Env. You will later be prompted to select the integration required within the Action node.

Customer Secret: This refers to the Consumer Secret associated with the Connected app created within SalesForce.

Customer Key: This refers to the Consumer Key associated with the Connected app created within SalesForce.

Domain: This is your account's unique org-specific subdomain for Salesforce login and application URL.

When you enter your tenant domain into the SalesForce Integration Card be sure to add only the part before “my.salesforce” from the URL. For example, if the whole URL reads www.this-is-a-demo-for-you.user.my.salesforce.com in the tenant domain enter only “this-is-a-demo-for-you.user”. If you get DNS errors when trying to authorise a Connected App, it is likely that login.salesforce.com is redirecting to an incorrect location (e.g. xyz.my.salesforce.com instead of xyz.develop.my.salesforce.com), and the correct one needs to be specified as the Salesforce domain.

Once this is set up you should be able to see the integration amongst the list of your other integrations.

Using the newly added integration within AI Studio

Returning to the Action Nodes in your agent will then allow you to select among the integrations you created via the API dashboard.

This also allows you to integrate into multiple environments without adding multiple nodes.

From here, it's business as usual, use the action nodes wherever it is appropriate within your flows, selecting the right integration for each action.

Please keep in mind that the default timeout for SalesForce authentication is 10 seconds.

Having trouble with your request?

For error tracking, please have a look at Salesforce's detailed documentation.

Authentication EP: https://help.salesforce.com/s/articleView?id=sf.remoteaccess_oauth_username_password_flow.htm&type=5

Creating Oauth connected app: https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/intro_oauth_and_connected_apps.htm

Integrating with Salesforce Sandbox Environments

Please note that currently, the best means of integrating with Sandbox environments is still via Webhook.

Here’s the syntax:

Method:-

GET https://your-tenant-domain.my.salesforce.com/services/oauth2/token?

Headers:-

HTTP HeaderValue

Content-Type

application/x-www-form-urlencoded

Query Parameters:-

Query ParameterValue

grant_type

password

client_id

Your Consumer Key

client_secret

Your Consumer Secret

username

Your API user

password

Your API user's password

Response Mapping:-

Object PathParameter

access_token

$SF_ACCESS_TOKEN (parameter where you want to store the token)

Check if your password contains special characters such as a #.

If it does, please use URL encoding to change the format of your password. You can do this using Postman

E.g. instead of #42LBMDEH → %1242LBMDEH

Last updated