Skip to content

Basket Operations

Tracks changes to the user's shopping cart using the BASKET_OPERATIONS event.

View as Markdown llms.txt

Tracks changes to the user’s shopping cart using the BASKET_OPERATIONS event. All three requests share the same event name and differ only in the step field.

Requests:

  • Basket Add — fires when a product is added to the cart (step: "add"). Requires productId, price, quantity, and basketId.
  • Basket Remove — fires when a product is removed from the cart (step: "remove"). Requires productId, price, quantity, and basketId.
  • Basket Clear — fires when the entire cart is emptied (step: "clear"). No product-level fields are needed.

All requests use the {dataCenterUrl} endpoint and require userId, sessionId, lang, currency, and basketId.

Example body

{
"name": "BASKET_OPERATIONS",
"userId": "1234567890123456789",
"sessionId": "323232",
"testMode": "false",
"device": "PC",
"nextPage": false,
"params": {},
"os": "ANDROID",
"lang": "EN",
"currency": "EUR",
"productId": "T59008765Y0",
"basketId": "basket_1234567890123456789",
"step": "add",
"price": "1999",
"quantity": 1
}

Example body

{
"name": "BASKET_OPERATIONS",
"basketId": "basket_1234567890123456789",
"userId": "1234567890123456789",
"sessionId": "9876543210987654321",
"testMode": "false",
"device": "PC",
"params": {},
"recommendIds": [],
"pageUrl": "",
"referrer": "",
"lang": "EN",
"currency": "EUR",
"region": "",
"productId": "PRODUCT_ID",
"price": "1000",
"quantity": "1",
"email": "user@example.com",
"step": "remove"
}

Example body

{
"name": "BASKET_OPERATIONS",
"basketId": "basket_1234567890123456789",
"userId": "1234567890123456789",
"sessionId": "9876543210987654321",
"testMode": "false",
"device": "PC",
"params": {},
"recommendIds": [],
"referrer": "",
"lang": "EN",
"currency": "EUR",
"region": "",
"email": "user@example.com",
"step": "clear"
}