Skip to content
Get an API key
Reference

Events

1 endpoints in this family.

Read the event log

GET/api/v1/events

Every event Nodium emits — the ones your webhooks receive — is also written to a numbered log, kept 30 days. Read it from a cursor instead of depending on webhook deliveries: the webhook is a doorbell, the log is the truth. Each entry is the webhook envelope (id, event, workspace_id, external_id, occurred_at, data) plus its seq.

Start without after: data is empty and next_after is the current head — store it as your first cursor. Then call with after set to the last next_after you kept, and repeat while next_after moves: a page may be empty and still move forward (events of other clients are skipped). When a call returns the same next_after you sent, you are up to date; come back when a webhook rings, or every minute. Keep next_after only after you have stored the page.

Entries come in seq order and none is skipped: an entry is returned only once every earlier one is settled, so a recent entry can appear a moment after the webhook that announced it. Deduplicate on id (a webhook delivery and the log carry the same one). seq is unique across the whole log, not per client: expect gaps.

A key that sees every client of the account reads all of them, unless the Nodium-Tenant header names one; a key pinned to one client reads that client only. Entries older than your plan's content retention keep their envelope but an empty data.

Query parameters

  • afterinteger

    The next_after of the previous call: return the entries after this position. Omit it to get the head only; 0 reads from the oldest entry kept.

  • limitinteger

    Entries per call, 1 to 500. Default 100.

Response

A page of events and the cursor to continue from.

  • data.dataobject[]

    The entries, by seq. Empty when after is omitted.

    Show fields
    • seqinteger

      The position in the log.

    • idstring

      The event id (evt_…), the same as in webhook deliveries.

    • eventstring

      The event name, for example message.received.

    • workspace_idstring

      The client where the event happened.

    • external_idstring

      Your id for that client, or null for "My company".

    • occurred_atstring

      When it happened (ISO 8601).

    • dataobject

      What the event carries; see the webhook event catalogue.

  • data.next_afterinteger

    Pass it as after on the next call. Every entry up to it was returned or is not yours to read.

Refusals

  • 410cursor_expired`after` is older than the oldest entry kept (30 days): some events were purged before you read them. Restart from `after=0`, or from the head.
  • 422invalid_request`after` is not a non-negative integer.
  • 404tenant_not_foundThe `Nodium-Tenant` header names no client this key can read.
curl https://nodium.io/api/v1/events \ -H "Authorization: Bearer $NODIUM_KEY"

Response

200 OK
{ "data": { "data": [ { "seq": 0, "id": "…", "event": "…", "workspace_id": "…", "external_id": "…", "occurred_at": "…", "data": {} } ], "next_after": 0 }}