Cart and checkout
The Store API cart (/wp-json/wc/store/v1/cart) and checkout total through WooCommerce’s own cart, where Joinery applies its rules, so you don’t need anything extra:
- Each item’s
prices.priceis the unit price after Joinery rules.prices.regular_priceis the product’s regular price, so you can show a strikethrough. - Cart-wide discounts appear in the cart’s
feeslist as a negative fee named Discount, and are included intotals.
Cart item (excerpt)
Quantity breaks on products
Products get ajoinery extension with the unit price from each quantity where it changes, for the current customer. It always starts at quantity 1.
Response (excerpt)
"1080" with currency_minor_unit: 2 is 10.80.
Quantity breaks come from actions that declare them, such as Dynamic Pricing’s Tiered price by quantity. Every rule condition still applies, so a break only appears when this product’s price really changes at that quantity for this customer.