API reference

Website events

Send page views, identify calls, conversions and custom events to EmailMarketer.io to trigger journeys and build segments.

Website events feed journey triggers (page view, identify, custom event, conversion) and website-events segment rules. Send them from your server with event.track.

event.track

POST https://app.emailmarketer.io/api/v1/event with APIKey.

Parameter Type Required Description
Event string Yes For example page_view, identify, conversion or your own event name
ListID int No The list the contact is on
Email string No The contact’s address
ID string No Your own user ID, or a SHA-256 hash of the email
UUID string No A visitor ID. Created for you if you do not send one
Properties object No Event data
IdentifyProperties object No For identify only: custom field values keyed by merge tag alias or CustomField<ID>

Conversion events need conversion-id, conversion-name and conversion-value in Properties. Add "isTest": true to Properties to check a call without recording it.

curl https://app.emailmarketer.io/api/v1/event \
  -H "Content-Type: application/json" \
  -d '{
    "APIKey": "'"$EM_API_KEY"'",
    "Event": "conversion",
    "ListID": 123,
    "Email": "jane@example.com",
    "Properties": { "conversion-id": "order-1042", "conversion-name": "Order", "conversion-value": 49.00 }
  }'
{ "status": "success", "uuid": "550e8400-e29b-41d4-a716-446655440000", "external_id": "user-12345", "identify_event_sent": true }
Code Meaning
4 Invalid ListID
5 Missing Event
7 Invalid email
8, 9, 10 Missing conversion-id, conversion-name or conversion-value

website_events.properties

GET /api/v1/website_events.properties with ListID. Returns the property names seen for each event on that list, for building segment rules.

{ "ListID": 123, "Properties": { "page_view": ["$page_title"], "conversion": ["conversion-id"] } }

Errors: 1 missing ListID, 2 invalid ListID, 3 list not found.