> For the complete documentation index, see [llms.txt](https://docs.rillet.com/EjmEP4KZ9BVp9j2ho4Mh/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.rillet.com/EjmEP4KZ9BVp9j2ho4Mh/integrations/crm/salesforce-integration.md).

# Salesforce Integration

Connect **Salesforce** to **Rillet** to automate accounting from a Closed Won opportunity through to contracts, syncing Accounts, Products, and Opportunities in Salesforce into Customers, Products, and Contracts in Rillet. Before starting, make sure you have access to both accounts.

### Connect Salesforce to Rillet

You can access the Salesforce integration using either of these methods:

| Method                    | How to Access                                                                                                            |
| ------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
| **Launchpad**             | Access the Salesforce integration through the **Browse Integration** section from the Launchpad.                         |
| **Organization Settings** | Click your **company logo** in the lower-left corner of the screen, then go to **Organization Settings > Integrations**. |

Once you reach the integrations page, continue with the steps in **Complete the Salesforce Connection** below.

### Complete the Salesforce Connection

Follow these steps once you reach the integrations page:

1. Select **Salesforce > Not Connected** under **CRM**.

   <figure><img src="https://612265232-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNpXFVFZpTQck3vIrjmHB%2Fuploads%2F1N4OHLViARDQWlk5535t%2Fimage.png?alt=media&amp;token=f36ba788-897a-464f-b340-14b4c0a423eb" alt=""><figcaption></figcaption></figure>
2. Log in with your Salesforce credentials when redirected to the Salesforce login page.<br>

   <figure><img src="https://612265232-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNpXFVFZpTQck3vIrjmHB%2Fuploads%2FWwhzAtGxFQvctundC0f2%2Fimage.png?alt=media&amp;token=4610caf1-aad3-4c3e-86bd-8e3930bd1d36" alt=""><figcaption></figcaption></figure>
3. Enter the required information for **Synchronization Settings**:
   * **Sync Data from:** Specify the date you want to start syncing opportunities. All opportunities with a close date on or after this date will be synced automatically into Rillet.
   * **Default Product for imported Opportunities:** Select a product that will be the default if you do not use opportunity line items. This product is just a fallback for opportunities without line items.
   * **(Optional):** The start date of the contract term, in **Custom Salesforce field name for opportunity start date**. This field is not standard in Salesforce, but adding it can automate contract setup in Rillet.
   * **(Optional):** The end date of the contract term, in **Custom Salesforce field name for opportunity end date**.
4. Click **Save** to complete the integration setup.<br>

   <figure><img src="https://612265232-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNpXFVFZpTQck3vIrjmHB%2Fuploads%2FbtugsdUMRkCH8lyi4nQT%2Fimage.png?alt=media&amp;token=2f734998-155e-4721-b0a0-cd3403673267" alt=""><figcaption></figcaption></figure>

{% hint style="info" %} <mark style="color:$info;">**Note:**</mark>

You can locate these custom field names in Salesforce by navigating to **Set Up > Objects & Fields > Object Manager > Opportunity > Fields and Relationships**.
{% endhint %}

Once configured, the integration begins syncing Salesforce data into Rillet according to these settings.

### Sync Salesforce Accounts, Products, and Opportunities

The integration maps Salesforce records to Rillet as follows:

| Salesforce             | Rillet                                                               |
| ---------------------- | -------------------------------------------------------------------- |
| Accounts               | [**Customers**](https://app.rillet.io/accounts-receivable/customers) |
| Products               | [**Products**](https://app.rillet.io/accounts-receivable/products)   |
| Opportunities          | [**Contracts**](https://app.rillet.io/accounts-receivable/contracts) |
| Opportunity Line Items | Contract Line Items                                                  |

Customers and Products are only created in Rillet when associated with a Closed Won opportunity, and Salesforce opportunities sync into Rillet automatically once they reach that status.

### Manage Salesforce Contracts in Rillet

Synced opportunities appear as **Contracts to be Reviewed** in the **Workflow Snapshot** section of your Rillet launchpad.<br>

<figure><img src="https://612265232-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNpXFVFZpTQck3vIrjmHB%2Fuploads%2FMA1PLerrVwUxeJqShx0J%2Fimage.png?alt=media&amp;token=8c596e8d-94ce-45c7-b704-5c1585e611ec" alt=""><figcaption></figcaption></figure>

Select **Contracts to be Reviewed** to open the list of contracts awaiting review, each labeled **Pending Review (Salesforce)** in the far right column.

<div align="left"><figure><img src="https://612265232-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNpXFVFZpTQck3vIrjmHB%2Fuploads%2FAQuSJIofcDrmMPUmtC7J%2Fimage.png?alt=media&amp;token=f0c8f5b5-b764-4e59-86b1-c4d241f9da89" alt=""><figcaption></figcaption></figure></div>

Open a contract to review and confirm it using the same steps as **Adding Contracts to Rillet**, since Salesforce data auto-fills the contract fields; repeat this process for each contract synced from Salesforce to ensure the imported information is accurate. Once confirmed, the contract no longer displays the **Pending Review** label.<br>

<div align="left"><figure><img src="https://612265232-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNpXFVFZpTQck3vIrjmHB%2Fuploads%2FvrEWRgGV1XyCyg3UQuQZ%2Fimage.png?alt=media&amp;token=ee955667-e8e5-4817-976a-217ae7126198" alt=""><figcaption></figcaption></figure></div>

| Sync Behavior               | Details                                                                                     |
| --------------------------- | ------------------------------------------------------------------------------------------- |
| Sync Frequency              | Runs every 30 minutes, importing new Closed Won opportunities.                              |
| Pending Review State        | Does not impact metrics, journal entries, or invoicing until reviewed.                      |
| Editing After Sync          | Start dates, end dates, and other details can be changed while the contract is in review.   |
| Avoiding Duplicate Accounts | Provide a list of Salesforce account names and IDs to prevent duplicate accounts in Rillet. |

Once configured, Salesforce opportunities flow automatically into Rillet as reviewable contracts, keeping your CRM and accounting data aligned.

### Frequently Asked Questions (FAQ)

<details>

<summary>What are the common objects that are synced in?</summary>

Accounts, Products, Opportunities, Opportunity Line Items.

</details>

<details>

<summary>Can I use anything besides Opportunities?</summary>

Yes, you can also use Orders to sync contracts into Rillet. Talk to your Rillet team member to enable this flow.

</details>

<details>

<summary>Why are my Salesforce orders or opportunities not syncing in?</summary>

A few things could prevent an object from syncing: confirm the Close Date of the object is on or after the sync start date in your Salesforce Settings, confirm the API names of the start date and end date are in the correct syntax, and confirm the object is in a Closed Won state.

</details>

### See Also

To learn more about the Salesforce integration in **Rillet**, review these articles:

* [**Salesforce Bi-Directional Sync: Invoices, Contracts, and Customers**](/EjmEP4KZ9BVp9j2ho4Mh/integrations/crm/salesforce-integration/salesforce-bi-directional-sync-invoices-contracts-and-customers.md)
* [**Install the Salesforce Managed Package**](/EjmEP4KZ9BVp9j2ho4Mh/integrations/crm/salesforce-integration/salesforce-managed-package-integration-overview/install-the-salesforce-managed-package.md)
* [**HubSpot**](/EjmEP4KZ9BVp9j2ho4Mh/integrations/crm/hubspot.md)
* [**Add a Contract**](/EjmEP4KZ9BVp9j2ho4Mh/accounts-receivable/contracts/add-a-contract.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.rillet.com/EjmEP4KZ9BVp9j2ho4Mh/integrations/crm/salesforce-integration.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
