Audit logList audit events

List audit events

List audit events, filterable by role, decision, and source.

curl -X GET "https://api.autopil.ai/v1/audit/events?limit=100&agent_role=example_string&decision=ALLOW&source_id=example_string" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: YOUR_API_KEY"
[
  {
    "event_id": "example_string",
    "agent_role": "example_string",
    "agent_id": "example_string",
    "user_id": "example_string",
    "source_id": "example_string",
    "decision": "ALLOW",
    "policy_name": "John Doe",
    "reason": "example_string",
    "context_hash": "example_string",
    "source_type": "example_string",
    "pii_masked": true,
    "timestamp": "2024-12-25T10:00:00Z"
  }
]
GET
/v1/audit/events
GET
Base URLstring

Target server for requests. Edit to use your own host.

API Key (header: X-API-Key)
X-API-Keystring
Required

API key with admin, read, or evaluate scope. Missing key → 401; invalid or revoked key → 403.

API key with admin, read, or evaluate scope. Missing key → 401; invalid or revoked key → 403.
Request Preview
Response

Response will appear here after sending the request

Authentication

header
X-API-Keystring
Required

API Key for authentication. API key with admin, read, or evaluate scope. Missing key → 401; invalid or revoked key → 403.

Query Parameters

decisionstring
Allowed values:ALLOWDENY

Responses

event_idstring
agent_rolestring
agent_idstring
user_idstring
source_idstring
decisionstring
Allowed values:ALLOWDENY
policy_namestring
reasonstring
context_hashstring
source_typestring
pii_maskedboolean
timestampstring