Ingest Event

Send a pageview or custom event from the tracking script.

Ingest Event

The primary data ingestion endpoint used by the EngageTrack tracking script. Receives pageview and custom event payloads.

This endpoint is called automatically by the tracking script. You typically don't need to call it directly unless building a custom integration.

Endpoint

POST /api/v1/event

No Bearer token required — the site is identified by the site_id field (the site's public ID).

Request Body

FieldTypeRequiredDescription
site_idstringYesSite public ID (pk_live_*)
event_typestringNopageview, click, form_submit, download, outbound, purchase, custom
urlstringYesFull page URL
event_namestringNoCustom event name (for custom events)
referrerstringNoReferrer URL
titlestringNoPage title
visitor_uidstringNoPersistent visitor ID from localStorage
session_idstringNoClient-side session ID
screen_wnumberNoScreen width
screen_hnumberNoScreen height
time_on_pagenumberNoSeconds spent on previous page
scroll_depthnumberNoMax scroll percentage (0-100)
revenuenumberNoRevenue amount (for purchase events)
currencystringNoCurrency code, e.g. USD
order_idstringNoOrder ID (for purchase events)
propertiesobjectNoCustom key-value properties

Response

Returns 202 Accepted with body ok on success.

Identify Endpoint

To link an anonymous visitor to a known user identity:

POST /api/v1/identify
FieldTypeRequiredDescription
site_idstringYesSite public ID
visitor_uidstringYesVisitor UID from tracker
user_idstringYesYour application's user ID
namestringNoUser display name
emailstringNoUser email
avatarstringNoAvatar URL
customobjectNoCustom attributes