Skip to main content

Events API

Every events call: what to send, what comes back, and copy-ready examples.

Add a form, booking, signup or custom event

POST/eventsScope: events:write

In the address and headers

Idempotency-Keyheader, optional
text. up to 200 letters

Body

kindneeded
form, booking, booking_canceled, attendance, signup, custom
external_idneeded
text. up to 200 letters
occurred_atoptional
UTC time
labeloptional
text. up to 200 letters
nameoptional
text. up to 200 letters
emailoptional
email
phoneoptional
text. up to 40 letters
visitor_idoptional
text. up to 40 letters
click_idoptional
text. up to 40 letters
is_testoptional
true or false
curl -X POST "https://api.usetotems.com/v1/events" \
  -H "Authorization: Bearer $TOTEMS_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
    "kind": "form",
    "external_id": "form-77",
    "email": "alex@example.com",
    "label": "Apply form"
  }'
Answer, status 201 (sample data)
{
  "data": {
    "id": "2a99433f-7c15-4e2b-8d44-5b6a7c8d9e0f",
    "created": true,
    "person_id": "2a847cfa-7c15-4e2b-8d44-5b6a7c8d9e0f"
  },
  "request_id": "req_..."
}

Add up to 100 events

POST/events/batchScope: events:write

In the address and headers

Idempotency-Keyheader, optional
text. up to 200 letters

Body

eventsneeded
list of any value. up to 100
curl -X POST "https://api.usetotems.com/v1/events/batch" \
  -H "Authorization: Bearer $TOTEMS_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
    "events": [
      {
        "kind": "signup",
        "external_id": "user-1",
        "email": "alex@example.com"
      },
      {
        "kind": "custom",
        "external_id": "webinar-9",
        "email": "sam@example.com",
        "label": "Joined webinar"
      }
    ]
  }'
Answer, status 201 (sample data)
{
  "data": [
    {
      "index": 0,
      "ok": true,
      "event": {
        "id": "2a9c7571-7c15-4e2b-8d44-5b6a7c8d9e0f",
        "created": true,
        "person_id": "2a847cfa-7c15-4e2b-8d44-5b6a7c8d9e0f"
      }
    },
    {
      "index": 1,
      "ok": true,
      "event": {
        "id": "2a9e0e8a-7c15-4e2b-8d44-5b6a7c8d9e0f",
        "created": true,
        "person_id": "2a9fa7a3-7c15-4e2b-8d44-5b6a7c8d9e0f"
      }
    }
  ],
  "request_id": "req_..."
}
Was this useful?

Your answer stays in this browser.

Last checked: Made from the live API rulesPlain MarkdownSomething wrong? Tell us