---
title: "Set the caller's own display name"
method: PATCH
path: "/agent/v1/me"
tags: ["Org"]
---

# Set the caller's own display name

`PATCH /agent/v1/me`

## Request

- Base URL: `https://api.run402.com`
- URL: `https://api.run402.com/agent/v1/me`
- Auth: one of:
  - API key in header `SIGN-IN-WITH-X`
  - HTTP bearer
  - HTTP bearer

Sets `display_name` on the calling principal (1–64 characters after trimming, no control characters) and returns the same body `GET /agent/v1/whoami` returns. Self-only: a grant key sets the name of the principal it acts for, never a name of its own. This name is what promotion credit (`hand_to_member.credited_as`), `run402 up`'s room presence, and audit surfaces show for the principal; `run402 init --name`, `run402 org whoami --set-name`, and `up`'s agent-principal-only default (`RUN402_AGENT_NAME` when the runtime declares one, else a specifically detected client: `claude-code`, `codex`, `cursor`, `grok`; nothing is written when nothing is known) all land here. Wallet principals are created unnamed: the gateway never seeds `display_name` from the wallet subject.

## Headers

- `SIGN-IN-WITH-X` string, required

## Request body

- object
  - `display_name` string, required

## Response `200`

The updated principal in the `whoami` body shape.

- object
  - `principal` object, required
    - `id` string
    - `type` string
    - `display_name` string, nullable

## Other responses

- `400`: `INVALID_DISPLAY_NAME` — empty, over 64 characters, or contains control characters; `details` carries `min` and `max`.

---

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