Skip to main content
POST
/
v3
/
stores
/
{store_id}
/
public
/
analytics
/
tiktok
/
events
Send a TikTok Events API event
curl --request POST \
  --url https://api.scalev.com/v3/stores/{store_id}/public/analytics/tiktok/events \
  --header 'Content-Type: application/json' \
  --header 'X-Scalev-Storefront-Api-Key: <x-scalev-storefront-api-key>' \
  --data '
{
  "event_source_url": "<string>",
  "user": {
    "email": "<string>",
    "phone": "<string>",
    "external_id": "<string>",
    "ttclid": "<string>",
    "ttp": "<string>",
    "user_agent": "<string>"
  },
  "events": [
    {
      "event_id": "<string>",
      "event": "AddToCart",
      "parameters": {}
    }
  ],
  "referrer_url": "<string>",
  "variants": [
    {
      "variant_unique_id": "<string>",
      "quantity": 2
    }
  ],
  "bundle_price_options": [
    {
      "bundle_price_option_unique_id": "<string>",
      "quantity": 2
    }
  ]
}
'
{
  "error": {},
  "error_code": "<string>",
  "message": "<string>",
  "errors": {}
}

Headers

X-Scalev-Storefront-Api-Key
string
required

Publishable storefront public API key for the target store. Page public API keys are not accepted on Storefront public routes.

Path Parameters

store_id
string
required

Store unique_id.

Body

application/json
event_source_url
string<uri>
required

Full storefront page URL for the event. The API strips query parameters before sending to TikTok.

user
object
required
events
object[]
required
Minimum array length: 1
referrer_url
string<uri> | null

Browser referrer URL. The API uses this with event_source_url to choose checkout versus home storefront analytics configuration.

variants
object[]
bundle_price_options
object[]

Response

Success with no response body