> For the complete documentation index, see [llms.txt](https://docs.digitalriver.com/salesforce-lightning/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.digitalriver.com/salesforce-lightning/salesforce-lightning-b2b-commerce-app-2.1/introduction/how-it-works.md).

# How it works

Use the Salesforce Lightning app to enable Digital River to be the merchant of record for storefronts hosted on the Salesforce platform.

* Salesforce Lightning B2B Commerce maintains all pricing and product data.
* Digital River maintains minimal product data used to fulfill its requirements as the merchant of record. This data is used for tax calculations, collection, payments, and payment processing.
* Digital River automatically syncs with the Product (Product2) in Salesforce Lightning with minimal information needed to calculate taxes and enable the merchant of record functions.
* Digital River maintains a copy of the cart (WebCart), the customer, and the order.
* The fulfiller updates the status of the order from `accepted` to `fulfilled` or `canceled` in Salesforce. The Digital River app sends the updated order status to Digital River, who will settle the funds.

## Digital River checkout flow

{% file src="/files/5w9APG81mxjCLl9vVBbO" %}
