Skip to main content
Glama

Compare Versions

compare_versions
Read-only

Compare two specification versions and show their differences: added/removed/modified endpoints and schemas. Omit sourceVersionId to compare against the version before the target. detail 'full' (default) returns the changed entities; 'flags' returns only what changed and how — much smaller, and enough to decide where to look. Requires project context. Use this for the raw structural difference; for a written summary of it use generate_changelog.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "specId": "<specId>",
      "targetVersionId": "<targetVersionId>"
    },
    "name": "compare_versions"
  }
}

Input Schema

NameRequiredDescriptionDefault
detailNoHow much to return: 'full' (default) or 'flags'full
specIdYesPublic ID (GUID) of the API specification
sourceVersionIdNoPublic ID (GUID) of the source (older) version — omit for the version before the target
targetVersionIdYesPublic ID (GUID) of the target (newer) version

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / sourceVersionId / description
      Previous value: -"Public ID (GUID) of the source (older) version — omit for the latest published version"New value: +"Public ID (GUID) of the source (older) version — omit for the version before the target"
  2. First observed

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, so safety is covered; the description adds what the returned payload contains and, importantly, the size/shape tradeoff between 'full' and 'flags', plus the precondition that project context is required. It stops short of describing pagination, cost limits, or what happens when versions are unrelated or identical, which keeps it from a 5.

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?

Four short sentences, front-loaded with the purpose, then the defaulting rule, then the detail tradeoff, then the sibling routing. No restatement of the title or schema boilerplate; every clause carries an operative fact.

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 read-only, four-parameter diff tool with no output schema, the definition covers the essentials: what is compared, how much is returned, how the source version defaults, and the prerequisite of project context. What a 'changed entity' looks like in the payload is left implicit, a minor gap given there is no output schema to lean on.

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 baseline is 3. The description still adds non-obvious meaning: the defaulting behavior of sourceVersionId to the immediately prior version, and the practical consequence of 'flags' being 'much smaller, and enough to decide where to look' — a decision aid the schema's one-line enum text does not convey.

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 specific verb and resource ("Compare two specification versions and show their differences") and then enumerates what the difference consists of — added/removed/modified endpoints and schemas. It also explicitly distinguishes itself from the nearest sibling (generate_changelog) by scope: raw structural difference vs. written summary.

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?

Concrete when-to-use rules are given: omit sourceVersionId to compare against the preceding version, use detail 'flags' when a compact answer suffices to decide where to look, and use generate_changelog instead when a written summary is wanted. Both the alternative and the condition that selects it are named.

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