Skip to content
Pages · How QB Bridge works

The life of a record

Applies to CustomerVendorInvoiceBill

This page follows one deal from the moment it is won to the moment it is paid. Every entity takes the same trip; only the fields differ. Click a step to see what happens and where to look when something stops.

sf | Save | A deal is won | A salesperson moves an Opportunity to Closed Won and saves it. | Where to look: the Opportunity
bridge | Flow | The Flow hands it over | A Record-Triggered Flow on Opportunity calls the QB Bridge action "QuickBooks Sync - Record Updated". | Where to look: Entities tab, Invoice, Outbound to QuickBooks card
bridge | Rules | QB Bridge decides | The Updated rule is on and its Logic Formula passes, for example Stage equals Closed Won. The record joins the work queue. | Where to look: the Outbound to QuickBooks card, Rule On
bridge | Queue | A worker picks it up | A background worker takes the waiting record a moment later. Saving it again before then updates the same queue entry instead of adding another. | Where to look: QB Bridge Health, Waiting
bridge | Build | The mapping builds the invoice | Formulas run, the account is turned into the QuickBooks customer ID, products into QuickBooks items, and the lines are collected. | If it stops here, the reason says why: "has no QuickBooks ID yet", or MISSING_REF_DATA for a name it could not find
qb | Create | QuickBooks creates it | QuickBooks creates the invoice with its lines and returns its ID. | Where to look: the QuickBooks URL on the QB Invoice
sf | Mirror | Salesforce keeps a copy | QB Bridge writes a QB Invoice record (Source = Salesforce) and stores the QuickBooks ID on the Opportunity if you chose an ID field. | Where to look: QB Invoices tab, the record's sync history
qb | Paid | The customer pays | Finance records the payment in QuickBooks. The invoice balance drops to 0. | Where to look: QuickBooks
bridge | Fetch | QB Bridge asks what changed | On its schedule (every 15 minutes or less often) QB Bridge asks QuickBooks for everything that changed since the last run. | Where to look: QB Bridge Health, Background jobs, Inbound poll
sf | Updated | Salesforce shows it is paid | The QB Invoice gets Payment Status = Paid, Paid Amount and Paid Date. If you chose Opportunity fields for them in the inbound settings, a separate Update Salesforce step copies them onto the Opportunity too. | Where to look: the QuickBooks data component on the Opportunity, the QB Invoice, or the Opportunity fields you chose

The trip out: Salesforce to QuickBooks#

Two things can start a send:

StartWhenRules apply?How it runs
Automatic: a Record-Triggered Flow calls a QB Bridge actionA record is created, updated or deletedYes: the rule for that operation must be on, and its Logic Formula (if any) must passThrough the work queue, with retries
Manual: a user clicks Sync to QuickBooks on the recordWhenever someone clicks itNo: the user sees what will be sent and confirmsStraight away, once; the user sees the result

Either way, QB Bridge decides between create and update by itself: if the record is already linked to a QuickBooks record, it updates that one; otherwise it creates one and links it. The link is the record's QB record (its SF Master Record Id holds the record), written on the first successful send. That is why sending twice never makes a duplicate.

What exactly happens when a record is sent
  1. The Flow or the action hands the record to QB Bridge.
  2. For automatic sends, QB Bridge checks the rule and its Logic Formula, then saves a work item: one per record and operation. Saving the record again while it waits updates that work item, whoever saves it.
  3. A background worker takes the waiting work items in small batches. Up to three workers can run side by side (Parallel sync workers on the Settings tab).
  4. The mapping builds the QuickBooks request: field values, fixed values and formulas, names turned into QuickBooks IDs, and line items for invoices and bills.
  5. For an update, only what changed since the last send is sent. If nothing mapped has changed, nothing is sent and the work item says "Nothing mapped has changed since the last sync; nothing was sent to QuickBooks."
  6. QB Bridge calls QuickBooks through your Named Credential QuickBooksAPI.
  7. On success it updates the QB record and writes the QuickBooks ID to your ID field (if you chose one). On failure the work item records why; it is tried again later if the error can go away by itself, such as QuickBooks being unavailable.

What a send can end as#

Every send is a work item. This is how its status moves; the same names appear in the record's sync history and on the Health tab.

flowchart TD
  W["Waiting"] -->|"QuickBooks accepted it"| S["Sent"]
  W -->|"nothing mapped has changed"| N["Nothing to send"]
  W -->|"refused"| F["Failed. An error that can pass is first tried again by itself"]
  F -->|"Retry, or the record is saved again"| R["Replaced by a later try"]
  R --> NEW["A new work item starts, Waiting"]

When both systems changed the same record#

Someone may edit a customer in QuickBooks while someone else edits the same customer in Salesforce. When QB Bridge then sends the Salesforce change, QuickBooks refuses it as out of date. QB Bridge reads the QuickBooks record, finds the fields changed on both sides, and lets the setting When both systems update the same field on the Settings tab decide:

SettingFields changed on both sides
The latest change wins (Recommended)The side changed most recently wins: the Salesforce record's last modified time against QuickBooks' last update time.
Salesforce always winsThe Salesforce values are sent.
QuickBooks always winsThe QuickBooks values are kept; those fields are left out of the update.
flowchart TD
  A["A Salesforce change is sent"] --> B{"Did QuickBooks refuse it as out of date?"}
  B -- "No" --> C["Sent as usual"]
  B -- "Yes" --> D["QB Bridge reads the QuickBooks record and finds the fields changed on both sides"]
  D --> E{"When both systems update the same field"}
  E -- "The latest change wins" --> F["The side changed most recently wins"]
  E -- "Salesforce always wins" --> G["The Salesforce values are sent"]
  E -- "QuickBooks always wins" --> H["Those fields are left out of the update"]
  F --> W["A warning in the logs names the fields"]
  G --> W
  H --> W

Fields changed on one side only are sent as usual. Each conflict is logged as a warning that names the fields, for example "Changed in both Salesforce and QuickBooks since the last sync: PrimaryPhone. Salesforce values sent (conflict setting)."

Why a QB record never syncs back out

QB records (QB Invoice, QB Customer and the others) and QB Bridge's own objects are never used as a source for outbound sync. Records that came from QuickBooks are not sent back either. When inbound updates a field on your own record, that field is one no mapping uses (on any entity, in a field, a formula or as the ID field), and the save does not start a send. So an inbound change can never bounce back to QuickBooks and start a loop.

The trip back: QuickBooks to Salesforce#

QuickBooks does not push changes to Salesforce. Instead QB Bridge asks on a schedule you set on the QB Bridge Settings tab: "what changed since last time?". The changes join the same work queue and are applied to the QB records, following the inbound settings of each entity: which events to accept (create, update, delete) and which fields an update may overwrite.

How the schedule works
  • Four scheduled jobs, named QB Bridge Ticker :00, :15, :30 and :45, run every 15 minutes. Each run starts whatever is due.
  • The Inbound poll asks QuickBooks what changed, at the interval you choose: 15, 30 or 45 minutes, or whole hours or days. Each run is one QuickBooks call for all entities.
  • Reference data refreshes the cached QuickBooks lists (products, accounts, terms…) that the mapping uses to turn names into IDs.
  • Once a day a connection check and a clean-up run. If QuickBooks refuses the connection, records wait in the queue and go once it is back.

Where to look#

You want to knowLook at
Did my record reach QuickBooks?The record's QuickBooks sync history panel, the QB record for it, or your QuickBooks ID field
Why didn't it?The same panel, or Failed records on the QB Bridge Health tab: the Reason column
Is automatic sync wired up?QB Bridge Entities tab, the entity's Outbound to QuickBooks card
Is QuickBooks data coming back?QB Bridge Health tab, Background jobs, the Inbound poll row (administrators)
What does QuickBooks hold for this record?The QuickBooks data component on the record page
Did a QuickBooks change reach my record?The record's QuickBooks sync history: an Update Salesforce row

Where to next#