---
title: "Get the authenticated principal"
method: GET
path: "/api/v1/me"
tags: ["me"]
---

# Get the authenticated principal

`GET /api/v1/me`

## Request

- Base URL: `https://pineprompt.com`
- URL: `https://pineprompt.com/api/v1/me`
- Auth: HTTP bearer

Returns the API key presented on the request, together with the active organization, the abilities currently in effect, and the projects you may act in.

## Response `200`

OK

- Me: The authenticated principal behind the current request: the API key presented, the abilities it carries, and the organization and projects it may reach.
  - `organization` Organization: An organization is the top-level billing entity and tenant boundary in Pineprompt. Every project, member, and API key belongs to exactly one organization.
    - `id` integer: The unique ID of the organization.
    - `name` string: The display name of the organization.
    - `created_at` string, date-time: When the organization was created.
    - `updated_at` string, date-time: When the organization was last updated.
  - `abilities` string[]: The abilities currently in effect for the request, taken from the API key itself.
  - `projects` Project[]: The projects in the active organization that the caller may act in.
    - `id` integer: The unique ID of the project.
    - `organization_id` integer: The ID of the organization that owns the project.
    - `name` string: The display name of the project.
    - `brand_id` integer, nullable: The ID of the project's own brand, or null while none has been designated.
    - `organization` Organization: An organization is the top-level billing entity and tenant boundary in Pineprompt. Every project, member, and API key belongs to exactly one organization.
      - `id` integer: The unique ID of the organization.
      - `name` string: The display name of the organization.
      - `created_at` string, date-time: When the organization was created.
      - `updated_at` string, date-time: When the organization was last updated.
    - `created_at` string, date-time: When the project was created.
    - `updated_at` string, date-time: When the project was last updated.
  - `api_key` ApiKeyMetadata
    - `id` integer: The unique ID of the API key.
    - `name` string: The label you gave the key when you created it.
    - `last_used_at` string, date-time, nullable: When the key was last used to authenticate a request, or `null` when it has not yet been used.
    - `created_at` string, date-time: When the key was created.

## Other responses

- `401`: Unauthorized

---

[API](https://skmtc.dev/pineprompt/apis/pineprompt-api.md) · [All operations](https://skmtc.dev/pineprompt/apis/pineprompt-api/llms.txt) · [OpenAPI document](https://skmtc.dev/pineprompt/apis/pineprompt-api/revisions/05dbb5241a27?raw)
