v66

OpenAPI 3.1.0raw.githubusercontent.com2026-08-0174265626.3 KB
permissions

Delete role

Remove a role from your workspace. This also removes the role from all assigned API keys.

Important: This operation cannot be undone and immediately affects all API keys that had this role assigned.

Required Permissions

Your root key must have the following permission:

  • rbac.*.delete_role
post/v2/permissions.deleteRole

Request body

rolestring required

Unique identifier of the role to permanently delete from your workspace. Must either be a valid role ID that begins with 'role_' or the given role name and exists within your workspace.

WARNING: Deletion is immediate and irreversible with significant consequences:

  • All API keys assigned this role will lose the associated permissions
  • Access to resources protected by this role's permissions will be denied
  • Any authorization logic depending on this role will start failing
  • Historical analytics referencing this role remain intact

Before deletion, ensure:

  • You've updated any dependent authorization logic or code
  • You've migrated any keys to use alternative roles or direct permissions
  • You've notified relevant team members of the access changes

Example request

{
  "role": "role_dns_manager"
}

Response

Role deleted successfully

dataEmptyResponse required

Empty response object by design. A successful response indicates this operation was successfully executed.

Example response

{
  "meta": {
    "requestId": "req_123"
  }
}