Update audit retention settings
PUT
/api/admin/settings/audit-storage/retention
Code sample: Shell / cURL
curl --request PUT \ --url https://auth.example.com/api/admin/settings/audit-storage/retention \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "eventLogRetentionDays": 180, "piiLogRetentionDays": 365, "archiveBeforeDelete": true }'Updates managed audit retention settings after validating retention ranges and archival behavior.
Authorizations
Section titled “Authorizations ”Request Body required
Section titled “Request Body required ”Audit retention configuration patch.
Media type application/json
object
eventLogRetentionDays
integer
piiLogRetentionDays
integer
archiveBeforeDelete
boolean
minimumRetentionDays
integer
key
additional properties
Example
{ "eventLogRetentionDays": 180, "piiLogRetentionDays": 365, "archiveBeforeDelete": true}Responses
Section titled “ Responses ”Successful JSON response.
Media type application/json
object
success
boolean
config
object
eventLogRetentionDays
integer
piiLogRetentionDays
integer
archiveBeforeDelete
boolean
minimumRetentionDays
integer
key
additional properties
source
string
profile_id
string
note
string
key
additional properties
Example
{ "success": true, "config": { "eventLogRetentionDays": 180, "piiLogRetentionDays": 365, "archiveBeforeDelete": true }, "source": "runtime_profile", "profile_id": "managed-audit-profile", "note": "Retention configuration updated via the managed audit profile."}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"}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"}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"}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"}