Events API
Send Event
Section titled “Send Event”POST /ingest/eventsRequest Body:
{ "event": "purchase", "customerId": "cust_abc123", "amount": 4999, "metadata": { "orderId": "ord_456", "items": ["sku_a", "sku_b"] }}| Field | Type | Required | Description |
|---|---|---|---|
event | string | Yes | Event type |
customerId | string | Yes | Customer identifier |
amount | number | No | Value in cents |
metadata | object | No | Custom event data |
timestamp | string | No | ISO 8601 (defaults to now) |
Response:
{ "success": true, "data": { "id": "evt_abc123", "event": "purchase", "status": "queued" }}Send Batch Events
Section titled “Send Batch Events”POST /ingest/events/batchSend up to 100 events in a single request:
{ "events": [ { "event": "purchase", "customerId": "cust_abc123", "amount": 4999 }, { "event": "review", "customerId": "cust_abc123", "metadata": {"productId": "prod_789", "rating": 5} } ]}List Events
Section titled “List Events”GET /v1/eventsQuery Parameters:
| Parameter | Type | Description |
|---|---|---|
customerId | string | Filter by customer |
event | string | Filter by event type |
from | string | Start date (ISO 8601) |
to | string | End date (ISO 8601) |