Trillet AI logo

Get Role

Retrieve a specific role by its ID.

GEThttps://api.trillet.ai/v1/api/roles-and-permissions/roles/{roleId}

Headers

x-api-keystringrequired

API key used for authenticating requests to the API.

x-workspace-idstringrequired

Workspace identifier for the API.

Path Parameters

roleIdstringrequired

The unique identifier of the role.

Response Fields

_idstring

Unique identifier for the role.

namestring

Name of the role.

descriptionstring

Description of the role.

permissionsarray

Array of permission objects assigned to the role.

userIdsarray

Array of user IDs assigned to this role.

{
  "_id": "665a1b2c3d4e5f6a7b8c9d0e",
  "name": "Agent Manager",
  "description": "Can manage agents and view call history",
  "permissions": [
    { "key": "agent_view", "category": "agents" },
    { "key": "agent_create", "category": "agents" },
    { "key": "agent_edit", "category": "agents" }
  ],
  "userIds": ["user_001"]
}