Skip to main content
Glama

Versión dentro de un rango

semver-satisfies
Read-onlyIdempotent

Verifica si una versión cumple un rango estilo npm (^, ~, x, guiones, ||). Cuándo: hay que leer, construir o revisar con exactitud una URL, una cabecera HTTP, un token, una versión, un rango de IP, un documento HTML o Markdown o un archivo para agentes. No para: incrementar una versión SemVer (semver-bump). Efectos secundarios: ninguno (solo lectura, sin red, sin estado guardado). Determinista: la misma entrada da la misma salida. Límites: entrada JSON de hasta 64 KB, 1 s por llamada, resultado de hasta 1 MB.

EN: Checks whether a version satisfies an npm-style range (^, ~, x-ranges, hyphen ranges, comparators, || alternatives). Prereleases only match when the range names the same version tuple, unless include_prerelease is true. When: a URL, HTTP header, token, version string, IP range, HTML or Markdown document or agent-readiness file has to be parsed, built or checked exactly. Not for: incrementing a SemVer version (semver-bump). [EN completo / full EN: inputSchema.description]

Input Schema

NameRequiredDescriptionDefault
rangeYesRange, e.g. ^1.2.0 || >=2.1 <3 (string; required; up to 512 chars).
versionYesSemantic version, e.g. 1.2.3-beta.1 (string; required; up to 256 chars).
include_prereleaseNoLet prereleases match any range (boolean; optional; default false).

Output Schema

NameRequiredDescriptionDefault
satisfiesNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / range / examples
      Added value: +[
      +  "^1.2.0"
      +]
    • addedInput schema / properties / version / examples
      Added value: +[
      +  "1.4.2"
      +]
  2. Changed1 schema field changed
    • addedInput schema / description
      Added value: +"EN: Checks whether a version satisfies an npm-style range (^, ~, x-ranges, hyphen ranges, comparators, || alternatives). Prereleases only match when the range names the same version tuple, unless include_prerelease is true. When: a URL, HTTP header, token, version string, IP range, HTML or Markdown document or agent-readiness file has to be parsed, built or checked exactly. Not for: incrementing a SemVer version (semver-bump). Side effects: none (read-only, no network access, no stored state). Deterministic: the same input gives the same output. Limits: JSON input up to 64 KB, 1 s per call, result up to 1 MB."
  3. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false and openWorldHint=false, so restating 'no side effects, read-only, no network' adds little. The description does add genuinely new behavior: the prerelease matching rule and concrete operational limits (64 KB input, 1 s per call, 1 MB result), which is what the annotations cannot convey.

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

Conciseness3/5

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

The core purpose-plus-exclusion is front-loaded and efficient, but the body is duplicated in ES and EN, and the generic 'When' enumeration of unrelated artifacts is padding that dilutes the signal. It is serviceable rather than tight.

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?

With an output schema present, return values need not be described, and the limits, determinism and prerelease rule together give an agent enough to call it correctly. The only weak spot is the broad 'When' list, which does not reflect this tool's actual two-parameter surface.

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?

Schema coverage is 100%, so the baseline is 3, and the description earns above that by explaining the semantics of include_prerelease ('prereleases only match when the range names the same version tuple, unless include_prerelease is true'), which the schema's one-line default note does not.

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?

States a specific verb and result ('Checks whether a version satisfies an npm-style range') and enumerates the exact range syntaxes supported (^, ~, x-ranges, hyphen ranges, comparators, ||). It also explicitly names the sibling it is not (semver-bump), so an agent can route without opening either schema.

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 'Not for: incrementing a SemVer version (semver-bump)' exclusion is explicit, and the prerelease matching rule tells the agent when to set include_prerelease. However, the 'When' clause lists URLs, HTTP headers, tokens, IP ranges and HTML/Markdown documents, which is generic boilerplate that does not map onto a two-string version/range tool and could misdirect an agent.

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