Create Cart
Opens a cart for a shopper and returns its token. The cart is anonymous: no customer is attached until checkout. Send items to add the first lines in the same call. The body is optional.
For a product whose request_form is in BUY_NOW mode, send answers and needed_by with the item. A product sold through order requests returns 422 here; use Create Request instead.
Keys: public key or secret key.
Authentication
AuthorizationBearer
Bearer authentication of the form Bearer <token>, where token is your auth token.
identitystring
The identity for the active workspace.
Headers
channel
client-ip
The shopper's IP address. Read only when the request is signed with a secret key, so a server calling on behalf of many shoppers does not share one rate limit. Ignored for public keys.
Request
This endpoint expects an object.
country
Market to price the cart for, as a two- or three-letter country code (NG or NGA). Defaults to the channel’s default country. Fixed for the life of the cart.
items
Lines to add straight away.
Response
Successfully created cart
status
Always true on success.
message
Human-readable outcome.
data
Errors
400
Bad Request Error
401
Unauthorized Error
402
Payment Required Error
404
Not Found Error
422
Unprocessable Entity Error
429
Too Many Requests Error

