Dynamically update line itemsPrivate preview
Update line items in response to changes made during checkout.
Dynamically add, remove, or update line items included in a Checkout Session.
This allows you to:
- Check inventory: Run inventory checks and holds when customers attempt to change item quantities.
- Add new products: Add a complimentary product if the order total exceeds a specific amount.
- Update shipping rates: If the order total changes, update shipping rates by combining the method described in this guide with our guide on how to Customize shipping options during checkout.
- Update tax rates: If you’re not using Stripe Tax, you can dynamically update tax rates on line items based on the shipping address entered.
We’re working on adding support for this feature when using an embedded form. Contact us to be notified when this is released or use this feature with Elements with the Checkout Sessions API instead.