💎 自用像素
PageView, ViewContent, AddToCart, InitiateCheckout, Purchase
接口地址
POST /api/pixel-events
请求头
Content-Type: application/jsonOrigin: https://your-shop-domain.com(必须,系统通过此头部识别店铺)
请求体参数
| 参数名 | 类型 | 必填 | 说明 |
|---|---|---|---|
| event_type | string | 是 | 事件类型(见下方枚举) |
事件类型枚举
- PageView
- ViewContent
- AddToCart
- InitiateCheckout
- Purchase
请求示例
POST /api/pixel-events HTTP/1.1
Host: api.example.com
Origin: https://runningshoesflashsale.com
Content-Type: application/json
{
"event_type": "AddToCart"
}
响应示例
{
"success": true,
"message": "事件记录成功"
}