> ## Documentation Index
> Fetch the complete documentation index at: https://adapt.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Salesforce

> Connect Salesforce to Adapt to query and analyze your CRM data

Connect Salesforce to let Adapt query your CRM records (accounts, contacts, opportunities) and analyze your sales pipeline.

## Set up credentials

You create an OAuth app in Salesforce Setup, then copy its consumer key and consumer secret. As of the Spring '26 release, Salesforce recommends External Client Apps over Connected Apps, and creating new Connected Apps may require contacting Salesforce Support.

<Steps>
  <Step title="Open Setup">
    Log in to your Salesforce org. Click the gear icon and select **Setup**.
  </Step>

  <Step title="Open App Manager">
    In the **Quick Find** box, type `App Manager` and select **App Manager**.
  </Step>

  <Step title="Create a new app">
    Click **New Connected App**. If prompted, choose to create an **External
    Client App** instead, which is the option Salesforce now recommends. Enter a
    **Connected App Name**, **API Name**, and **Contact Email**.
  </Step>

  <Step title="Enable OAuth settings">
    Select **Enable OAuth Settings**. Enter a **Callback URL** (for example,
    `https://login.salesforce.com/services/oauth2/callback`) and add the OAuth
    scopes your integration needs, such as **Manage user data via APIs (api)**
    and **Perform requests at any time (refresh\_token, offline\_access)**. Click
    **Save**.
  </Step>

  <Step title="Copy the consumer key and secret">
    After saving, open the app and go to **Manage Consumer Details** (you may be
    asked to verify your identity). Copy the **Consumer Key** and **Consumer
    Secret**. Allow a few minutes for the new app to activate before using it.
  </Step>
</Steps>

<Note>
  In Lightning Experience you can find the app again later under **Setup > App
  Manager**. Use the row dropdown and select **View**, then **Manage Consumer
  Details** to retrieve the key and secret.
</Note>

## Connect to Adapt

<Steps>
  <Step title="Open Integrations">
    In Adapt, go to **Settings > Integrations**.
  </Step>

  <Step title="Find Salesforce">
    Search for **Salesforce** and select it from the catalog.
  </Step>

  <Step title="Start the connection">
    Click **Connect** to open the connection form.
  </Step>

  <Step title="Add your credentials">
    Enter the values you gathered above, then click **Add connection**:

    | Secret Name                | Value                                |
    | -------------------------- | ------------------------------------ |
    | `SALESFORCE_CLIENT_ID`     | Your connected app's consumer key    |
    | `SALESFORCE_CLIENT_SECRET` | Your connected app's consumer secret |

    You can rename the connection and choose whether it is shared with your
    organization or kept personal to you.
  </Step>

  <Step title="Test the connection">
    Ask Adapt to list your most recent opportunities.
  </Step>
</Steps>

### Security

* Credentials are encrypted at rest with AES-256
* Grant only the OAuth scopes your use case needs, such as `api` and `refresh_token`
* Use a dedicated integration user with least-privilege access where possible
* Never share the consumer key or secret publicly or commit them to source control

## Capabilities

Adapt can query CRM objects such as accounts, contacts, and opportunities, and analyze your pipeline. Use it to surface stalled deals, summarize account activity, and report on pipeline health.

### Examples

Pipeline summary

```
Summarize my open Salesforce opportunities by stage and total amount.
```

Account lookup

```
Show me the contacts and recent activity for the Acme Corp account in Salesforce.
```

Deal review

```
Which Salesforce opportunities closing this quarter have had no activity in the last 14 days?
```

Forecast analysis

```
Compare won versus lost Salesforce opportunities over the last two quarters by amount.
```
