Skip to content
Kapten
Esc
↑↓navigate↵open⌘Jpreview

Delete a custom Role

Requires ac:delete, and organization:delete for a Role that grants it. Deletes the Role’s Grants, Memberships and pending invitations; members holding no other Role leave the organization. Built-in Roles cannot be deleted (409).

DELETE/organizations/{organizationId}/roles/{roleId}
Authorization
AuthorizationBearer token (JWT) · headerrequired

An access token issued by this service (RFC 9068), in the Authorization header as Bearer <token>.

Path parameters
organizationIdstring<uuid>required
roleIdstring<uuid>required
Responses
204

The Role is deleted.

default

The request failed.

errorstringrequired

Stable machine-readable code.

Allowed:invalid_requestunauthorizedforbiddennot_foundconflictgoneunavailableinternal
messagestringrequired

Human-readable explanation.

Request
curl -X DELETE 'https://auth.kapten.io/organizations/497f6eca-6276-4993-bfeb-53cbbbba6f08/roles/497f6eca-6276-4993-bfeb-53cbbbba6f08' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Accept: application/json'
Response
The Role is deleted.