API ReferenceAudit
Export Audit Events
Bulk export audit events as CSV or JSONL and receive a signed download URL.
Endpoint
POST /v1/audit/events:exportBase URL: https://<Domain id="api"/>
Authentication: Bearer token with audit:export scope.
Creates a background export job. The response contains a polling URL; once ready, fetch the signed download URL. Export files are retained for 7 days.
Request Body
{
"start_time": "2026-04-01T00:00:00Z",
| Field | Type | Required | Description |
|---|---|---|---|
start_time | RFC 3339 | Yes | Range start (inclusive) |
end_time | RFC 3339 | Yes | Range end (exclusive) |
filter | string | No | Filter DSL |
format | enum | Yes | "CSV" | "JSONL" |
organization_id | string | No | Scope to one org |
Example
body := strings.NewReader(`{"start_time":"2026-04-01T00:00:00Z","end_time":"2026-04-17T00:00:00Z","format":"JSONL"}`)
req, _ := http.NewRequest("POST",
"https://api-id.avnology.net/v1/audit/events:export", body)
req.Header.Set
import httpx, os
res = httpx.post(
"https://api-id.avnology.net/v1/audit/events:export",
json={
"start_time": "2026-04-01T00:00:00Z",
"end_time": "2026-04-17T00:00:00Z",
"format"
curl -X POST "https://api-id.avnology.net/v1/audit/events:export" \
-H "Authorization: Bearer $AVNOLOGY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"start_time": "2026-04-01T00:00:00Z",
"end_time": "2026-04-17T00:00:00Z",
"format": "JSONL"
}'body := strings.NewReader(`{"start_time":"2026-04-01T00:00:00Z","end_time":"2026-04-17T00:00:00Z","format":"JSONL"}`)
req, _ := http.NewRequest("POST",
"https://api-id.avnology.net/v1/audit/events:export", body)
req.Header.Set
import httpx, os
res = httpx.post(
"https://api-id.avnology.net/v1/audit/events:export",
json={
"start_time": "2026-04-01T00:00:00Z",
"end_time": "2026-04-17T00:00:00Z",
"format"
curl -X POST "https://api-id.avnology.net/v1/audit/events:export" \
-H "Authorization: Bearer $AVNOLOGY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"start_time": "2026-04-01T00:00:00Z",
"end_time": "2026-04-17T00:00:00Z",
"format": "JSONL"
}'body := strings.NewReader(`{"start_time":"2026-04-01T00:00:00Z","end_time":"2026-04-17T00:00:00Z","format":"JSONL"}`)
req, _ := http.NewRequest("POST",
"https://api-id.avnology.net/v1/audit/events:export", body)
req.Header.Set
import httpx, os
res = httpx.post(
"https://api-id.avnology.net/v1/audit/events:export",
json={
"start_time": "2026-04-01T00:00:00Z",
"end_time": "2026-04-17T00:00:00Z",
"format"
curl -X POST "https://api-id.avnology.net/v1/audit/events:export" \
-H "Authorization: Bearer $AVNOLOGY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"start_time": "2026-04-01T00:00:00Z",
"end_time": "2026-04-17T00:00:00Z",
"format": "JSONL"
}'body := strings.NewReader(`{"start_time":"2026-04-01T00:00:00Z","end_time":"2026-04-17T00:00:00Z","format":"JSONL"}`)
req, _ := http.NewRequest("POST",
"https://api-id.avnology.net/v1/audit/events:export", body)
req.Header.Set
import httpx, os
res = httpx.post(
"https://api-id.avnology.net/v1/audit/events:export",
json={
"start_time": "2026-04-01T00:00:00Z",
"end_time": "2026-04-17T00:00:00Z",
"format"
Response (202 Accepted)
{
"export_id": "exp_01H7X3K9Q1",
"status": "pending",
"status_url": "/v1/audit/exports/exp_01H7X3K9Q1",
"expires_at": "2026-04-24T00:00:00Z"
}Poll the status_url until status == "completed". The final response includes download_url (signed, 24h validity).