Marketplace API / Types

Cart

Object

A shopping cart.

Every cart is associated with only one seller. A buyer can have multiple carts with different sellers.

type Cart implements Node

Fields

FieldTypeDescription
idID!
A globally unique ID. Treat this value as an opaque string.
items[CartItem!]!
Items currently in this cart.
sellerUser!
The seller whom the cart items belong to.
shipsFromShipsFromLocation
The single origin all items in this cart ship from. Null when the origin is unknown, or if items ever ship from different origins — clients must handle both the same way.
subtotalMoney!
Subtotal for the items in this cart.
urlURL!
URL for viewing this cart. Open it directly; unauthenticated users are redirected to sign in.Arguments:
returnPath: String — A path, such as /p/vintage-rolex?size=m, resolved against the origin of Marketplace.url without that URL's path prepended. Checkout's back link returns the customer to this path. The value must start with one /, must not start with // or /\, must not contain a tab, carriage return or line feed, and must resolve to a URL on the storefront's origin. Any other value fails with error code VALIDATION_ERROR. When omitted or null, the back link opens Marketplace.url.

Returned by