Audit log
Security audit events for the workspace: sign-ins, member and role changes, API keys, settings changes, share links, exports and deletions. Poll the feed from a SIEM; needs the workspace.audit_log permission.
List audit events (SIEM feed)
/api/v1/audit-eventsPoll this from a SIEM. Events come oldest first; store next_cursor and pass it as cursor next time. Events appear about 5 seconds after they happen (the feed holds back the newest few seconds so a cursor never skips one). order=desc with before pages newest first instead. Needs the workspace.audit_log permission: owners and admins hold it, and a workspace API key created with permissions: ["workspace.audit_log"] can read the log and nothing else.
Query parameters
cursorstringReturn events after this cursor (from
next_cursor).sincestringOnly events at or after this time (ISO 8601). Use on the first poll instead of a cursor.
untilstringOnly events before this time (ISO 8601).
typestringComma-separated event types, or a whole category such as
member.*.- default 100
limitintegerEvents per page, at most 1000.
- default "asc"
orderone of "asc", "desc"asc(feed order) ordesc(newest first). beforestringWith
order=desc: events before this cursor.
Returns200 · object
eventsarray of objectRequired11 child fields
actorobjectRequired4 child fields
- nullable
api_key_idstringId of the API key or session that made the request. Never the key itself.
- nullable
emailstringThe actor's email at the time of the event.
typestringRequireduser,service_key(a workspace API key),kumkuat_staff(Kumkuat support acting in your workspace),systemoranonymous.- nullable
user_idstring
cursorstringRequiredThis event's position in the feed.
detailobjectEvent-specific fields, e.g. a setting's old and new value. Credentials are masked to their last four characters.
idstringRequiredGlobally unique event id (
evt_...). Use it to deduplicate.occurred_atstringRequiredUTC, ISO 8601.
outcomestringRequiredsuccessorfailure.- nullable
request_idstringTrace id of the request, for support.
sourceobjectRequired2 child fields
- nullable
ipstringClient IP address.
- nullable
user_agentstring
targetobjectRequired3 child fields
- nullable
idstring - nullable
namestring - nullable
typestringWhat was acted on:
member,invitation,api_key,workspace,document,share_link, ...
- for example "member.role_changed"
typestringRequiredEvent type; GET /api/v1/audit-events/types lists them.
- nullable
workspace_idstring
has_morebooleanRequiredTrue when another page is ready now; poll again immediately.
- nullable
next_cursorstringPass as
cursoron the next call. Null only when the call had no cursor and nothing matched. orderstringRequired
Download audit events as CSV
/api/v1/audit-events/export.csvEvery event from since (default: 30 days ago) to until (default: now) as CSV, oldest first. Takes the same type filter as the feed. Columns: occurred_at, type, outcome, actor_type, actor_email, actor_user_id, api_key_id, source_ip, user_agent, target_type, target_id, target_name, detail (JSON), id, request_id. Each download is recorded as an audit_log.exported event.
Responses
422Unprocessable Entity
curl https://api.kumkuat.ai/api/v1/audit-events/export.csv \
-H 'X-API-Key: <api key>'List audit event types
/api/v1/audit-events/typesEvery event type the audit log records, with what it means.
Returns200 · object
retention_daysintegerRequiredHow long events are kept.
typesarray of objectRequired3 child fields
categorystringRequireddescriptionstringRequiredtypestringRequired
Other responses
422Unprocessable Entity
curl https://api.kumkuat.ai/api/v1/audit-events/types \
-H 'X-API-Key: <api key>'{
"retention_days": 0,
"types": [