Set cart
PATCH/v1/:id/set
Set cart
Request
Path Parameters
id stringrequired
Cart ID
Example: 9597879817
- application/json
Body
required
- Array [
- ]
products object[]required
Product identifiers for the cart.
id stringrequired
Product ID.
variantId stringrequired
The ID of the product variant.
quantity floatrequired
Possible values: >= 1
Quantity of the product variant.
Responses
- 200
- 400
- 401
- 404
- 5XX
Success
- application/json
- Schema
- Example (from schema)
Schema
- Array [
- ]
- Array [
- ]
data object
products object[]required
Product identifiers for the cart.
id stringrequired
Product ID.
variantId stringrequired
The ID of the product variant.
quantity floatrequired
Possible values: >= 1
Quantity of the product variant.
id stringrequired
Unique identifier for the cart
errors object[]
id stringrequired
Unique identifier for error. Can be used for tracing across services.
status floatrequired
HTTP status code.
code stringrequired
Unique code for specific error.
title stringrequired
Short description what the error entails.
{
"data": {
"products": [
{
"id": "clad6pg5z00eu012gfz7hfm92",
"variantId": "M00679529706740",
"quantity": 1
}
],
"id": "cjzyvxtm207z4rns56tif8job"
},
"errors": [
{
"id": "123e4567-e89b-12d3-a456-426655440000",
"status": 400,
"code": "USER_NOT_FOUND",
"title": "Error occurred trying to create a new order"
}
]
}
400 - Bad request
- application/json
- Schema
- Example (from schema)
Schema
- Array [
- ]
errors object[]
status floatrequired
detail stringnullablerequired
title stringrequired
{
"errors": [
{
"status": 400,
"detail": "",
"title": "Bad input request"
}
]
}
401 - Unauthorized
- application/json
- Schema
- Example (from schema)
Schema
- Array [
- ]
errors object[]
status floatrequired
detail stringnullablerequired
title stringrequired
{
"errors": [
{
"status": 401,
"detail": "",
"title": "Authentication information is missing or invalid"
}
]
}
404 - Not found
- application/json
- Schema
- Example (from schema)
Schema
- Array [
- ]
errors object[]
status floatrequired
detail stringnullablerequired
title stringrequired
{
"errors": [
{
"status": 404,
"detail": "",
"title": "Not Found"
}
]
}
500 - Unknown error
- application/json
- Schema
- Example (from schema)
Schema
- Array [
- ]
errors object[]
status floatrequired
detail stringnullablerequired
title stringrequired
{
"errors": [
{
"status": 500,
"detail": "",
"title": "Unknown error"
}
]
}
Loading...