Skip to main content
POST
This endpoint creates a new shopping cart that persists across sessions. Carts can be associated with authenticated customers or anonymous sessions.

Authentication

This endpoint requires a valid API key with carts:write permissions.

Request Body

string
Customer ID to associate with the cart (for authenticated users)
string
Session ID for guest carts (auto-generated if not provided)
string
Sales channel: “web”, “mobile”, “pos”, “api”
string
required
ISO 4217 currency code
string
Locale for the cart (e.g., “en-US”)
array
Initial items to add to the cart
object
Shipping address for tax/shipping calculations
string
Email for guest checkout and abandoned cart recovery
string
Custom expiration date (ISO 8601, default: 30 days)
object
Additional custom fields

Response

Returns the created cart object.