Breaking changes in MCP servers

Which schema changes break existing callers -- and which only look like they do.

Install: pip install mcp-testbench  |  PyPI: pypi.org/project/mcp-testbench

The classification

mcp-testbench check compares a live server against a committed snapshot and classifies every change as breaking, non-breaking, routing (descriptions and annotation hints -- behaviour may change, calls do not break) or cosmetic (titles). Only breaking fails the check.

Input and output schemas follow opposite rules

A change that is safe on an input schema can be breaking on an output schema, and vice versa. Callers send inputs and rely on outputs, so the direction of every rule flips:

ChangeInput schemaOutput schema
property removedbreakingbreaking
property addedbreaking if required, else non-breakingnon-breaking
became requiredbreakingnon-breaking
no longer requirednon-breakingbreaking
type / enum widenednon-breakingbreaking
type / enum narrowedbreakingnon-breaking
constraints tightenedbreakingnon-breaking
constraints loosenednon-breakingbreaking

The same direction logic applies to enum changes, additionalProperties, and numeric / length constraints (minimum, maxLength, pattern, ...) at any nesting depth, with local $ref pointers resolved.

Examples

ChangeClass
tool search removedbreaking
new optional parameter limitnon-breaking
parameter query became requiredbreaking
output field result.url removedbreaking
tool description rewrittenrouting
destructiveHint flipped false -> truerouting
tool title changedcosmetic

Composition: anyOf / oneOf / allOf, branch by branch

Composition keywords are diffed branch by branch. Branches are matched between the old and new schema deterministically: first by identical resolved content, then by a strong key (the $ref target, then title), then by structural similarity (shared type and property names). Matched branches are diffed recursively with the same engine, under a subject that names the branch -- e.g. tool search.input.anyOf[ref=Config].timeout. Pure reordering of branches is silent.

A union branch is a widening or narrowing of the value space, exactly like an enum, and follows the same direction rule. An allOf branch is the opposite: adding one adds a constraint (narrows), removing one drops a constraint (widens).

Composition changeInput schemaOutput schema
anyOf/oneOf branch removedbreakingnon-breaking
anyOf/oneOf branch addednon-breakingbreaking
allOf subschema added (new constraint)breakingnon-breaking
allOf subschema removednon-breakingbreaking
change inside a matched branchclassified by the normal rules, reported at the branch path

If no branch on one side matches any branch on the other and the sets differ, the composition is reported as a single breaking composition-replaced finding rather than silence or a pile of add/remove noise: nothing about the old value space can be proven to survive.

Known limits

Branch matching is structural, not semantic: two branches that are similar in shape but different in meaning can be matched and diffed against each other (their inner changes are still reported), and a wholesale rewrite of every branch surfaces as composition-replaced instead of per-branch detail. Everything else -- tools, prompts and resources, input and output schemas, nested objects and arrays -- is compared recursively.