Customer-facing audit log: every mutating API request on the account with its actor (user session, M2M client, API key, or impersonating staff), newest first. Reads are capped to the last 90 days. Super admin, admin, or auditor role required, since the log exposes other members' actions and request IPs; audit read is the whole point of the auditor role (Datadog's Audit Trail Read is the precedent).
const url = 'https://api.siteqwality.com/account/audit_log?actor_type=session';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.siteqwality.com/account/audit_log?actor_type=session' \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Query Parameters
Section titled “Query Parameters ”Only entries performed by this user.
Only entries performed by this API key.
Who performed an audited action. Mirrors customer_audit_log.actor_type.
Only entries with this actor type.
Action name, matched exactly or as a dot-prefix: http.job also
matches http.job.regions, but never http.jobs.
Only entries targeting this resource kind (first path segment).
Only entries targeting this resource id.
RFC3339; clamped to the read window.
RFC3339; inclusive upper bound.
Row cap, clamped to 1..=1000 (default 100).
Responses
Section titled “ Responses ”Audit log entries (last 90 days)
object
One row in the customer audit-log list response. request_ip is
stringified for JSON transport (Postgres INET round-trips as
IpNetwork).
object
The API key that acted, when actor_type is api_key. Null on rows
written before attribution landed (2026-08-06).
The key’s friendly name at read time (keys are revoked, never deleted, so this resolves for historical rows too).
Staff user id when the action was performed under impersonation.
Days of history the endpoint serves; older rows are not returned.
Example generated
{ "entries": [ { "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "occurred_at": "2026-04-15T12:00:00Z", "actor_type": "example", "actor_user_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "actor_api_key_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "actor_api_key_name": "example", "actor_m2m_client_id": "example", "impersonated_by": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "action": "example", "target_kind": "example", "target_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "http_method": "example", "http_path": "example", "http_status": 1, "request_ip": "example", "user_agent": "example" } ], "read_window_days": 1}Missing or invalid authentication
Caller lacks a role able to read the audit log (super admin, admin, or auditor)
Internal server error