Skip to navigation

Get cart

Returns the current state of a cart, including all line items and hold expiration times. Prices come back in the currency the cart was created in. Send the currency query parameter to re-quote this response in another currency. Send the country query parameter to include payment methods that depend on where the shopper is buying from, such as Klarna and Afterpay — without it those methods are never listed. Neither parameter changes the cart.

Authentication

X-TT-API-Keystring
API Key authentication via header

Path parameters

cartIdstringRequiredformat: "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$"

Cart ID (UUID)

Headers

X-TT-PlatformenumRequired
Identifies the platform the request comes from.
Allowed values:
X-TT-RetailerstringRequired
Your retailer identifier, provided during onboarding. It must be a retailer your API key was issued for.

Query parameters

currencystringOptionalformat: "^[A-Z]{3}$"

ISO 4217 currency to re-quote this response in, without changing the cart. Omit to price in the currency the cart carries.

countrystringOptionalformat: "^[A-Z]{2}$"

ISO 3166-1 alpha-2 country the shopper is buying from. Send it to include payment methods that depend on the shopper’s country, such as Klarna and Afterpay, in options.paymentMethods — without it those methods are never listed. Does not change the cart.

Response headers

X-RateLimit-Limitinteger
How many requests this API key may make for this retailer in the current window. Sent only when the request was counted against that limit. A response served from cache was not counted and repeats the value it was cached with.
X-RateLimit-Remaininginteger
How many requests this API key has left for this retailer in the current window. Sent only when the request was counted against that limit. A response served from cache was not counted and repeats the value it was cached with.

Response

Cart details.
dataobject
Shopping cart containing held inventory cart items.

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
409
Conflict Error
410
Gone Error
429
Too Many Requests Error
503
Service Unavailable Error