Checkout events that trigger integration and calculator runs
Key Takeaway
By default, starting checkout runs pricing, promotions and inventory. Selecting a delivery method runs taxes but not shipping, because shipping depends on a delivery group change. Sending only contact information runs no calculators.
In Salesforce B2B Commerce, buyer actions in the cart and checkout start background calculators that work out pricing, promotions, inventory, shipping and tax. The Cart Calculate API decides which calculators run for each buyer action. A developer can change that logic with a custom orchestrator. When you know which event runs which calculator, you can make Checkout API calls in the right order and track down missing prices, shipping charges or taxes.
Three levels of control
The Cart Calculate API has three levels of control.
- Orchestrators decide which calculators run and when.
- Calculators do cart calculations such as shipping and tax.
- Services do specific calculations that can reach beyond the cart. For example, the Pricing service also affects product detail pages.
By default, calculators run in this order:
- pricing
- promotions
- inventory
- shipping
- postShipping
- taxes
By default, shipping, postShipping and taxes run only during checkout. A custom orchestrator can change the order or skip calculators.