palbaseDocs

Palbase Auth API · API

GET/admin/audit/export

Export audit events

Streams the project's audit trail, oldest first, as NDJSON (one event per line, the shape of an AuditEvent) or CSV, optionally from one instant (inclusive) to another (exclusive) and of one event type. Personal data is decrypted, as in the list. The trail is read a page at a time, so its size is not a limit. The export itself is recorded (admin.audit.export). A failure after the answer has begun aborts the connection: a cut-short export is never delivered as a whole one.

Called by your server, with the project's secret key.

Query

format"ndjson" | "csv" · optionalndjson (default) or csv.
fromstring (date-time) · optionalOnly events at or after this instant (RFC 3339).
tostring (date-time) · optionalOnly events before this instant (RFC 3339); after from.
event_typestring · optionalOnly events of this type, e.g. auth.login.success.
curl
curl -X GET "https://<your-ref>.palbase.studio/admin/audit/export" \
  -H "apikey: $PALBASE_SECRET_KEY"

Responses

200The events, streamed as an attachment

400Validation failed or required field missing

401Missing, invalid, or expired credentials

403Authenticated but not permitted (banned, hook denial, role mismatch)

503Downstream dependency unavailable (typically HIBP / breach service)

defaultAn error: the envelope names it (`error`) and explains it (`error_description`).

Operation AdminExportAuditEvents of auth's contract.