List events
const url = 'http://127.0.0.1:9090/api/tenants/acme/events?after=4180&limit=100&endpoint=office&device=CG0001&type=punch&since=2026-01-15T00%3A00%3A00Z&until=2026-01-16T00%3A00%3A00Z&user_id=1001';const options = { method: 'GET', headers: { 'X-Request-Id': '4f1c2b0e-8a7d-4c51-9e2f-3a6b8d0c1e7f', Authorization: 'Basic <credentials>' }};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'http://127.0.0.1:9090/api/tenants/acme/events?after=4180&limit=100&endpoint=office&device=CG0001&type=punch&since=2026-01-15T00%3A00%3A00Z&until=2026-01-16T00%3A00%3A00Z&user_id=1001' \ --header 'Authorization: Basic <credentials>' \ --header 'X-Request-Id: 4f1c2b0e-8a7d-4c51-9e2f-3a6b8d0c1e7f'The events stored, oldest first, a page at a time, each with the sequence number it was stored under (seq).
An event is never returned before every event with a lower seq is in place, so reading on from next skips
nothing: pass the answer’s next as after. A page with no events means there are none newer yet, and next
stays where it was. Events are kept for retention_days once every sink they go to has taken them, and until it
does while one has not.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The tenant’s id.
Example
acmeQuery Parameters
Section titled “Query Parameters”Only events after the one with this sequence number: pass the next
of the previous answer to carry on from it. Default 0, from the
oldest kept.
Example
4180At most this many events: 100 unless given, at most 1000 (more is read as 1000).
Example
100Only this endpoint’s events.
Example
officeOnly this device’s events: its id, as its package identifies it.
Example
CG0001Only events of this type (“punch”, “user”, …).
Example
punchOnly events received at or after this time (RFC 3339). With
until, the days outside are not read at all: events are kept by
the day they were received.
Example
2026-01-15T00:00:00ZOnly events received before this time (RFC 3339): later than
since.
Example
2026-01-16T00:00:00ZOnly events whose data names this person ("user_id"): punches,
enrolments. Looked for in the events the other filters leave (no
index): bound it with since, or a device, on a large store.
Example
1001Header Parameters
Section titled “Header Parameters”An id to follow the request by: answered back in X-Request-Id, and in the log, the audit trail and the events the request causes. 1 to 128 letters, digits, -, _, . or :; anything else is replaced by a new id.
Example
4f1c2b0e-8a7d-4c51-9e2f-3a6b8d0c1e7fResponses
Section titled “Responses”A page of events, oldest first.
A page of stored events.
object
The events, oldest first.
An event as it is kept: with the sequence number it was stored under.
object
The type’s fields.
object
The device’s id: whatever its package identifies it by (a serial number, a MAC address, a cloud id); “” for an event about a whole job (job., but not job.execution.) or a sync group; for an event a system posted, what it is about, as posted (“” when it named nothing); for Time and Attendance’s own, the person or timecard it is about.
The endpoint the device belongs to, by its id within the tenant; “sync:
The sync group of the endpoint (every endpoint is in one, its own unless it names one), by its id within the tenant; for a group’s own events, that group. Absent for an endpoint no longer configured, and for events of another engine.
Stable idempotency key, 32 hex digits: the same device record always gets the same id, and an event a system posted (endpoint “source:
The package that read it, “name@version”; for the gateway’s own events about a device, that device’s package; “houradvantage-connect” for a job’s or sync group’s own events; for an event a system posted, its source; “houradvantage-attend” for Time and Attendance’s own.
Connect’s own id of the person the event is about (data.user_id) in its group: opaque, and kept when the person’s user id changes. Present when the group keeps people and has the person.
To a sink with person_id only: the id, in the system the sink names, of the person the event is about (data.user_id), from the person’s external_ids; absent when they have none there.
When the gateway received it (for the gateway’s own events, when it made them), RFC 3339 UTC.
The admin API request that caused the event, made while it ran: a change made through the API, an event posted through it. Absent for an event no request caused: a device’s message, a job’s waves, Time and Attendance working a ledger out. A request id is a correlation id only: the caller may have chosen it.
object
The request’s id: the X-Request-Id it was answered with, and that its audit trail entry and log lines carry.
The Idempotency-Key it was sent with, if any.
Who made the request, as the server named them from its login or token, never as the caller says: the login’s user, or token:
The version of this contract the event follows.
The tenant the event belongs to: in Connect’s events, the Connect tenant its endpoint is of (or that it was posted into); in Time and Attendance’s, the Time and Attendance tenant. Events of the source “attendance” in Connect’s log say “default” but are no Connect tenant’s: only install-level sinks that name the source are sent them, and they stay in the log until those sinks have taken them, then retention removes them as any event. Time and Attendance keeps its own events in a log of its own.
The event type; the event reference describes each.
The sequence number it was stored under, one order across the whole
install. Read on from it with after.
The seq of the last event on the page, or the after asked for
when the page is empty: pass it as after for the next page.
Example
{ "events": [ { "data": { "dst_ambiguous": false, "local_time": "2026-01-15 08:00:00", "state_name": "check_in", "time": "2026-01-15T08:00:00-06:00", "time_zone": "America/Chicago", "user_id": "1001", "utc_offset": "-06:00", "verify_name": "fingerprint", "zoned": "2026-01-15T08:00:00-06:00[America/Chicago]" }, "device": "CG0001", "endpoint": "office", "id": "3f2a9c1e7b6d4a0f8e5c2b1a9d8c7e6f", "received_at": "2026-01-15T14:00:02Z", "schema": 3, "seq": 4181, "tenant": "default", "type": "punch" } ], "next": 4181}until is not later than since.
A refusal, and why.
object
Why the request was refused, in a sentence.
For a request whose parameters do not fit (422): what is wrong with each field. Absent otherwise.
What is wrong with one field of a request.
object
The parameter, as the request names it (values.volume for a
setting inside values).
What is wrong with it.
The request’s id, as its X-Request-Id header gives it: what to
quote when asking what happened to it.
Example
{ "error": "until must be later than since"}A login is configured and the request carries neither it nor an API token, or it carries a wrong login (WWW-Authenticate: Basic realm="Hour Advantage", no body). Or the request carries an API token that is not one (revoked, or never made), login or not (WWW-Authenticate: Bearer realm="Hour Advantage", error="invalid_token", the body the API token was refused).
Example
the API token was refusedHeaders
Section titled “Headers”The scheme to answer with: Basic realm="Hour Advantage", or for a refused token Bearer realm="Hour Advantage", error="invalid_token".
The Host header does not name a loopback address while one is required (no login configured, or the API listens on loopback), or the Origin header does not match the Host: {"error": ...} says which. Or no login is configured and the request carries Forwarded, X-Forwarded-For or X-Real-IP (a proxy forwarded it): the plain text body says so. Or an API token asks for a route its scope does not reach: the plain text body says so.
A refusal, and why.
object
Why the request was refused, in a sentence.
For a request whose parameters do not fit (422): what is wrong with each field. Absent otherwise.
What is wrong with one field of a request.
object
The parameter, as the request names it (values.volume for a
setting inside values).
What is wrong with it.
The request’s id, as its X-Request-Id header gives it: what to
quote when asking what happened to it.
Example
{ "error": "the Host must name this machine (localhost or a loopback address); an API reached by other names needs the admin login"}Example
a forwarded request needs the admin login; none is setMore than 2 admin logins are being checked at once: send the request again after the Retry-After seconds. A request carrying the login that checked out last, or an API token, is not held up.
Example
too many logins at once; try againHeaders
Section titled “Headers”Seconds to wait: 1.
Something went wrong in the gateway that asking again will not put right by itself; error says what.
A refusal, and why.
object
Why the request was refused, in a sentence.
For a request whose parameters do not fit (422): what is wrong with each field. Absent otherwise.
What is wrong with one field of a request.
object
The parameter, as the request names it (values.volume for a
setting inside values).
What is wrong with it.
The request’s id, as its X-Request-Id header gives it: what to
quote when asking what happened to it.
Example
{ "error": "db error: ERROR: permission denied for table settings"}The database cannot be used right now (not reachable, too busy, no connection free in time), or the instance is still starting: send the same request again shortly. An API token that cannot be checked for the same reason is answered 503 in plain text (the API token cannot be checked right now; try again shortly).
A refusal, and why.
object
Why the request was refused, in a sentence.
For a request whose parameters do not fit (422): what is wrong with each field. Absent otherwise.
What is wrong with one field of a request.
object
The parameter, as the request names it (values.volume for a
setting inside values).
What is wrong with it.
The request’s id, as its X-Request-Id header gives it: what to
quote when asking what happened to it.
Example
{ "error": "the gateway is starting; try again shortly"}