Preview — pending review
This reference is generated from the platform API contract and is still under review. Operations, fields, and descriptions can change before publication.
List roles in the active scope
Returns the built-in and custom IAM roles visible in the active tenant/subscription/project
scope, including each role's permission matrix (resourceKey → manage|read|none), assignable scope
levels, member count, and built-in/custom flag. Backs the Roles page route load (role cards plus the
per-role permission matrix panel). This single endpoint also serves search/filter/sort/pagination:
q matches role id, name and description; builtIn filters built-in vs custom roles; sort/order
accept role columns (name, members, updatedAt); page/pageSize paginate. No mutation occurs.
Validation: scopeId must reference a tenant/subscription/project scope the caller can
access (UNKNOWN_SCOPE → 404 via routing, no access → 403 FORBIDDEN); page/pageSize must be
positive integers and order one of asc|desc, otherwise 422 VALIDATION_FAILED.
Async & state: Synchronous read; no state change.
Errors: 401 when the session is missing or expired; 403 when the caller lacks iam:read in the
scope; 422 for malformed pagination/sort parameters; 500 on backend read-model failure.
Idempotency/Concurrency: Safe, cacheable; no idempotency key required. Supports ETag-based
revalidation of the collection snapshot.
bearerTokenAuthorizationBearer <token>An API token (pc_live_…) or a service-account key (sak_live_…), created in Identity & Access Management and sent as Authorization: Bearer <token>. Requests are rate limited per credential and per tenant: every response carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset, and a refused request gets 429 RATE_LIMITED with Retry-After.
scopeId*stringOpaque ownership+authorization scope resolving to tenant + subscription + project.
region?stringRestrict the result set to a single region.
^[a-z][a-z0-9-]{1,39}$q?stringFree-text search.
sort?stringField to sort by (entity-specific; defaults to the entity's natural order).
order?stringSort direction.
"asc""asc""desc"page?integer1-based page number.
1 <= value1pageSize?integerItems per page (max 200).
1 <= value <= 20050builtIn?booleanFilter to built-in roles (true) or custom roles (false).
assignableScope?stringOnly return roles assignable at the given scope level.
"subscription""project"Paginated collection of roles in the active scope.
application/json- response
data*array<>meta*Pagination envelope metadata. List responses are always { data, meta } — never a naked array.
curl -X GET "https://example.com/scopes/string/iam/roles"{ "data": [ { "id": "string", "name": "string", "description": "string", "custom": true, "members": 0, "assignableScopes": [ "tenant" ], "builtIn": true, "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "permissions": { "property1": "manage", "property2": "manage" } } ], "meta": { "page": 1, "pageSize": 1, "total": 0, "hasNext": true }}