---
title: "Get Users"
method: GET
path: "/v1/admin/users"
tags: ["Admin"]
---

# Get Users

`GET /v1/admin/users`

## Query parameters

- `role_id` integer, nullable — The ID of the role to filter the users by.
- `organization_id` integer, nullable — The ID of the organization to filter the users by.
- `email` string, nullable — Email substring to filter the users by.
- `offset` integer — Number of users to skip.
- `limit` integer — Maximum number of users to return.
- `sort_by` 'id' | 'email' | 'created' | 'updated'
- `sort_order` 'asc' | 'desc'

## Response `200`

Successful Response

- UsersResponse
  - `object` 'list' — Type of the object.
  - `total` integer, required — Total number of users matching the query.
  - `offset` integer, required — Number of users skipped.
  - `limit` integer, required — Maximum number of users returned.
  - `data` UserResponse[], required — List of users.
    - `object` 'user' — Type of the object.
    - `id` integer, required — ID of the user.
    - `email` string, required — Email of the user.
    - `name` string, nullable — Name of the user.
    - `sub` string, nullable — Subject identifier for SSO.
    - `iss` string, nullable — Issuer identifier for SSO.
    - `role` integer, required — ID of the role assigned to the user.
    - `organization_id` integer, nullable — ID of the organization the user belongs to.
    - `budget` number, nullable — Budget allocated to the user.
    - `expires` integer, nullable — Expiration time of the user, as Unix timestamp.
    - `created` integer, required — Time of creation, as Unix timestamp.
    - `updated` integer, required — Time of last update, as Unix timestamp.
    - `priority` integer, required — Priority of the user. Higher value means higher priority.

## Other responses

- `401` — Invalid authentication scheme.<br>Invalid API key.
- `403` — User has no admin rights.<br>Your account has expired. Please contact support to renew your account.
- `422` — Validation Error

---

[API](https://skmtc.net/betagouv/apis/opengatellm.md) · [All operations](https://skmtc.net/betagouv/apis/opengatellm/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/betagouv/opengatellm/revisions/f2624a610e5a/schema)
