B2B feature. Learn more
clearCustomerCart mutation
The clearCustomerCart
mutation clears the customer's cart. B2B requisition lists must be enabled to execute this mutation.
Use the storeConfig query with the is_requisition_list_active
attribute to determine whether requisition lists are enabled.
This mutation requires a valid customer authentication token.
Syntax
Copied to your clipboardmutation {clearCustomerCart(cartUid: String!) {ClearCustomerCartOutput}}
Reference
The clearCustomerCart
reference provides detailed information about the types and fields defined in this mutation.
Example usage
The following example clears the customer's cart.
Request:
Copied to your clipboardmutation {clearCustomerCart(cartUid: "8k0Q4MpH2IGahWrTRtqM61YV2MtLPApz") {status}}
Response:
Copied to your clipboard{"data": {"clearCustomerCart": {"status": "true"}}}