---
title: "Get current user info"
method: GET
path: "/whoami"
tags: ["Auth"]
---

# Get current user info

`GET /whoami`

## Request

- Base URL: `https://api.mosaic.so`
- URL: `https://api.mosaic.so/whoami`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-API-Key`

Get information about the current user based on the API key.

## Response `200`

User information retrieved successfully

- User
  - `user_id` string: Unique identifier for the user
  - `email` string, nullable: User's email address
  - `is_admin` boolean: Whether the user has admin privileges
  - `api_key_id` string: ID of the API key used for the request
  - `created_at` string, date-time, nullable: When the API key was created
  - `last_used_at` string, date-time, nullable: When the API key was last used
  - `scopes` string[], nullable: Explicit API key scopes. null means full organization access; [] grants no entity permissions. Read and write scopes are independent.

## Other responses

- `401`: Authentication failed

---

[API](https://skmtc.dev/mosaic/apis/mosaic-ai-api.md) - [All operations](https://skmtc.dev/mosaic/apis/mosaic-ai-api/llms.txt) - [OpenAPI document](https://skmtc.dev/mosaic/apis/mosaic-ai-api/revisions/c20e9fc606a4?raw)
