Skip to main content
Skip to main content

Cart

A cart represents a virtual shopping bag. It can be used to complete an order, a swap, or a claim.

Properties

idstringRequired
The cart's ID
created_atDateRequired
The date with timezone at which the resource was created.
updated_atDateRequired
The date with timezone at which the resource was updated.
deleted_atnull | DateRequired
The date with timezone at which the resource was deleted.
object"cart"Required

Default: "cart"

emailstringRequired
The email associated with the cart
billing_address_idstringRequired
The billing address's ID
billing_addressAddressRequired
The details of the billing address associated with the cart.
shipping_address_idstringRequired
The shipping address's ID
shipping_addressnull | AddressRequired
The details of the shipping address associated with the cart.
itemsLineItem[]Required
The line items added to the cart.
region_idstringRequired
The region's ID
regionRegionRequired
The details of the region associated with the cart.
discountsDiscount[]Required
An array of details of all discounts applied to the cart.
gift_cardsGiftCard[]Required
An array of details of all gift cards applied to the cart.
customer_idstringRequired
The customer's ID
customerCustomerRequired
The details of the customer the cart belongs to.
payment_sessionnull | PaymentSessionRequired
The details of the selected payment session in the cart.
payment_sessionsPaymentSession[]Required
The details of all payment sessions created on the cart.
payment_idstringRequired
The payment's ID if available
paymentPaymentRequired
The details of the payment associated with the cart.
shipping_methodsShippingMethod[]Required
The details of the shipping methods added to the cart.
typeCartTypeRequired
The cart's type.

Default: default

completed_atDateRequired
The date with timezone at which the cart was completed.
payment_authorized_atDateRequired
The date with timezone at which the payment was authorized.
idempotency_keystringRequired
Randomly generated key used to continue the completion of a cart in case of failure.
contextRecord<string, unknown>Required
The context of the cart which can include info like IP or user agent.
metadataRecord<string, unknown>Required
An optional key-value map with additional details
sales_channel_idnull | stringRequired
The sales channel ID the cart is associated with.
sales_channelSalesChannelRequired
The details of the sales channel associated with the cart.
sales_channelsSalesChannel[]
The associated sales channels.
shipping_totalnumber
The total of shipping
discount_totalnumber
The total of discount rounded
raw_discount_totalnumber
The total of discount
item_tax_totalnull | number
The total of items with taxes
shipping_tax_totalnull | number
The total of shipping with taxes
tax_totalnull | number
The total of tax
refunded_totalnumber
The total amount refunded if the order associated with this cart is returned.
totalnumber
The total amount of the cart
subtotalnumber
The subtotal of the cart
refundable_amountnumber
The amount that can be refunded
gift_card_totalnumber
The total of gift cards
gift_card_tax_totalnumber
The total of gift cards with taxes
Was this section helpful?