Commerce Cart API

lightning/commerceCartApi

Create and delete carts for buyers in a webstore using the lightning/commerceCartApi module. The lightning/commerceCartApi module requires API version 62.0 or later.

For Use In

Lightning Experience, Experience Builder Sites, Salesforce Mobile App

The lightning/commerceCartApi module includes methods to create and delete carts for buyers in a webstore.

To use the Commerce Cart API in your component, import the functions in your component’s JavaScript file.

1import { createCart, deleteCart } from "lightning/commerceCartApi";

For this module’s specification and examples, see the Lightning Web Components Developer Guide.

error fallback image
Temporary Loading Glitch
Looks like this content has briefly vanished into the horizon! Refresh the page and try again.