# User profiles

Profiles of users: their name, email address and language

Base URL: `https://api.cv-transformer.com/v1`. Endpoints: `GET /user_profiles`. Authenticate with the header `Authorization: Bearer YOUR_API_KEY` (see [authentication](https://www.cv-transformer.com/yue/api-reference/authentication.md)).

## The user profile object

| Attribute | Type | Description |
| --- | --- | --- |
| `user_id` | `uuid` | Unique identifier. |
| `created_at` | `timestamp with time zone` | Creation timestamp. |
| `updated_at` | `timestamp with time zone` | Last modification timestamp. |
| `avatar` | `text \| null` | Avatar image of the user. |
| `email` | `text` | Email address of the user. |
| `fts` | `tsvector` | Full text search index. |
| `invited_at` | `timestamp with time zone \| null` | Last invitation timestamp. |
| `language` | `Language` | Language of the user. |
| `last_login_at` | `timestamp with time zone \| null` | Last sign-in timestamp. |
| `name` | `text` | Name of the user. |
| `phone` | `text` | Phone number of the user. |
| `source` | `text \| null` | How the user signed up, like `invite`. |

```json
{
  "user_id": "00000000-0000-0000-0000-000000000000",
  "created_at": "2026-01-01T12:00:00+00:00",
  "updated_at": "2026-01-01T12:00:00+00:00",
  "avatar": "",
  "email": "",
  "fts": "'doe':2 'john':1",
  "invited_at": null,
  "language": "en",
  "last_login_at": null,
  "name": "",
  "phone": "",
  "source": ""
}
```

### Types

```typescript
type Language = 
  | "en"
  | "cs"
  | "da-DK"
  | "de"
  | "en-GB"
  | "es"
  | "fr"
  | "ja-JP"
  | "nb-NO"
  | "nl"
  | "pt-BR"
  | "sv-SE"
  | "yue"
  | "zh";
```

### Related resources

Embed related resources with the [`select` parameter](https://www.cv-transformer.com/yue/api-reference/selecting.md), for example `select=*,layouts(*)`. Resources related through more than one column need the column as a hint, like `table!column(*)`.

| Embed | Type | Description |
| --- | --- | --- |
| `layouts(*)` | `array` | The [layouts](https://www.cv-transformer.com/yue/api-reference/layouts.md) referencing this user profile through `layouts.creator_id`. |
| `members(*)` | `array` | The [members](https://www.cv-transformer.com/yue/api-reference/members.md) referencing this user profile through `members.user_id`. |

## List user profiles

`GET /v1/user_profiles` · requires the `members:read` scope

Filter on any attribute with `column=operator.value` (see [filtering](https://www.cv-transformer.com/yue/api-reference/filtering.md)). Choose columns and embed related resources with `select` (see [selecting](https://www.cv-transformer.com/yue/api-reference/selecting.md)), and sort and paginate with `order`, `limit` and `offset` (see [sorting and pagination](https://www.cv-transformer.com/yue/api-reference/sorting-pagination.md)).

```bash
curl "https://api.cv-transformer.com/v1/user_profiles?limit=10&select=*" \
  -H "Authorization: Bearer YOUR_API_KEY"
```

Responses:

- `200`: A list of user profiles with the selected columns. The `Content-Range` header holds the range returned and the total count, like `0-9/42`.
- `206`: Partial Content
- `400`: The request is malformed, for example an unknown column or an invalid filter.
- `401`: The API key is missing or invalid.
- `403`: The API key doesn't have the scope this request needs.
- `429`: The API key made more requests per minute than its rate limit allows. Retry after the number of seconds in the `Retry-After` header.

Errors have a JSON body with a `message`, `details` and `hint`, and for database errors a `code`. See the [introduction](https://www.cv-transformer.com/yue/api-reference.md) for more on errors. The full API is described by the OpenAPI spec at https://api.cv-transformer.com/v1/openapi.json.
