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

# Sync Salesforce objects

> How to make Treble see the changes you make in Salesforce. It's the most forgotten step and the most common cause of errors that seem to have no explanation.

Treble keeps a **copy of the structure** of your Salesforce objects and fields: which objects exist, which fields each one has, which values each picklist accepts and which ones are required.

That copy doesn't update on its own. It's updated when you run the **object sync**.

<Warning>
  Every time you change something in Salesforce that affects the structure, run the sync. If you don't, Treble keeps working with the previous version and the errors that appear **usually have no obvious relation to the change you made**.
</Warning>

<div class="hr" />

## When you need to sync

<AccordionGroup>
  <Accordion title="You created or modified a field">
    A new field doesn't appear in Treble's blocks until you sync.
  </Accordion>

  <Accordion title="You changed whether a field is required or gave it a default value">
    Treble decides which fields to send when creating a record based on this information. If it's outdated, it may send fields that are no longer needed, or omit others that now are.
  </Accordion>

  <Accordion title="You added or modified a validation rule">
    Validation rules affect which values Salesforce accepts when creating or updating a record.
  </Accordion>

  <Accordion title="You created or changed a record type">
    Record types define which picklist values and which lookups are valid on each record.

    <a class="article-link" href="/en/docs/integrations/salesforce/features/record-types"><p>Record types</p><Icon icon="arrow-up-right-from-square" iconType="solid" /></a>
  </Accordion>

  <Accordion title="You added values to a picklist">
    Treble shows the options it had stored at the last sync.
  </Accordion>

  <Accordion title="Field names appear in another language">
    Treble shows field labels **exactly as Salesforce returns them**, and Salesforce translates them according to the language of the user the integration is connected with.

    If you want to see them in English instead of Spanish (or the other way around), you need to change that user's language in Salesforce and sync again. It's not a Treble setting.
  </Accordion>

  <Accordion title="Treble let you know it released an improvement">
    Some integration improvements only become visible after syncing.
  </Accordion>
</AccordionGroup>

<div class="hr" />

## How to sync

<Steps>
  <Step title="Open any conversation">
    Go to your Treble platform and open any conversation flow. **It doesn't matter which one**: the sync applies to the whole account, not to the flow you're in.
  </Step>

  <Step title="Click the gear in the top bar">
    Inside the conversation builder, in the top-left bar, click the gear icon ⚙.

    <img src="https://mintcdn.com/trebleai/n_48dzI5l_tB6XfZ/images/salesforce-object-sync-1.png?fit=max&auto=format&n=n_48dzI5l_tB6XfZ&q=85&s=b1523474010de0016649b5466e4e6800" alt="The gear icon in the top bar of the conversation builder" className="mx-auto" width="3024" height="1712" data-path="images/salesforce-object-sync-1.png" />

    <Info>
      It's the same gear for all flows. If you don't see it, confirm that you're inside the conversation builder and not in the campaign list.
    </Info>
  </Step>

  <Step title="Click Sync data">
    The **Settings** panel opens. At the very bottom is the **CRM object block: data sync** card, with the **Sync data** button.

    <img src="https://mintcdn.com/trebleai/n_48dzI5l_tB6XfZ/images/salesforce-object-sync-2.png?fit=max&auto=format&n=n_48dzI5l_tB6XfZ&q=85&s=a444549598a4962df3521ecd49333a17" alt="The settings panel with the data sync card" className="mx-auto" width="3024" height="1710" data-path="images/salesforce-object-sync-2.png" />
  </Step>

  <Step title="Wait for it to finish">
    While it runs, the button shows a loading indicator. Depending on the number of objects and fields in your org, it can take anywhere from a few seconds to a few minutes.

    <Check>
      Below the button, **Last sync** shows the date, time and status. When it says **Completed**, Treble's blocks are already showing the new structure.
    </Check>

    <Info>
      That "last sync" line is the fastest way to resolve an "I already synced": if the date is old, it wasn't run; if it's recent and the problem persists, the issue is something else.
    </Info>
  </Step>
</Steps>

<Note>
  **There are three different syncs** and they're easily confused:

  | Sync | What it moves | When it runs |
  | - | - | - |
  | **Initial contact sync** | Your Salesforce records into Treble | Once, when connecting the integration |
  | **Periodic contact sync** | Records created, modified or deleted since the last pass | On its own, every \~30 minutes. You don't need to do anything |
  | **Object sync** (this page) | The **structure**: objects, fields, picklists, record types | Manually, when you run it |

  If someone tells you "I already synced" but the problem persists, it's worth confirming **which** of the three.

  The quick rule: if a **contact** is missing, it's about the first two and is checked in the [Sales view](/en/docs/integrations/salesforce/features/sales-view). If a **field** or a picklist option is missing, it's this one.
</Note>

<div class="hr" />

## How to tell the problem is a missing sync

These signs usually point to an outdated structure:

| What you see | What to check |
| - | - |
| A field you created in Salesforce doesn't appear in Treble's property list | Sync |
| Treble sends a value to a picklist and Salesforce rejects it, even though the value exists | Sync, and check the record's record type |
| A new required field makes record creation fail | Sync |
| You changed a setting in Treble and "nothing happened" | Almost everything is read at sync time, not in real time |

<Tip>
  **Practical recommendation:** make syncing part of your process. Every time your Salesforce team makes a structural change, have the person who manages Treble run the sync as the next step. It takes less than a minute and avoids long diagnoses.
</Tip>

<div class="hr" />

## Next steps

<CardGroup cols={2}>
  <Card title="Record types" icon="layer-group" href="/en/docs/integrations/salesforce/features/record-types">
    Why a wrong record type produces errors on fields that seem unrelated.
  </Card>

  <Card title="Advanced settings" icon="sliders" href="/en/docs/integrations/salesforce/features/advanced-settings">
    What can be customized and what limits it has.
  </Card>
</CardGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.