Governance
Update an organization retention policy
PATCH /v1/organizations/{id}/retention-policy · SDK updateOrganizationRetentionPolicy · CLI deployments governance retention-update
PATCH
Requires governance:write.
platformBearerheader
AuthorizationBearer <token>Platform bearer credential accepted as an opaque API key or JWT.
id*stringMatch
^[0-7][0-9A-HJKMNP-TV-Z]{25}$x-deployments-organization*stringMatch
^[0-7][0-9A-HJKMNP-TV-Z]{25}$idempotency-key*stringLength
1 <= length <= 512application/json- body
Properties
1 <= propertiesartifacts?integerRange
1 <= value <= 3650audit?integerRange
365 <= value <= 3650events?integerRange
1 <= value <= 3650messages?integerRange
1 <= value <= 3650runs?integerRange
1 <= value <= 3650threads?integerRange
1 <= value <= 3650OrganizationRetentionPolicyResponse
application/json- response
artifacts*integerRange
1 <= value <= 3650audit*integerRange
365 <= value <= 3650events*integerRange
1 <= value <= 3650messages*integerRange
1 <= value <= 3650runs*integerRange
1 <= value <= 3650threads*integerRange
1 <= value <= 3650createdAt*stringMatch
^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$Format
date-timeorganizationId*stringMatch
^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$updatedAt*stringMatch
^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$Format
date-timeupdatedByPrincipalId*stringMatch
^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$version*integerRange
0 <= valuecurl -X PATCH "https://example.com/v1/organizations/string/retention-policy" \ -H "x-deployments-organization: string" \ -H "idempotency-key: string" \ -H "Content-Type: application/json" \ -d '{}'{ "artifacts": 1, "audit": 365, "events": 1, "messages": 1, "runs": 1, "threads": 1, "createdAt": "2019-08-24T14:15:22Z", "organizationId": "string", "updatedAt": "2019-08-24T14:15:22Z", "updatedByPrincipalId": "string", "version": 0}