---
title: "Get Current User"
method: GET
path: "/api/admin/users/whoami"
tags: ["admin-users"]
---

# Get Current User

`GET /api/admin/users/whoami`

Identity + envelope for the calling admin API key.

Intentionally bypasses ``require_admin_permission``: any valid, non-
expired, non-disabled admin API key whose owner is still ADMIN/MANAGER
can call this. Returning the resolved permission envelope is what makes
a freshly-minted scoped key able to discover what it can do.

## Response `200`

Successful Response

- GenericResponseAdminWhoamiResponse
  - `data` AdminWhoamiResponse — Extended User response that includes admin permissions.
    - `id` string
    - `role` 'ADMIN' | 'MANAGER' | 'USER'
    - `createdAt` string, date-time
    - `name` string, required
    - `slug` string, nullable
    - `email` string, required
    - `image` string, nullable
    - `emailVerified` string, date-time, nullable
    - `hasBetaAccess` boolean
    - `isBanned` boolean
    - `skipPrepay` boolean
    - `blacklist` string[]
    - `permissions` object — Resolved UserPermission envelope (scoped): each section maps to an `all` bucket and/or per-team/user/resource buckets describing what this admin can do across the admin API surface.
    - `admin_role` 'ADMIN' | 'MANAGER' | 'USER', required
  - `status` string, nullable — Response status

## Other responses

- `401` — Authorization failed
- `403` — Insufficient permissions
- `422` — Invalid request data

---

[API](https://skmtc.net/primeintellect/apis/pi-api.md) · [All operations](https://skmtc.net/primeintellect/apis/pi-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/primeintellect/pi-api/revisions/3d3868828a78/schema)
