It appears that when I try to apply a discount code via cartDiscountCodesUpdate
-
The code is applied
-
The code is returned in Cart.discountCodes
However, Cart.discountCodes[0].applicable is set to false but the total for the cart has changed to reflect the applied discount.
I’m applying a 10% Off coupon and my query looks like this:
mutation cartDiscountCodesUpdate($cartId: ID!, $discountCodes: [String!]!, $contextCountry: CountryCode!) @inContext(country: $contextCountry) {
cartDiscountCodesUpdate(cartId: $cartId, discountCodes: $discountCodes) {
cart {
...CartFragment
}
userErrors {
field
message
}
}
}
I should also add, the documentation here has the wrong method signature:
https://shopify.dev/api/storefront/2022-01/mutations/cartDiscountCodesUpdate
Thanks,
Stephen