Skip to content
Docs
Operation

List User-Account Roles

GET/user-accounts
Get all user-account-role assignments across your organisation. This shows the complete picture of who has access to what. Each result includes the user, the account they have access to, and which role(s) they hold for that account. Useful for auditing permissions or building admin interfaces.

When to use this

  • Auditing who has access to which accounts
  • Building a permissions management dashboard
  • Exporting access lists for compliance

Returns

Role assignments retrieved successfully

Errors

400
Bad Request - Invalid input
401
Unauthorized - Authentication required
403
Forbidden - Insufficient permissions
404
Not Found - Resource not found
500
Internal Server Error

Every error names its code and links to it. All error codes

Notes

Note
Returns all assignments-use filters to narrow down results for specific users or accounts.
Tip
For a simpler view, try listUserAccountRolesByUser or listUserAccountRolesByAccount.

Related

import { BackstageClient } from '@ticketlayer/backstage';const client = new BackstageClient({  organisationSlug: 'your-org',});client.setAccessToken('YOUR_ACCESS_TOKEN');// List useraccountrolesconst { useraccountroles, pagination } = await client.useraccountroles.list({  limit: 20,  page: 1,});for (const item of useraccountroles) {  console.log(`${item.id}: ${item.name || item.id}`);}console.log(`Page ${pagination.page} of ${pagination.totalPages}`);
Response 200
{
  "assignments": [
    {
      "id": "uar_abc123",
      "organisationId": "org_xyz789",
      "userId": "usr_abc123",
      "accountId": "acc_xyz789",
      "roleId": "rol_system_event_manager",
      "createdAt": "2024-01-15T10:30:00Z",
      "user": {
        "id": "string",
        "email": "string",
        "firstName": "string",
        "lastName": "string"
      },
      "account": {
        "id": "string",
        "name": "string"
      },
      "role": {
        "id": "string",
        "name": "string",
        "isSystemRole": true
      }
    }
  ]
}

Try it in test mode