GET /users
List users
Returns a paginated list of unified users accessible to the caller, optionally filtered by account. When accountId is provided, only users belonging to that account are returned. Always returns 200 with an empty entities array when no matches are found — never 404.
Results are limited to accounts the caller may view.
Pagination. Cursor-based. Pass the cursor value from the response to retrieve the next page; a null cursor means this is the last page. The cursor is opaque — do not parse, construct or modify it, and do not assume it encodes a page number or an offset. It marks a position in the result order rather than a distance from the start, so paging remains equally fast however deep the traversal goes and there is no ceiling on how far it can run.
A cursor is only valid for the exact request that produced it. Changing accountId, sortBy or sortOrder while replaying a cursor returns 400; restart the traversal without a cursor instead. Changing pageSize mid-traversal is allowed.
Consistency. This list is served from a read model that is updated shortly after a write, so a user created, changed or deleted moments ago may not be reflected yet. GET /users/{id} is always up to date. A page is not a snapshot: because writes are applied while a traversal is in progress, a user whose sort position changes mid-traversal may be seen twice or not at all in that traversal. Re-read the list, or fetch a user by ID, when an exact result matters.
Authentication
OAuth 2.0. Required scope(s): users:manage.
Request
Path parameters
None.
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
accountId |
string (uuid) | no | The unified account ID to filter users by. Omit to return all users accessible to the caller. |
cursor |
string | no | The cursor value returned from a previous paginated request. Used to retrieve the next page of results. When not provided, the first page of results is returned. Opaque — do not parse or modify this value. |
pageSize |
integer | no | The number of items to return per page. Used in conjunction with cursor for pagination. Default is 100, valid range between 1 and 200. |
sortBy |
string | no | Field to sort results by. One of createdAt, lastName, firstName. Defaults to createdAt. |
sortOrder |
string | no | Sort direction. One of asc, desc. Defaults to asc. |
Send
accountIdexplicitly. Although the parameter is optional, omitting it can return a400. Filter by account on every call, and handle a400if you do request the unfiltered list.
Headers
None.
Responses
200 — Users retrieved successfully
Returns an empty entities array when no users match the filter — never a 404. Also returned when the caller may not view the requested account, so that this operation cannot probe which account IDs exist.
Content-Type: application/json
Schema: UnifiedUserCollection
| Field | Type | Required | Description |
|---|---|---|---|
entities |
array of UnifiedUser | yes | The list of matching users. Empty array when no matches are found. |
cursor |
string or null | no | Cursor value to retrieve the next page of results. Null if there are no more pages. Opaque — do not parse or modify this value. |
pageSize |
integer | yes | Number of items per page |
count |
integer (int64) | no | Total number of users matching the request across all pages, not just this one. Divide by pageSize to obtain the number of pages. |
Example:
{
"cursor": "eyJ2IjoiMSIsImIiOiI5ZjNhIiwicyI6WyJEb2UiLCJmNjIwIl19",
"pageSize": 100,
"count": 1284,
"entities": [
{
"id": "f6201f5f-7fc0-49c8-a84f-eac6e6f1f950",
"accountId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"firstName": "Jane",
"lastName": "Doe",
"createdAt": "2026-03-15T14:22:00.000000Z",
"updatedAt": "2026-03-18T09:15:30.000000Z"
},
{
"id": "b8a3d1e2-4c5f-6789-0abc-def123456789",
"accountId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"firstName": "John",
"lastName": "Smith",
"createdAt": "2026-03-16T08:00:00.000000Z",
"updatedAt": null
}
]
}
400 — Invalid query parameter
Returned when accountId is missing or not a UUID, sortBy or sortOrder is not an allowed value, pageSize is not an integer between 1 and 200, or cursor is malformed or was issued for a different account, sort field or sort order.
Content-Type: application/problem+json
Schema: ProblemDetails
Example:
{
"type": "https://problems-registry.smartbear.com/bad-request",
"title": "Bad Request",
"status": 400,
"detail": "accountId must be a valid UUID: not-a-uuid",
"instance": "/users",
"traceId": "6d4a3a62-0d4b-4b96-9171-8c5070e01c35"
}
401 — Unauthorized
The OAuth token is missing, invalid, or carries no urn:alianza:claims:principal_id claim. Authentication is required via bearer token.
Content-Type: application/problem+json
Schema: ProblemDetails
Example:
{
"type": "https://problems-registry.smartbear.com/unauthorized",
"title": "Unauthorized",
"status": 401,
"detail": "Missing or invalid bearer token.",
"instance": "/users",
"traceId": "6d4a3a62-0d4b-4b96-9171-8c5070e01c35"
}
403 — Forbidden - The access token does not hold the users:manage scope. A caller that holds the scope but may not view the account receives an empty 200, not a 403
Content-Type: application/problem+json
Schema: ProblemDetails
Example:
{
"type": "https://problems-registry.smartbear.com/forbidden",
"title": "Forbidden",
"status": 403,
"detail": "The caller is not permitted to perform this operation.",
"instance": "/users",
"traceId": "6d4a3a62-0d4b-4b96-9171-8c5070e01c35"
}
429 — Too many requests. The client has exceeded the rate limit for this API.
Content-Type: application/problem+json
Schema: ProblemDetails
Example:
{
"title": "Too Many Requests",
"status": 429,
"detail": "Rate limit exceeded. Please slow down and try again.",
"instance": "/users",
"traceId": "6d4a3a62-0d4b-4b96-9171-8c5070e01c35"
}
500 — Unexpected server error. detail is always this fixed generic message.
Content-Type: application/problem+json
Schema: ProblemDetails
Example:
{
"type": "https://problems-registry.smartbear.com/server-error",
"title": "Internal Server Error",
"status": 500,
"detail": "An unexpected error occurred while processing your request.",
"instance": "/users",
"traceId": "6d4a3a62-0d4b-4b96-9171-8c5070e01c35"
}
503 — Service temporarily unavailable, including when the authorization service cannot be reached, which fails closed
Content-Type: application/problem+json
Schema: ProblemDetails
Example:
{
"type": "https://problems-registry.smartbear.com/service-unavailable",
"title": "Service Unavailable",
"status": 503,
"detail": "The service is temporarily unavailable. Please try again later.",
"instance": "/users",
"traceId": "6d4a3a62-0d4b-4b96-9171-8c5070e01c35"
}
Errors
This operation may return:
400— Invalid query parameter —accountId,sortBy,sortOrder,pageSizeorcursorwas set with an invalid value401— Unauthorized - The OAuth token is missing, invalid, or carries nourn:alianza:claims:principal_idclaim403— Forbidden - The access token does not hold theusers:managescope429— Too many requests. The client has exceeded the rate limit for this API.500— Unexpected server error.detailis always this fixed generic message.503— Service temporarily unavailable, including when the authorization service cannot be reached, which fails closed
See Errors reference for the full catalogue.
Related
- Schema:
UnifiedUser - Schema:
UnifiedUserCollection - Schema:
ProblemDetails