Updating Product Pricing
A guide on how to update product pricing at runtime
Any configurator-lite session has a default pricing set for each product which can then be overridden at any point.
The process of updating the pricing can be achieved in 3 simple steps:
- Getting the current pricing
const currentPricing = EPIGRAPH_CONFIGURATOR.api.getCurrentProductPricings();- Updating the desired prices.
currentPricing.get("product-sku-01").price = 99.99;
currentPricing.get("product-sku-02").price = 564.55;- Set the updated pricing.
//Pass the currentPricing object into the API call to set all prices.
await EPIGRAPH_CONFIGURATOR.api.setCurrentProductPricings(currentPricing); // could also be an async callUpdated 8 months ago
