Skip to main content
Glama

whoami

Retrieve the remote identity context: principal, active authenticator, linked identities, org memberships, and session grade. Confirm which control-plane principal the wallet resolves to before proceeding.

Instructions

The remote identity (r.orgs.whoami()): the control-plane principal this server's wallet resolves to, its active authenticator and linked identities, its org memberships, and the sign-in session grade (none for a wallet). For the local wallet use status. Any other operation is a run snippet against r, the Node SDK client; docs is its reference.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNo
resultNo
statusYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / additionalProperties
      Added value: +false
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": true,
      +  "properties": {
      +    "error": {
      +      "additionalProperties": true,
      +      "properties": {
      +        "category": {
      +          "type": "string"
      +        },
      +        "code": {
      +          "type": "string"
      +        },
      +        "column": {
      +          "type": "integer"
      +        },
      +        "details": {},
      +        "fix": {},
      +        "http_status": {
      +          "type": "integer"
      +        },
      +        "line": {
      +          "type": "integer"
      +        },
      +        "logs": {
      +          "items": {
      +            "type": "string"
      +          },
      +          "type": "array"
      +        },
      +        "message": {
      +          "type": "string"
      +        },
      +        "mutation_state": {
      +          "type": "string"
      +        },
      +        "next_actions": {
      +          "items": {
      +            "additionalProperties": true,
      +            "properties": {
      +              "type": {
      +                "type": "string"
      +              }
      +            },
      +            "type": "object"
      +          },
      +          "type": "array"
      +        },
      +        "operation_id": {
      +          "type": "string"
      +        },
      +        "phase": {
      +          "type": "string"
      +        },
      +        "plan_id": {
      +          "type": "string"
      +        },
      +        "resource": {
      +          "type": "string"
      +        },
      +        "retryable": {
      +          "type": "boolean"
      +        },
      +        "safe_to_retry": {
      +          "type": "boolean"
      +        },
      +        "trace_id": {
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "code",
      +        "message",
      +        "next_actions"
      +      ],
      +      "type": "object"
      +    },
      +    "result": {
      +      "additionalProperties": true,
      +      "properties": {
      +        "memberships": {
      +          "items": {
      +            "additionalProperties": true,
      +            "properties": {
      +              "org_id": {
      +                "type": "string"
      +              },
      +              "role": {
      +                "type": "string"
      +              }
      +            },
      +            "required": [
      +              "org_id"
      +            ],
      +            "type": "object"
      +          },
      +          "type": "array"
      +        },
      +        "principal": {
      +          "additionalProperties": true,
      +          "properties": {
      +            "id": {
      +              "type": "string"
      +            },
      +            "type": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "id"
      +          ],
      +          "type": "object"
      +        },
      +        "session": {
      +          "anyOf": [
      +            {
      +              "additionalProperties": true,
      +              "properties": {
      +                "grade": {
      +                  "type": "string"
      +                }
      +              },
      +              "type": "object"
      +            },
      +            {
      +              "type": "null"
      +            }
      +          ]
      +        }
      +      },
      +      "required": [
      +        "principal",
      +        "memberships"
      +      ],
      +      "type": "object"
      +    },
      +    "status": {
      +      "enum": [
      +        "ok",
      +        "error"
      +      ],
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "status"
      +  ],
      +  "type": "object"
      +}
  2. First observedv3.6.0

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are present, so the description carries the full burden. It discloses not just that the tool returns identity, but the specific elements of that identity, including the nuance that wallet sessions have no grade. It does not explicitly state that the operation is read-only or describe error cases, but that is lightly implied by the whoami concept.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two dense sentences carry substantial information without filler. The first sentence lists the output components, the second provides sibling routing and a note about the SDK. Some technical jargon ('control-plane principal', 'r.orgs.whoami()') makes it less instantly accessible, but each clause earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a no-parameter tool with an output schema, the description is nearly complete: it covers what is returned, how to distinguish this from the local wallet tool, and how it fits into the broader run/docs ecosystem. It could optionally explain 'session grade' in plainer language, but this is a minor gap given the output schema likely documents structure.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool has zero parameters, so the schema is trivially 100% covered and the baseline is 4. The description adds no parameter detail because none is needed; it focuses instead on output and context.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly defines the tool as returning the remote identity, enumerating its components: control-plane principal, active authenticator, linked identities, org memberships, and session grade. It distinguishes from siblings by explicitly noting that local wallet identity is handled by 'status' and that other operations belong to 'run'.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit routing: 'For the local wallet use status' and 'Any other operation is a run snippet'. This tells an agent exactly when to use this tool versus alternatives and when to use run instead.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools