OpenapiLegal
Publish a new per-realm custom agreement version.
Admin — requires `inject_identity` + `settings.manage` + `has_access_to_realm`. Unknown `agreementType` → 400; non-object/empty `content` → 400 (also enforced in the service). On success the service records an `agreement.published` audit event and returns the new version.
Admin — requires inject_identity + settings.manage + has_access_to_realm.
Unknown agreementType → 400; non-object/empty content → 400 (also
enforced in the service). On success the service records an
agreement.published audit event and returns the new version.
Path Parameters
realmId*string
Realm ID
agreementType*string
Agreement type: terms_of_service | privacy_policy
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
content*unknown
external_url?string|null
mode?null|
version_label?string|null
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X PUT "https://example.com/api/legal/admin/string/agreements/string" \ -H "Content-Type: application/json" \ -d '{ "content": null }'{ "effective_at": "2019-08-24T14:15:22Z", "external_url": "string", "mode": "full_text", "version_id": "9e94c502-ca41-4342-a7f7-af96b444512c", "version_no": 0}{ "code": "string", "details": null, "message": "string", "requestId": "string", "status": 0}{ "code": "string", "details": null, "message": "string", "requestId": "string", "status": 0}{ "code": "string", "details": null, "message": "string", "requestId": "string", "status": 0}{ "code": "string", "details": null, "message": "string", "requestId": "string", "status": 0}