Cart
In this section, we will cover the basics of cart. We will show you how to add products to cart, update cart items, remove cart items, and get cart totals.
Overview
Cart is the hearth of any eCommerce store. It is the place where customers add products to buy, update quantities, remove products, and finally checkout. In this section, we will show you how to interact with cart using various methods.
Methods in this section are divided into two groups: guest cart methods and customer cart methods. Guest cart methods are used when the customer is not logged in, while customer cart methods are used when the customer is logged in.
Using listed method you can implement the full cart functionality in your storefront integration.
References
Method | Description |
---|---|
cart | Method to fetch/guestrt data |
customerCart | Method to fetch logged in customer cart data |
createEmptyCart | Method to create a new cart |
updateCartItems | Method to update cart items |
removeItemFromCart | Method to remove item from cart |
applyCouponToCart | Method to apply coupon to cart |
removeCouponFromCart | Method to remove coupon from cart |
cartTotalQty | Method to fetch cart total items quantity |
mergeCarts | Method to merge guest and logged in customer carts |