---
title: "Get the calling API key metadata"
method: GET
path: "/api/v1/me/api-key"
tags: ["Settings"]
---

# Get the calling API key metadata

`GET /api/v1/me/api-key`

## Request

- Base URL: `https://api.proof.holdings`
- URL: `https://api.proof.holdings/api/v1/me/api-key`
- Auth: one of:
  - HTTP bearer
  - API key in cookie `auth_token`

Returns the calling API key redacted metadata (id, name, key_prefix, environment, scopes) for agent self-inspection. Never returns key_hash. Requires API-key auth — a JWT session has no single-key context and receives 400. (h-dashboard-per-key-api)

## Response `200`

The calling API key (redacted)

- APIKeyResponse: An API key's redacted metadata, as the calling key reads itself (`GET /me/api-key`). Never carries the key value.
  - `id` string, required: MongoDB ObjectId
  - `name` string, required
  - `key_prefix` string, required
  - `environment` 'production' | 'test', required
  - `scopes` string[], required
  - `profile_id` string: MongoDB ObjectId
  - `created_at` string, date-time, required
  - `last_used_at` string, date-time, nullable: When the key last authenticated a request; null if never
  - `expires_at` string, date-time, nullable: When the key stops authenticating; null means it never expires. Enforced at authentication — an expired key is rejected exactly like an unknown one.
  - `revoked_at` string, date-time, nullable: When the key was revoked; null while it is live
  - `replaced_key_ids` ObjectId[]: Ids of the keys this key replaced, newest first: the earlier keys of the same integration, replaced when the key was regenerated (`POST /api/v1/me/api-keys/{id}/regenerate`) or renewed by an MCP sign-in refresh. Requests and usage of those keys count as this key's. Empty when it replaced none. Recorded from the release of key history on; a key replaced before it is not linked.

## Other responses

- `400`: No API-key context (JWT caller)
- `401`: Unauthorized

---

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