/filters/users - Get aggregated user filters

GET /filters/users

Aggregated endpoint that returns all user filter data in a single request. Auth is checked once, then roles and organizations are fetched in parallel. Respects RBAC hierarchy for both roles and organizations.

Responses

  • 200 application/json

    User filters retrieved successfully

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object
      Hide data attributes Show data attributes object
      • roles array[object]
        Hide roles attributes Show roles attributes object
        • id string

          Role ID

        • name string

          Role name

        • description string

          Role description

      • organizations array[object]
        Hide organizations attributes Show organizations attributes object
        • id string

          Organization Logto ID

        • name string

          Organization name

        • type string

          Organization type

          Values are distributor, reseller, or customer.

  • 401 application/json

    Unauthorized - invalid or missing token

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object | null
  • 403 application/json

    Forbidden - insufficient permissions

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object | null
GET /filters/users
curl \
 --request GET 'https://api.your-domain.com/api/filters/users' \
 --header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "code": 200,
  "data": {
    "roles": [
      {
        "id": "role_abc123",
        "name": "Admin",
        "description": "System administrator"
      },
      {
        "id": "role_def456",
        "name": "Support",
        "description": "Support operator"
      }
    ],
    "organizations": [
      {
        "id": "org_abc123",
        "name": "ACME Corp",
        "type": "customer"
      },
      {
        "id": "org_def456",
        "name": "TechStart Inc",
        "type": "reseller"
      }
    ]
  },
  "message": "user filters retrieved successfully"
}
Response examples (401)
{
  "code": 401,
  "message": "invalid token",
  "data": {}
}
Response examples (403)
{
  "code": 403,
  "message": "insufficient permissions",
  "data": {}
}