List roles
⚠️
Preview — this feature is being built; the design below is the spec.
GET https://app.syntic.ai/v1/compliance/rolesReturn the roles defined in the organization and what each allows, so an export can show what a person was entitled to do.
For how this fits into a full workflow, see Compliance API.
Headers
| Header | Required | Value |
|---|---|---|
Authorization | Yes | Bearer <admin key>: an Admin API key (sk_admin_...) that carries the compliance:read scope (plus compliance:write for deletions and holds). Enterprise plans only. See Compliance API. |
syntic-beta | Yes, while in preview | compliance-2026-12-01. Without it the call fails with 400 beta_required. See Versioning. |
Query parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
limit | integer | 20 | 1 to 100. |
after_id | string | Next page: the previous page’s last_id. | |
before_id | string | Previous page: the previous page’s first_id. |
Response
200 OK, Content-Type: application/json
{
"data": [
{
"id": "role_01JCT6U8W0Y2A4C6E8G0",
"type": "role",
"name": "developer",
"scope": "organization",
"permissions": [
"api_keys:own",
"workspaces:use",
"console:read"
],
"member_count": 41
}
],
"has_more": false,
"first_id": "role_01JCT6U8W0Y2A4C6E8G0",
"last_id": "role_01JCT6U8W0Y2A4C6E8G0"
}| Field | Type | Description |
|---|---|---|
scope | string | organization or workspace. |
permissions | array | Permission strings granted by the role. |
Examples
curl -sS "https://app.syntic.ai/v1/compliance/roles" \
-H "Authorization: Bearer $SYNTIC_ADMIN_KEY" \
-H "syntic-beta: compliance-2026-12-01"Errors
Errors use the error envelope and carry a request_id. Codes specific to this operation:
| Status | type | code | When |
|---|---|---|---|
| 400 | invalid_request_error | beta_required | The syntic-beta header is missing. |
| 401 | authentication_error | invalid_api_key | The admin key is missing, unknown, revoked or expired. |
| 403 | permission_error | admin_key_required | An inference key was used. |
| 403 | permission_error | scope_missing | The admin key lacks the compliance:read (or, for writes, compliance:write) scope. |
| 429 | rate_limit_error | rate_limited | Too many requests; wait for Retry-After. See Rate-limit headers. |
Was this page helpful?