Skip to main content

changeDeviceCart

Add, Update, or Remove Items from a Device Cart or SavedForLater. If you are attempting to move an item from the cartItems to savedForLaterItems or vice versa, you must both add and remove the item in the same mutation, which is allowed.

Requires the publiccart/write scope.

changeDeviceCart(
addOrUpdateItems: CartAddOrUpdateItemsInput
deviceId: String!
removeItems: CartRemoveItemsInput
): Cart!

Arguments

changeDeviceCart.addOrUpdateItems ● CartAddOrUpdateItemsInput input

The items to add or update for the cart or savedForLater. Either addOrUpdateItems or removeItems must be provided, and both can be provided.

changeDeviceCart.deviceId ● String! non-null scalar

changeDeviceCart.removeItems ● CartRemoveItemsInput input

The items to add or update to savedForLater. Either addOrUpdateItems or removeItems must be provided, and both can be provided.

Type

Cart object

A cart is a temporary container for products that a customer or anonymous user wants to buy