Skip to main content
The Permissions API provides fine-grained RBAC capabilities beyond the base roles (viewer, editor, admin). It supports custom roles with specific permission sets.

GET /api/v1/permissions

List all available permissions or resolve the current user’s effective permissions.

Query Parameters

ParameterTypeRequiredDescription
actionstringNolist to list all permissions, resolve to get current user’s permissions (default: resolve)

Response — resolve

{
  "role": "editor",
  "userId": "user_abc123",
  "permissions": [
    "offers.read",
    "offers.write",
    "channels.read",
    "channels.write",
    "decision_flows.read",
    "decision_flows.write"
  ],
  "totalPermissions": 6
}

Response — list

{
  "permissions": [
    "offers.read",
    "offers.write",
    "offers.delete",
    "channels.read",
    "channels.write",
    "decision_flows.read",
    "decision_flows.write",
    "decision_flows.publish",
    "users.manage",
    "settings.manage"
  ]
}

POST /api/v1/permissions

Assign a custom role to a user. Admin only.

Request Body

FieldTypeRequiredDescription
userIdstringYesUser ID to assign the role to
roleIdstringYesCustom role ID

Response (201)

{
  "id": "clx...",
  "userId": "user_abc123",
  "roleId": "role_marketing_editor",
  "tenantId": "my-tenant"
}