get_agent_status — introspect the current Agent ID
Available via MCP and HTTP API.
- MCP: call
get_agent_statusto check if an Agent ID is configured locally. - HTTP: there is no public endpoint; check your own storage for
agent_id,token, andjwtor re‑register if missing.
Purpose
Allows an agent to introspect its own Agent ID configuration and decide whether registration is needed.
What it does
- Checks if an Agent ID has already been stored locally.
- Returns a simple JSON object describing:
- whether the agent is
configured, - the current
agent_id,agent_name,email, andregistered_at(if known).
- whether the agent is
Typical agent usage
- At startup, call
get_agent_status. - If
configuredisfalse, callinit_agent_id(either with env‑backed config or by asking the user for details). - Use the returned metadata to show the user which identity is currently associated with this runtime.
Output shape (example)
json
{
"configured": true,
"agent_id": "agent_123...",
"agent_name": "Claude Code - your-machine",
"email": "your-email@example.com",
"registered_at": "2024-10-01T12:34:56.000Z"
}