Shopify POS UI Extensions API 2026-07: FixedAmount Discounts Must Be Per-Unit
Patch your discount logic to compute per‑unit discounts before calling setLineItemDiscount or bulkSetLineItemDiscounts in API version 2026‑07.
Patch your discount calculations to compute per‑unit discounts before using setLineItemDiscount or bulkSetLineItemDiscounts in API version 2026‑07.
Summary
Shopify’s POS UI Extensions API version 2026-07 introduces a breaking change to how FixedAmount line item discounts are interpreted. Previously, when developers passed a total discount for a line item, the API automatically converted it to a per‑unit value. In the new version, that conversion is removed and the value you provide is taken as the discount applied to each unit.
To apply a total discount of $5 on a line item with quantity 2, you now need to pass $2.50 per unit; passing $5 will result in a $10 total discount. Percentage discounts remain unaffected. Apps that were already using API version 2026-04 or earlier do not need to change, but any app that adopts 2026-07 must adjust its discount calculations accordingly.
If the total discount does not divide evenly by the quantity, round the per‑unit value to match your intended discount logic. The change applies only to FixedAmount discounts and does not affect other discount types.
Key changes
- FixedAmount line item discounts now interpreted as per‑unit values
- No automatic conversion from total to per‑unit
- To apply total discount, divide by quantity and pass per‑unit
- Percentage discounts unaffected
- Apps using 2026‑04 or earlier need not change
- Must handle rounding if total not divisible evenly
- API version 2026‑07 requires per‑unit discount