docs(pos): document Discount.amount read behavior from 2026-10 - #4621
Open
vctrchu wants to merge 1 commit into
Open
docs(pos): document Discount.amount read behavior from 2026-10#4621vctrchu wants to merge 1 commit into
vctrchu wants to merge 1 commit into
Conversation
Assisted-By: devx/ebf9cf26-03bb-4c3e-9919-a083a362bb2b
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds TSDoc to
Discount.amounton the POS cart types documenting the read behavior that ships with API version 2026-10: reading a manual discount from the cart returns the value that was applied (e.g.10for 10%), matching writes, so discounts can be echoed throughbulkCartUpdatelosslessly. Includes the POS app version caveat for older clients.Why
Part of the fix for shop/issues-retail#33093: before 2026-10, reads return the calculated monetary total while writes take the applied value, so read-modify-write cycles silently corrupt percentage discounts. The behavior change is implemented in Shopify/extensibility#1657 (host, version-gated) and shop/world#997169 (POS emits the raw value).
Reported in https://community.shopify.dev/t/36265 and https://community.shopify.dev/t/36171.
Companion doc correction for the released 2026-07 branch: #4620.