curl -X POST https://api2.ecomailapp.cz/tracker/events \
-H "key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"event": {
"email": "john@example.com",
"category": "shopping",
"action": "product_viewed",
"label": "Nike Air Max 90",
"property": "nike-air-max-90",
"value": {
"product_id": 12345,
"price": 139.99,
"currency": "EUR",
"variant": "Black/White",
"url": "https://example.com/products/nike-air-max-90"
}
}
}'
{
"id": 1234,
"email": "john@example.com",
"category": "shopping",
"action": "product_viewed",
"label": "Nike Air Max 90",
"property": "nike-air-max-90",
"value": "{\"product_id\":12345,\"price\":139.99,\"currency\":\"EUR\",\"variant\":\"Black/White\",\"url\":\"https://example.com/products/nike-air-max-90\"}"
}
Tracker events
Create an event
Track a custom event for a subscriber. Supplements the JavaScript tracker.
POST
/
tracker
/
events
curl -X POST https://api2.ecomailapp.cz/tracker/events \
-H "key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"event": {
"email": "john@example.com",
"category": "shopping",
"action": "product_viewed",
"label": "Nike Air Max 90",
"property": "nike-air-max-90",
"value": {
"product_id": 12345,
"price": 139.99,
"currency": "EUR",
"variant": "Black/White",
"url": "https://example.com/products/nike-air-max-90"
}
}
}'
{
"id": 1234,
"email": "john@example.com",
"category": "shopping",
"action": "product_viewed",
"label": "Nike Air Max 90",
"property": "nike-air-max-90",
"value": "{\"product_id\":12345,\"price\":139.99,\"currency\":\"EUR\",\"variant\":\"Black/White\",\"url\":\"https://example.com/products/nike-air-max-90\"}"
}
Only the
email field is required. All other fields (category, action, label, property, value) are optional — include only what makes sense for your use case.
The value field accepts a plain string, a JSON-encoded string, or a JSON object/array. If you pass an object or array, we will automatically JSON-encode it on our side.
Event details.
Show event properties
Show event properties
Subscriber’s email address. The subscriber must already exist in your contact list.
Event category (e.g.
"shopping", "engagement", "support").Event action (e.g.
"product_viewed", "form_submitted", "review_left").Event label — a human-readable name or identifier (e.g. a product name, page title).
Event property — a custom key or identifier (e.g. a product SKU, category slug).
Event value. Can be a plain string, a JSON-encoded string, or a JSON object/array (objects and arrays will be JSON-encoded automatically on our side). Maximum length is 20,000 characters (after JSON encoding, if applicable).
curl -X POST https://api2.ecomailapp.cz/tracker/events \
-H "key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"event": {
"email": "john@example.com",
"category": "shopping",
"action": "product_viewed",
"label": "Nike Air Max 90",
"property": "nike-air-max-90",
"value": {
"product_id": 12345,
"price": 139.99,
"currency": "EUR",
"variant": "Black/White",
"url": "https://example.com/products/nike-air-max-90"
}
}
}'
{
"id": 1234,
"email": "john@example.com",
"category": "shopping",
"action": "product_viewed",
"label": "Nike Air Max 90",
"property": "nike-air-max-90",
"value": "{\"product_id\":12345,\"price\":139.99,\"currency\":\"EUR\",\"variant\":\"Black/White\",\"url\":\"https://example.com/products/nike-air-max-90\"}"
}
⌘I