Skip to main content

cartDeleteItem

Remove an item from the shopping cart.

Permanently removes the specified item from the cart and recalculates cart totals. This action cannot be undone.

Possible errors:

  • CART_NOT_FOUND_ERROR: Cart with the specified ID does not exist
  • CART_ITEM_NOT_FOUND_ERROR: Cart item with the specified ID does not exist
  • CART_ITEM_DELETE_ERROR: Failed to remove the item from the cart
  • CART_ITEM_NOT_DELETABLE_ERROR: Cart item cannot be deleted in its current state
cartDeleteItem(
id: String!
input: CartDeleteItemInput!
): Cart!

Arguments

cartDeleteItem.id ● String! non-null scalar

Unique identifier of the cart containing the item.

Must be a valid UUID format representing an existing cart.

cartDeleteItem.input ● CartDeleteItemInput! non-null input

Item deletion information.

Contains the identifier of the cart item to be removed.

Type

Cart object

Shopping cart entity for managing customer purchases.

Represents a shopping session containing products, customer information, addresses, payment preferences, and all data needed for order processing. Carts can be associated with different customer types and support various business models.