v4

latestOpenAPI 3.1.1Apache 2.02026-07-31107278570.4 KB
Roles

Get role details

Retrieves complete information for a specific role including metadata and inheritance details (base role and dependent role count). Use this endpoint to audit role configuration and understand the role's place in the hierarchy. To view the role's permissions, use the ListRolePermissions endpoint.

get/api/v1/roles/{role_name}

Path parameters

role_namestring required

Unique name identifier of the role to retrieve. Must be alphanumeric with underscores, 1-64 characters.

Query parameters

includestring

Include additional data in the response. Valid values: 'permissions' (direct permissions only), 'permissions:all' (includes inherited permissions from role hierarchy)

Response

Successfully retrieved role details. Returns the role object including metadata and inheritance details. Permissions are not included.

Example response

{
  "role": {
    "default_creator": true,
    "default_member": true,
    "dependent_roles_count": 3,
    "description": "Can create, edit, and publish content but cannot delete or manage users",
    "display_name": "Content Editor",
    "extends": "admin_role",
    "id": "role_1234abcd5678efgh",
    "is_org_role": true,
    "name": "content_editor",
    "permissions": [
      {
        "description": "Read Content",
        "name": "read:content",
        "role_name": "admin_role"
      },
      {
        "description": "Write Content",
        "name": "write:content",
        "role_name": "editor_role"
      }
    ]
  }
}