Cart Analytics API

Record that a user added a product to the cart.

Last updated

On this page

Overview

Use the Cart Analytics API to record an add-to-cart action.

Endpoint

MethodPath
POST/api/v2/conversion/cart

Request body parameters

Parameter nameRequirementTypeDescription
oIdrequiredstringID of the product added to the cart.
userTokenoptionalstring | nullableUnique for every user session (cookie _athena). Send it if an Athena XAI rendered product is added to the cart.
additionalDataoptionalobjectAdditional information about the add to cart action: quantity, configurable_super_attribute.

Example call

MethodPath
POST{{athena_url}}/api/v2/conversion/cart

Body raw (JSON)

JSON
{
    "token": "website_token",
    "oId": "2573655",
    "athenaUid": "athena-123-test",
    "source": "search",
    "channel": "search landing page",
    "ip_address": "ip_address"
}

Response

JSON
{
    "message":"Cart Analytics was successfully stored.",
    "status":200
}