Getting started
How to send your first event
Video walkthrough
Overview
Sending a first server-side event proves ingestion, authentication, and schema validation in your workspace. This guide uses the HTTP ingestion endpoint with a signed test payload so you can confirm delivery in the live tail before wiring a full storefront or app.
Steps
- In the dashboard, open Settings → API keys and copy an ingestion key with event-write scope.
- Choose a canonical event name such as
PurchaseorPageViewand map it to your internal contract. - POST JSON to the ingestion route with required identifiers (
event_id,timestamp,context.client.user_agentwhen browser-origin).
curl -sS -X POST "https://ingest.tracklayer.io/v1/events" \
-H "Authorization: Bearer tl_your_key" \
-H "Content-Type: application/json" \
-d '{
"event": "PageView",
"event_id": "evt_demo_001",
"timestamp": "2026-05-05T12:00:00.000Z",
"properties": { "path": "/help", "title": "Help center" }
}'- Open Live tail and filter by
event_idto verify acceptance and any enrichment notes.
Troubleshooting
- 401 responses usually mean the key is missing scope or the workspace region does not match the hostname you targeted.
- 422 schema errors list the exact path that failed validation; fix the field and replay with a new
event_id. - If events appear delayed, check whether you batched locally—TrackLayer accepts singles or small batches, but very large payloads may be split by the client SDK.