Add cart.updateLineItemQuantity to the POS Cart API (2026-10) - #4672
Open
js-goupil wants to merge 1 commit into
Open
Add cart.updateLineItemQuantity to the POS Cart API (2026-10)#4672js-goupil wants to merge 1 commit into
js-goupil wants to merge 1 commit into
Conversation
js-goupil
marked this pull request as ready for review
September 3, 2026 13:39
fatbattk
approved these changes
Sep 3, 2026
js-goupil
force-pushed
the
jsgoupil/cart-update-line-item-quantity
branch
from
September 3, 2026 18:07
6765ade to
b842aef
Compare
Line-scoped quantity update that preserves the line item's properties, discounts, and selling plans. Available on API version 2026-10 and later; quantity must be a positive integer (use removeLineItem to remove a line), and a uuid matching multiple split-line allocations throws rather than guessing the target line. Includes a docs example that reads the uuid from the cart signal, tester mock support, and a changeset. Assisted-By: devx/7cc61f9e-de33-47f7-a151-9c7b33f92276
js-goupil
force-pushed
the
jsgoupil/cart-update-line-item-quantity
branch
from
September 3, 2026 18:11
b842aef to
a16bc8c
Compare
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.
Background
https://github.com/shop/issues-retail/issues/34342
Community feature request: https://community.shopify.dev/t/feature-request-updatelineitemquantity-in-the-pos-ui-extensions-cart-ap/36489
POS UI extensions have no line-scoped way to change the quantity of an existing cart line. Today an extension must either re-add the variant (which creates a separate line, or merges unpredictably across POS versions) or rewrite the whole cart with
bulkCartUpdate(which risks rejecting on computed fields and has repriced existing lines to $0.00). Custom sale lines have no variant ID, sobulkCartUpdateis their only option.Solution
Adds
updateLineItemQuantity(uuid: string, quantity: number): Promise<void>to the POS Cart API (MutableCartApiContent), available in API version 2026-10 and later.quantitymust be an integer of 1 or greater; useremoveLineItemto remove a line.Also included: a docs example, tester mock support (
@shopify/ui-extensions-tester), and a changeset (minor for@shopify/ui-extensions, patch for the tester).🎩
yarn build,yarn type-check,yarn lint, and the POS tester test suites.Checklist