curl --request POST \
--url 'https://prod-api.stateset.cloud.stateset.app/api/v1/agents/customers/{customer_id}/carts/{cart_id}/items' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"quantity": 2,
"variant_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}'
Agent adds an item to a customer's cart
Item added to cart
POST
/
api
/
v1
/
agents
/
customers
/
{customer_id}
/
carts
/
{cart_id}
/
items
curl --request POST \
--url 'https://prod-api.stateset.cloud.stateset.app/api/v1/agents/customers/{customer_id}/carts/{cart_id}/items' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"quantity": 2,
"variant_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}'
Path parameters
string
required
Customer ID
string
required
Cart ID
Request body
AgentAddToCartRequest
integer (int32)
required
string (uuid)
required
Response
No response body. Item added to cart.Status codes
| Code | Meaning |
|---|---|
201 | Item added to cart |
400 | Invalid request |
401 | Unauthorized |
403 | Forbidden |
curl --request POST \
--url 'https://prod-api.stateset.cloud.stateset.app/api/v1/agents/customers/{customer_id}/carts/{cart_id}/items' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"quantity": 2,
"variant_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}'
Last modified on August 31, 2026