---
title: "List realm roles"
method: GET
path: "/clusters/{cluster_id}/realms/{realm_name}/roles"
tags: ["Realm Roles"]
---

# List realm roles

`GET /clusters/{cluster_id}/realms/{realm_name}/roles`

## Request

- Base URL: `http://localhost:8000`
- URL: `http://localhost:8000/clusters/{cluster_id}/realms/{realm_name}/roles`
- Auth: API key in header `API-Key`

Returns the roles defined in the specified realm.

Required scope: `realm-roles:read`

## Path parameters

- `cluster_id` string, uuid, required
- `realm_name` string, required: Keycloak realm name (not ID). Must start with a letter; allows letters, digits, and hyphens.

## Headers

- `API-Version` '2026-06-01.beta', required

## Response `200`

The request has succeeded.

- RealmRole[]
  - `name` string, required: Role name.
  - `description` string, nullable: Human-friendly role description, when available.
  - `composite` boolean: Whether this role is composed from other roles.
  - `client_role` boolean: Whether this is a client-scoped role rather than a realm-scoped role.

## Other responses

- `401`: Access is unauthorized.
- `403`: Access is forbidden.
- `404`: The server cannot find the requested resource.
- `429`: Client error
- `500`: Server error
- `501`: Server error

---

[API](https://skmtc.dev/skycloak/apis/skycloak-public-api.md) · [All operations](https://skmtc.dev/skycloak/apis/skycloak-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/skycloak/apis/skycloak-public-api/revisions/33a69e2ce35f?raw)
