Skip to content

Create logging export

POST
/api/admin/logging-policies/exports
Code sample: Shell / cURL
curl --request POST \
--url https://auth.example.com/api/admin/logging-policies/exports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "tenant_id": "tenant_123", "log_type": "security", "plane": "control", "format": "jsonl", "source": "catalog", "time_start": 1770000000, "time_end": 1770086400, "limit": 1000 }'

Creates an asynchronous logging export job, writes its message payload to R2, and returns polling URLs.

Media type application/json
object
tenant_key
string
tenant_id
string
log_type
string
plane
string
source
string
Allowed values: catalog record_index
format
string
Allowed values: jsonl csv zip
include_records
boolean
include_payload
boolean
detail_scope
string
Allowed values: none full
include_detail
boolean
time_start
integer
time_end
integer
limit
integer
idempotency_key
string
key
additional properties
Example
{
"tenant_id": "tenant_123",
"log_type": "security",
"plane": "control",
"format": "jsonl",
"source": "catalog",
"time_start": 1770000000,
"time_end": 1770086400,
"limit": 1000
}

Successful JSON response.

Media type application/json
object
result
required
object
key
additional properties
audit_id
One of:
string
job_id
string
key
additional properties
Example
{
"result": {
"id": "lexp_123",
"job_id": "lexp_123",
"message_job_id": "lmj_123",
"status": "queued",
"format": "jsonl",
"queued": true,
"queue_binding": "LOGGING_DELIVERY_BULK_QUEUE",
"polling": {
"export": "/api/admin/logging-policies/exports/lexp_123",
"message_job": "/api/admin/logging-policies/message-jobs/lmj_123"
},
"created_at": 1770000000000,
"expires_at": 1770604800000
},
"audit_id": "audit_123"
}

Error response.

Media type application/json
object
error
string
message
string
error_description
string
key
additional properties
Example generated
{
"error": "example",
"message": "example",
"error_description": "example"
}