List users in the workspace
const url = 'https://example.com/v1/identity/users?limit=25';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://example.com/v1/identity/users?limit=25' \ --header 'Authorization: Bearer <token>'Cursor-paginated list of workspace users (sort order is binding-defined), for tenant admins only. Optional ?query= is a prefix match on displayName — the natural filter shape for a “search users” surface. primaryEmail may be redacted per workspace policy. Anyone else adds a person to a project by their email or id (POST /v1/projects/{projectId}/memberships).
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”1..100. Default 25.
Where the previous page ended: its nextCursor, as it came. A runtime that seals cursors takes one only for the same list, filters and caller, within a day; otherwise 400 bad-input, and the list starts again without it. Absent → first page.
Prefix match on displayName.
With true, people who were removed (unregisteredAt) too.
With true, only people with an open invitation (invite: pending or expired), who haven’t signed in yet. An older runtime ignores it and lists everyone (from 0.1.9).
Extra fields, one or more, comma-separated: include=grants. grants: each person’s grants, as GET /v1/identity/users/{userId}/grants answers them, in this one read. A runtime that doesn’t read grants (no authorization store) leaves grants out, as an older one does.
Responses
Section titled “Responses”Page of users.
object
Workspace-scoped user record (admin plane). primaryEmail may be redacted on the wire based on workspace policy (the routes treat it as opaque). metadata is free-form JSON — deployments carry IdP claims / provisioning source / roles here.
object
When they were removed from the workspace (POST /v1/identity/users/{userId}/unregister); absent while they are here.
Their invitation, while they haven’t signed in: absent once they have, for people added without an email, and for people added before invitations (from 0.1.9).
object
When it was last emailed; absent when it never was.
Their first sign-in that made a session. Absent before it, and for people who last signed in before it was kept (from 0.1.9).
Who added them: user:<id> (a tenant admin) or service_account:<id>; identity_provider:<providerId> for someone who joined by domain through that identity provider, or email_domain:<domain> through one of the workspace’s allowed domains; site:<siteId> for a person a site signs in. Ids only, never an email. Absent for the seed user, and from a runtime that doesn’t keep it.
object
The person’s grants: only on GET /v1/identity/users?include=grants, and only from a runtime that reads grants.
object
Whether the person is a tenant admin. Absent when the runtime has no authorization store: nothing grants it then.
Whether the running server’s KINDGI_ADMIN_EMAILS names the person: they’re a tenant admin at every start, and taking tenant admin from them, or removing them, answers 409 listed-admin until the address is off the list. Absent when the runtime doesn’t report it.
Whether the person is a tenant member: they read the workspace’s settings (providers, policies, adapters, signing keys, deployments), not its projects. A person is one from being added. Absent when the runtime has no authorization store, or doesn’t report it.
Direct project memberships.
A person’s direct role on a project.
object
Role on a project, as read. member is only read, on a role given before it was retired: it grants what viewer does, and writes refuse it.
Team memberships.
A person’s role in a team.
object
Role on a team membership.
A person’s active entry on the reviewer roster.
object
Reviewer role class. Hierarchy: standard < senior < admin.
The capabilities the person holds, such as env:write or signing-keys:write. Absent when the runtime doesn’t report them: unknown, not none.
Example
{ "data": [ { "invite": { "state": "pending" }, "grants": { "projects": [ { "role": "viewer" } ], "teams": [ { "role": "member" } ], "reviewer": { "role": "standard" } } } ]}Missing / malformed / expired / revoked bearer token.
object
object
Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).
Optional, kind-specific.
object
Server-assigned request id; also echoed via X-Request-Id header.
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}Not a tenant admin.
object
object
Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).
Optional, kind-specific.
object
Server-assigned request id; also echoed via X-Request-Id header.
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}rate-limit-exceeded with details.limit: "api-requests", on a runtime that sets workspace limits (Kindgi Cloud): this workspace’s limit on API requests a minute is reached, so the request wasn’t run; Retry-After says when to send it again.
object
object
Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).
Optional, kind-specific.
object
Server-assigned request id; also echoed via X-Request-Id header.
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}Headers
Section titled “Headers”Whole seconds to wait before sending the request again, at least 1. Sent with the codes the answer names as sending it, so it may be absent.
The database was too busy to answer in time (database-busy), or the authorization store couldn’t be reached (authz-backend-unavailable); Retry-After (whole seconds) says when to try again.
object
object
Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).
Optional, kind-specific.
object
Server-assigned request id; also echoed via X-Request-Id header.
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}Headers
Section titled “Headers”Whole seconds to wait before sending the request again, at least 1. Sent with the codes the answer names as sending it, so it may be absent.
See also
POST /v1/identity/users: Add a personGET /v1/identity/users/{userId}: Get a user by idGET /v1/identity/users/{userId}/sessions: List active sessions for a userPOST /v1/identity/users/{userId}/unregister: Remove a person- Operate a self-hosted runtime
- Export your data
- Error code
authz-backend-unavailable - Error code
database-busy - Error code
rate-limit-exceeded - Every error code