Skip to main content
Glama
YawLabs

@yawlabs/npmjs-mcp

by YawLabs

npm_token_revoke

DestructiveIdempotent

Revoke an npm access token by its key, requiring explicit confirmation to prevent accidental revocation of the active token.

Instructions

Revoke an access token by its key (UUID from npm_tokens). Requires confirm: true. Revoking the token currently in use by NPM_TOKEN will break the next call. Creating tokens is NOT exposed because the endpoint requires the user password — create via https://www.npmjs.com/settings/~/tokens instead.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
confirmYesMust be literally true. Guards against revoking the token you're authenticating with.
tokenKeyYesToken key (UUID shown by npm_tokens)
Behavior4/5

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

Annotations already indicate destructiveHint: true and readOnlyHint: false, so the description doesn't need to restate those. However, it adds valuable context beyond annotations by explaining the consequence of revoking the currently used token and the reason token creation is not exposed (requires user password). This is useful behavioral disclosure.

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 (four short sentences) and front-loaded with the primary purpose. Every sentence adds meaningful context: operation, prerequisite, risk, and alternative. No filler or redundancy.

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 destructive tool with only two parameters and no output schema, the description covers purpose, confirmation requirement, side effects, and creation alternatives. It could mention the success/error response shape, but that is not critical given the low complexity. The warning about breaking the next call is a strong safety context.

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 coverage is 100%, with both tokenKey and confirm having descriptive text. The description reiterates 'Requires confirm: true' and the tokenKey provenance, but does not add meaning beyond the schema. Baseline 3 is appropriate because the schema already carries the semantic weight.

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 opens with 'Revoke an access token by its key (UUID from npm_tokens)', which identifies the specific action (revoke), the resource (access token), and the key mechanism. This clearly differentiates it from sibling tools like npm_tokens (listing) or npm_verify_token (verification).

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 explicitly states 'Requires confirm: true' as a prerequisite, warns about breaking the next call if revoking the current token, and provides alternative guidance for token creation ('create via https://www.npmjs.com/settings/~/tokens instead'). This gives the agent clear when-to-use and when-not-to-use context.

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

Install Server

Other Tools

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/YawLabs/npmjs-mcp'

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