---
title: "Update cart item"
method: POST
path: "/item"
tags: ["items"]
---

# Update cart item

`POST /item`

Updates the quantity of a specific item in the customer's cart.

## Request body

- object
  - `cart_item_key` string — Unique identifier for the item in the cart.
  - `quantity` string, required — Quantity of this item to update to.
  - `return_cart` boolean — Returns the whole cart to reduce API requests.

## Response `200`

Cart item updated successfully.

- union
  - CartItem
    - `item_key` string — Unique identifier for the item within the cart.
    - `id` integer — Product ID.
    - `name` string — Product name.
    - `title` string — Product title.
    - `price` string — Current product price.
    - `quantity` object — Quantity information for this item.
      - `value` number — Current quantity of the item in the cart.
      - `min_purchase` number — Minimum quantity that can be purchased.
      - `max_purchase` number — Maximum quantity that can be purchased.
    - `totals` object — Item totals.
      - `subtotal` number — Line subtotal (before discounts).
      - `subtotal_tax` number — Line subtotal tax.
      - `total` number — Line total (after discounts).
      - `tax` number — Line total tax.
    - `slug` string — Product slug.
    - `meta` object — Item metadata.
      - `product_type` string — Product type.
      - `sku` string — Product SKU.
      - `dimensions` object — Product dimensions.
        - `length` string — Product length.
        - `width` string — Product width.
        - `height` string — Product height.
        - `unit` string — Dimension unit.
      - `weight` string — Product weight.
      - `variation` union — Chosen attributes (for variations).
        - object
        - string[]
    - `backorders` string — Backorder status.
    - `cart_item_data` object — Custom cart item data.
    - `featured_image` string — Product featured image URL.
  - Cart — A map of cart item keys to cart item objects. Each property key is a unique cart item key.

## Other responses

- `400` — Bad request - invalid parameters.
- `404` — Cart item not found.

---

[API](https://skmtc.net/cocartapi/apis/cocart-jwt-authentication.md) · [All operations](https://skmtc.net/cocartapi/apis/cocart-jwt-authentication/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cocartapi/cocart-jwt-authentication/revisions/2031b047ca5f/schema)
