Light Logo
Users

List users

Retrieves a paginated list of users. By default the users are returned in the order that they joined WriftAI.

GET
/users
AuthorizationBearer <token>

In: header

Query Parameters

cursor?Cursor

The starting point to fetch the next set of items.

page_size?Page Size

The number of results per page.

Default25
Range5 <= value <= 100
sort_by?UsersSortBy

The field by which to sort the results.

Default"created_at"
Value in"created_at"
sort_direction?Sort Direction

The direction in which to sort the results.

Default"asc"
Value in"asc" | "desc"

Response Body

from wriftai import Clientwriftai = Client()users = wriftai.users.list()for user in users.items:    print(user.name)
{
  "items": [
    {
      "account_id": "8f2b1e4a-9c3d-4f6e-b1a2-7d8e9f0a1b2c",
      "name": "jane-doe",
      "avatar_url": "https://wrift.ai/avatars/jane-doe.png",
      "display_name": "Jane Doe",
      "bio": "Building ML models for text-to-speech.",
      "location": "San Francisco, CA",
      "company": "WriftAI",
      "created_at": "2024-06-12T14:22:31Z",
      "updated_at": "2024-06-12T14:22:47Z"
    }
  ],
  "next_cursor": "eyJyZXZlcnNlIjpmYWxzZSwic3RhcnRfaWQiOiI0OTdmNmVjYS02Mjc2LTQ5OTMtYmZlYi01M2NiYmJiYTZmMDgiLCJzdGFydF9jcmVhdGVkX2F0IjoiMjAyNC0wNi0xMlQxNDoyMjozMVoifQ==",
  "previous_cursor": "eyJyZXZlcnNlIjpmYWxzZSwic3RhcnRfaWQiOiJmZmZmOTk5OS05OTk5LTk5OTktOTk5OS1mZmZmZmZmZmZmZmYiLCJzdGFydF9jcmVhdGVkX2F0IjoiMjAyNC0wNS0wMVQwOTowMDowMFoifQ=="
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string",
      "input": null,
      "ctx": {}
    }
  ]
}