Retention settings control how long Audit Log events are stored before being permanently deleted. You can configure the retention period on a per-organization basis.
Get the configured event retention period for the given Organization.
curl "https://api.workos.com/organizations/org_01EHZNVPK3SFK441A1RGBFSHRT/audit_logs_retention" \ --header "Authorization: Bearer sk_example_123456789"
GET/organizations /:id /audit_logs_retentionParameters Returns Set the event retention period for the given Organization.
curl --request PUT \ --url "https://api.workos.com/organizations/org_01EHZNVPK3SFK441A1RGBFSHRT/audit_logs_retention" \ --header "Authorization: Bearer sk_example_123456789" \ --header "Content-Type: application/json" \ -d @- <<'BODY' { "retention_period_in_days": 30 } BODY
PUT/organizations /:id /audit_logs_retentionParameters Returns