---
title: "GET /api/v1/{context_id}/principals/{principal_id}"
method: GET
path: "/api/v1/{context_id}/principals/{principal_id}"
---

# GET /api/v1/{context_id}/principals/{principal_id}

`GET /api/v1/{context_id}/principals/{principal_id}`

## Request

- The document declares no server URL.
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/surrealdb/apis/spectron/docs/api/v1/:context_id/principals/:principal_id/get.ts> (a function with typed inputs; its response is checked against the schema)

Fetch one principal by id (requires the `grant:manage` grant)

## Path parameters

- `context_id` string, required
- `principal_id` string, required

## Response `200`

- PrincipalJson: A principal in the `GET /{ctx}/principals` / `…/{id}` responses.
  - `displayName` string, required: Human-readable display name.
  - `grants` Grants, required: Per-verb scope pattern map. Keys are grant verbs in `<noun>:<verb>` form (`memory:read`, `memory:write`, `memory:forget`, `scope:read`, `scope:create`, `scope:delete`, `grant:manage`); values are arrays of scope patterns.
  - `id` string, required: Record-id key (e.g. `alpha-bot`).
  - `kind` string, required: Identity kind: `human` / `agent` / `service` / `unknown`.

## Other responses

- `401`: Unauthorized
- `403`: Caller lacks the `grant:manage` grant
- `404`: Principal does not exist
- `422`: Invalid context id
- `503`: Server too busy: the per-pod in-flight request cap was exceeded. Retry per the `Retry-After` header.

## Changes

- **2026-08-24** `9f1598713067`: 1 info
  - added the non-success response with the status `503`

[Operation history](https://skmtc.dev/surrealdb/apis/spectron/changes/api/v1/:context_id/principals/:principal_id/get.md)

---

[API](https://skmtc.dev/surrealdb/apis/spectron.md) - [All operations](https://skmtc.dev/surrealdb/apis/spectron/llms.txt) - [OpenAPI document](https://skmtc.dev/surrealdb/apis/spectron/revisions/9f1598713067?raw)
