Skip to main content
Glama

Revoke an API key

revoke_api_key
DestructiveIdempotent

Stops a key working immediately. Revoking the key this connection authenticated with is allowed and ends the connection — it is the right move if a key has leaked, so it isn't blocked, but it is not undoable. Issuing a replacement is a dashboard action.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesId of the API key to revoke, from list_api_keys (not the key itself or its prefix).

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYes
revokedYes
wasCurrentKeyYesTrue if this was the key this connection used, which has now ended.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

The annotations already include destructiveHint=true and idempotentHint=true. The description adds critical behavioral context: 'ends the connection' (impact on current session) and 'it is not undoable' (irreversibility), which are not captured by annotations. This goes beyond just repeating the annotation flags. The only minor miss is not detailing what happens to the affected operations (e.g., immediate failure of previous calls), but the main safety and irreversibility aspects are well covered.

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 compact, three sentences, with the core action and immediate impact front-loaded. Every sentence adds value: the first gives the action and immediacy, the second explains the self-key scenario and when it's appropriate, and the third points to the alternative for replacement. No fluff.

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?

Given the tool's simplicity (one parameter, output schema present), the description covers the essential behavioral aspects: mutation, irreversibility, connection impact, and usage context. The output schema likely describes the response (maybe success status), so return values are covered. The only minor gap is not mentioning any side effects like invalidating cached credentials, but for typical API key revocation, this is adequate. It's complete enough for an agent to call correctly.

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?

The schema description coverage is 100%, so the schema already documents the 'id' parameter with a note to use the id from list_api_keys. The description does not add much beyond that—it mentions the key's id but the schema already says 'not the key itself or its prefix.' The description reinforces the context (that the id is the internal id), but it's largely redundant. Baseline 3 is appropriate given full schema coverage.

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 states the action: 'Stops a key working immediately,' which is a specific verb with the resource (API key). It also distinguishes itself from related operations like list_api_keys (by clarifying the id is from list_api_keys, not the key itself) and mentions issuing a replacement is a dashboard action, differentiating from any potential sibling like 'create_api_key'.

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?

The description provides explicit guidance on when to use this tool: 'it is the right move if a key has leaked, so it isn't blocked.' It also implies when not to use it (if you need a replacement, that's a dashboard action), and mentions that revoking the currently authenticated key is allowed, which is a specific use-case clarification.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources