Skip to main content
Glama

OpenAPI 3.1, JSON Schema & MCP Contract Breaking-Change Detector

detect_openapi_breaking_changes
Read-onlyIdempotent

Compare baseline and candidate OpenAPI, JSON Schema, or MCP manifests to detect breaking changes and audit backward compatibility before deployment.

Instructions

Compares baseline and candidate OpenAPI 3.1 specs, JSON Schemas, or MCP tool manifests to detect breaking changes (removed fields, new required inputs, narrowed enums, type mutations). Use when auditing API, JSON Schema, or MCP contract revisions for backward compatibility before deployment; for compiling new TypeScript, Zod, and Pydantic schemas from a single sample JSON payload, use compile_polyglot_type_schemas instead. Read-only edge call (32 KB, 60 RPM): accepts 'baseline_schema_json' (with enum defaults), uses '?demo=true' or L402 (25 sats); HTTP 400 if invalid.

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": {
      "baseline_schema_json": "<baseline_schema_json>",
      "candidate_schema_json": "<candidate_schema_json>"
    },
    "name": "detect_openapi_breaking_changes"
  }
}

Input Schema

NameRequiredDescriptionDefault
contract_formatNoContract specification format; defaults to 'auto_detect' when omitted.
baseline_schema_jsonYesJSON string of the baseline OpenAPI 3.1 spec, JSON Schema, or MCP tools array.
candidate_schema_jsonYesJSON string of the proposed candidate schema or contract revision to compare.

Output Schema

NameRequiredDescriptionDefault
breaking_changesYesDetailed list of breaking removals, type changes, or new required parameters.
non_breaking_additionsYesBackward-compatible optional fields or endpoints added.
recommended_semver_bumpYesRecommended Semantic Version bump ('MAJOR_BREAKING', 'MINOR_ADDITIVE', or 'PATCH_COMPATIBLE').
breaking_changes_detectedYesTrue if any backward-incompatible contract change is found.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.3.3

TDQS

A4.4/5.0
Behavior5/5

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

Annotations already declare readOnly, idempotent, closed-world, non-destructive, so the safety profile is covered. The description goes well beyond that with operational details an agent cannot get from structured fields: a 32 KB payload cap, 60 RPM rate limit, L402 payment (25 sats) as an access mode, a '?demo=true' bypass, and HTTP 400 on invalid input — exactly the kind of pre-call context that prevents failed invocations.

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

Conciseness4/5

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

Purpose and the alternative-tool routing come first, followed by the operational constraints, which is the right ordering. It is dense and slightly telegraphic near the end (the '32 KB, 60 RPM ... L402 (25 sats); HTTP 400' clause is crammed), but no sentence is filler.

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?

An output schema exists, so return values need no explanation. The description covers supported input formats, auto-detection, access constraints, failure mode, and pre-deployment use context — everything an agent needs to invoke it 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?

Schema description coverage is 100% with an explicit enum default for contract_format, so the schema does the heavy lifting and the baseline is 3. The description restates 'baseline_schema_json (with enum defaults)' without adding syntax or format guidance, and only the non-schema '?demo=true' query flag is new information.

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 resource set: compares baseline and candidate OpenAPI 3.1 specs, JSON Schemas, or MCP tool manifests to detect breaking changes, with the change classes enumerated (removed fields, new required inputs, narrowed enums, type mutations). The scope is narrow enough that an agent can separate it from generic diffing or schema-compilation siblings without opening a 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?

Gives an explicit when-to-use framing ('auditing API, JSON Schema, or MCP contract revisions for backward compatibility before deployment') and names one alternative, compile_polyglot_type_schemas, with the condition that selects it. However, the two closest siblings in the roster — detect_mcp_schema_rugpull and detect_breaking_migrations — are never mentioned, leaving real ambiguity for MCP-manifest and migration-adjacent revisions.

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

Deploy Server

Other Tools