applyCodeToNewCart
Creates a new cart and applies a discount code to it.
If you already have a cart ID and want to apply a discount code to it, use the applyDiscountCode
mutation instead.
Use Shop.acceptsDiscountCodes to check if the shop accepts discount codes.
Arguments
| Argument | Description | Type |
|---|---|---|
| input | ApplyCodeToNewCartInput! |
Type
This field resolves to ApplyCodeToNewCartPayload, which has the following fields:
| Field | Description | Type |
|---|---|---|
cart | The newly created cart with the discount code applied. | Cart |