Preview

Cart is in Preview status and is subject to change without notice. For more information about Preview status, see the GraphQL API policy.

Cart

The cart of a user containing one or more items to be purchased

This page contains

    Fields

    id: ID!

    The unique identifier for the cart.

    buyerUser: User! PREVIEW

    The user who is purchasing the products.

    buyerAccount: Account! PREVIEW

    The account(company) associated with the user purchasing the products.

    currency: Currency!

    The currency in which the price is presented.

    status: CartStatus! PREVIEW

    Status of the cart indicating whether purchase of the items in the cart is to be completed or is completed

    locale: Locale!

    The locale indicating which language should be used for cart-related text.

    items: [CartItem!]! PREVIEW

    The items present in the cart.

    associations: [CartItemAssociation!]! PREVIEW

    A list of associations for all items in the cart.

    paymentMethodId: String

    Represents the id of a payment method

    customAttributes: CartCustomAttributes PREVIEW

    Represents the custom attributes of the cart

    pricingTotal: CartPricingTotal! PREVIEW

    Pricing total details of the cart

    createdOn: DateTime!

    Date time representing when cart was created

    Mutations for Cart

    addItemsToCart PREVIEW

    Add items to existing active cart or create new cart with provided items if active cart doesn't exist

    applyDiscountToCart PREVIEW

    Apply discount Code to the cart

    removeDiscountFromCart PREVIEW

    Remove discount Code from the cart

    removeItemsFromCart PREVIEW

    Remove items from the cart

    updateCart PREVIEW

    Update an existing cart

    updateCartCustomAttributes PREVIEW

    Update an existing cart custom attributes

    updateCartItems PREVIEW

    Update items of an existing cart

    Queries for Cart

    activeCart PREVIEW

    Retrieves active cart of the user

    activeCartOfUser PREVIEW

    Retrieves active cart of the user