Skip to main content
Glama
YawLabs

@yawlabs/npmjs-mcp

by YawLabs

npm_deprecate

DestructiveIdempotent

Deprecate an npm package or specific versions with a custom warning message shown at install. Uses the HTTP API with NPM_TOKEN to avoid CLI auth friction and 422 errors.

Instructions

Deprecate a package or specific versions. Shows a warning message on install. Uses the HTTP API with NPM_TOKEN, bypassing the CLI auth friction that causes 422 errors on accounts with 2FA. Registry hard limit: deprecation messages must be <= 1024 characters. If the registry 422s, first verify the semver range matches at least one published version (npm_versions) — range/version mismatches are the most common cause, not message format.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesPackage name (e.g. '@yawlabs/spend')
messageYesDeprecation message. Use npm_undeprecate to clear.
versionRangeNoSemver range. Omit to deprecate ALL versions. Example: '<1.0.0' or '0.3.x'. Standard semver applies — bare integers are x-ranges (e.g. '0' means '0.x.x', not exact version 0). For a single version use '=1.2.3'.
Behavior5/5

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

Annotations already indicate destructive and idempotent behavior, but the description adds significant context: it shows a warning on install, uses HTTP API with NPM_TOKEN to avoid 2FA issues, enforces a 1024-character message limit, and gives a common 422 troubleshooting path. This goes well beyond the structured metadata and provides actionable behavioral details.

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 four sentences, each earning its place: purpose, behavioral effect, auth rationale, and troubleshooting. It is front-loaded with the core action and avoids any redundant or verbose wording.

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

Completeness5/5

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

For a destructive mutation tool, the description covers the essential context: what it does, how it authenticates, constraints (character limit), and common failure troubleshooting. Combined with rich annotations and full schema coverage, it provides a complete operational picture without needing an output schema.

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%, and the property descriptions already explain the meaning of name, message, and versionRange including semver nuances. The tool description does not add parameter-level semantic information beyond the schema, so a baseline score of 3 is appropriate.

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 a clear, specific verb and resource: 'Deprecate a package or specific versions.' This unambiguously distinguishes it from siblings like npm_undeprecate and npm_unpublish_version. The additional context about warning messages and API usage further clarifies the tool's role.

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?

The description states when to use the tool (to deprecate) and highlights a key advantage over CLI auth: bypassing 2FA friction. It also provides troubleshooting guidance pointing to npm_versions on 422 errors. However, it does not explicitly name alternatives like npm_undeprecate or state when not to use this tool, missing a bit of explicit exclusion guidance.

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