Price Books for Developers

The Salesforce B2C Commerce API dw.catalog.ProductPriceModel scripting class enables you to retrieve product prices in the storefront. Often products can have multiple prices assigned. B2C Commerce uses a set of business rules to determine which price is relevant at a given time.

The Salesforce B2C Commerce API dw.catalog.ProductPriceModel scripting class enables you to retrieve product prices in the storefront. Often products can have multiple prices assigned. B2C Commerce uses a set of business rules to determine which price is relevant at a given time. In general, B2C Commerce, based on price lookup rules, determines the best price (lowest price) for a requested quantity and shows it in the storefront.

Price lookup rules

These rules represent how prices are retrieved through the scripting API. Product prices are also relevant when a search is performed in the storefront. For example, B2C Commerce lets you refine searches by price. For performance reasons, B2C Commerce does not directly access prices that are stored in the database to provide this refinement capability. Instead, it uses prices that are stored in the product search index when the index is built. It's possible, therefore, for these prices to get out of synch (though they generally remain consistent).

Adequate information is encoded in the product index. B2C Commerce follows the same lookup rules regarding applicable price books, price activation dates, and multiple price tables for a given product. Sometimes, you must rebuild the product index so that the prices used by B2C Commerce are consistent with the prices that appear on product detail pages.

X Privacy Update: We use cookies to make interactions with our websites and services easy and meaningful, to better understand how they are used. By continuing to use this site you are giving us your consent to do this. Privacy Policy.