v41

latestOpenAPI 3.1.0raw.githubusercontent.com2025-08-053715199.1 KB
Cart

Add item

Add an item to the current user's cart.

put/cart/item

Request body

productVariantIDstring required

ID of the product variant to add to the cart.

quantityinteger required

Quantity of the item to add to the cart.

Example request

{
  "productVariantID": "var_XXXXXXXXXXXXXXXXXXXXXXXXX",
  "quantity": 2
}

Response

The updated cart.

Example response

{
  "data": {
    "subtotal": 4400,
    "items": [
      {
        "id": "itm_XXXXXXXXXXXXXXXXXXXXXXXXX",
        "productVariantID": "var_XXXXXXXXXXXXXXXXXXXXXXXXX",
        "quantity": 2,
        "subtotal": 4400
      }
    ],
    "amount": {
      "subtotal": 4400,
      "shipping": 800
    },
    "addressID": "shp_XXXXXXXXXXXXXXXXXXXXXXXXX",
    "cardID": "crd_XXXXXXXXXXXXXXXXXXXXXXXXX",
    "shipping": {
      "service": "USPS Ground Advantage",
      "timeframe": "3-5 days"
    }
  }
}