Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/specification/common/extensions/loyalty.md
Original file line number Diff line number Diff line change
Expand Up @@ -568,8 +568,8 @@ hold the Retail Club membership and the Retail Card. The platform can then rende
{"type": "subtotal", "display_text": "Subtotal", "amount": 1000},
{"type": "items_discount", "display_text": "Club member benefit", "amount": -150},
{"type": "discount", "display_text": "Free shipping for Retail Card holder", "amount": -199},
{"type": "fulfillment", "display_text": "Shipping", "amount": 0},
{"type": "total", "display_text": "Estimated Total", "amount": 651}
{"type": "fulfillment", "display_text": "Shipping", "amount": 199},
{"type": "total", "display_text": "Estimated Total", "amount": 850}
]
}
```
Expand Down
10 changes: 6 additions & 4 deletions docs/specification/shopping/extensions/discount.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,9 @@ JSONPath to identify targets:
This enables platforms to explain exactly how much each discount contributed to
each line item, even when multiple discounts stack.

**Invariant:** Sum of `allocations[].amount` equals `applied_discount.amount`.
**Invariant:** When `allocations` is present, the sum of `allocations[].amount`
equals `applied_discount.amount`. `allocations` is optional; a discount that
omits it is reported in `totals[]` as a single `discount` entry.

## Operations

Expand Down Expand Up @@ -499,9 +501,9 @@ to line items, and an automatic shipping discount at the order level.
"totals": [
{"type": "subtotal", "display_text": "Subtotal", "amount": 4000},
{"type": "items_discount", "display_text": "Item Discounts", "amount": -800},
{"type": "discount", "display_text": "Order Discounts", "amount": -599},
{"type": "fulfillment", "display_text": "Shipping", "amount": 0},
{"type": "total", "display_text": "Total", "amount": 2601}
{"type": "discount", "display_text": "Free shipping on orders over $30", "amount": -599},
{"type": "fulfillment", "display_text": "Shipping", "amount": 599},
{"type": "total", "display_text": "Total", "amount": 3200}
]
}
```
Expand Down
Loading