Skip to main content
Glama

Impersonate a user

impersonate

Generate a non-refreshable auth token for an existing user without their password, enabling API calls on their behalf. Superuser access required.

Instructions

Generate an auth token for an existing user without their password (superuser only). Returns a non-refreshable token valid for the given duration, useful to make API calls on behalf of a user.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
durationNoToken lifetime in seconds (default: collection auth token duration).
recordIdYesId of the user record to impersonate.
collectionNoAuth collection (default 'users').

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv1.0.0

TDQS

A4.1/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and discloses important behavior: the token is non-refreshable, duration-limited, and superuser-only. It could say more about side effects or the exact response format, but the key behavioral traits are clearly communicated.

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

Conciseness5/5

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

The description is two concise sentences with no filler. It front-loads the core action and resource, then efficiently adds the non-refreshable, duration, and use-case details.

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

Completeness3/5

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

For a sensitive auth operation with no annotations and no output schema, the description covers the main intent and token behavior but lacks explicit return-format details and more concrete error/permission context. It is adequate but has clear gaps.

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

Parameters3/5

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

Schema description coverage is 100%, so the baseline is 3. The description reinforces the meaning of duration and the target user but does not need to add much beyond the schema; collection is left to the schema.

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 uses a specific verb and resource: 'Generate an auth token for an existing user'. It clearly distinguishes itself from normal password-based auth by noting 'without their password' and adds the superuser restriction, making it easy to differentiate from sibling tools like auth_with_password or create_superuser.

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

Usage Guidelines4/5

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

It gives clear context on when to use it: when you need to make API calls on behalf of a user without their password, and only as a superuser. It does not explicitly name alternatives or rule out other auth methods, so it stops short of a 5.

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

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nestebe/pocketbase-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server