List RBAC Roles

GET /v1/endpoints/{uuid}/rbac/roles

List the roles defined on this endpoint. Roles are named permission bundles assigned to RBAC clients via memberships — they decide which HTTP methods and paths each authenticated visitor is allowed to use, and an optional per-role rate limit.

A role's permissions is a structured object (allow/deny method & path lists), not a flat list of permission keys.

Path parameters

uuid string (uuid) Req
The endpoint's uuid from /endpoints.

Response (200 OK)

JSON array of role objects ([] when the endpoint has none):

uuid string (uuid)
The role's public id. Used in nested URLs (/rbac/roles/{role_uuid}) and in membership bodies (role_uuid).
name string
Role name (unique per endpoint).
description string?
Free-form description shown in the dashboard. Omitted when empty.
priority int
Ordering weight used when a client holds multiple roles (higher priority wins conflicts).
is_default boolean
Whether new RBAC clients (created via API or through self-registration) get this role auto-assigned.
permissions object
Structured allow/deny policy. Fields: allowed_methods, denied_methods (string arrays, upper-cased), allowed_paths, denied_paths (string arrays), rate_limit_rps (int64), headers & metadata (string maps). Omitted sub-fields default to empty/none.
created_at, updated_at datetime
RFC 3339 UTC.

Deprecated: until the sunset this response also carries the legacy integer id and *_id fields. Don't use them; read uuid and the *_uuid fields.

To count members per role, query /rbac/memberships; member counts are not embedded here.

Errors

401 Unauthorized
Missing auth.
403 Forbidden
Caller lacks the endpoints:read permission in the active account.
404 Not Found
Endpoint doesn't exist or doesn't belong to the calling account.
Request
curl "https://api.ngris.com/v1/endpoints/019bb1e4-e785-77d2-9966-c3cff31d0a0e/rbac/roles" \ -H "X-API-KEY: <your_api_key>"
Python
from ngris import Ngris client = Ngris(api_key="<your_api_key>") for r in client.endpoint_rbac.list_roles("019bb1e4-e785-77d2-9966-c3cff31d0a0e"): badge = " (default)" if r["is_default"] else "" perms = r.get("permissions", {}) print(f"{r['name']}{badge}: {perms.get('allowed_methods', [])}")
Response — 200 OK
[ { "uuid": "019b5fc1-0eb5-7dd8-a0e9-a575428f890d", "name": "admin", "description": "Full access", "priority": 100, "is_default": false, "permissions": {}, "created_at": "2026-04-01T00:00:00Z", "updated_at": "2026-04-01T00:00:00Z" }, { "uuid": "019b6243-8510-7cbb-a69c-6e29c89b0d65", "name": "readonly", "description": "GET-only access", "priority": 10, "is_default": true, "permissions": { "allowed_methods": ["GET", "HEAD"], "denied_paths": ["/admin"], "rate_limit_rps": 20 }, "created_at": "2026-04-01T00:00:00Z", "updated_at": "2026-04-01T00:00:00Z" } ]
Was this helpful?
On this page
List RBAC Roles
Was this helpful?