Labsco
MCP SERVER

Zod Contract Mock Forge MCP

by vola-trebla

Turn a Zod schema into valid mocks, deliberate violations, and a read on what a change breaks.

Developer Conversions, Encoding & Test Data
Summary
Zod schemas an agent can actually run.

A Zod schema is runtime code — a model can read it but not execute it, which is why hand-written fixtures almost validate and then do not. Running the schema means the mock is valid by construction, and every violation targets a real constraint rather than a guessed one.

What it is

A layer that executes Zod schemas on an agent's behalf: it generates payloads that satisfy a schema, payloads that violate each constraint, and reports how a schema has drifted or evolved.

What you get
  • Valid mock data matching a schema, in whatever count you ask for
  • Structurally valid but value-diverse mocks, seeded, for property-based testing
  • Invalid payloads per constraint: missing fields, type mismatches, min/max, email, uuid, url
  • Per-variant violations for every branch of a union or discriminated union
  • The schema introspected into its actual constraints
  • A schema read straight from a file instead of pasted in as code
  • Drift detected between a schema and the docs it is supposed to match
  • A schema change evaluated for what it breaks
Requirements

Zod schemas, either passed in as code or read from a file the server can see. Published on npm as zod-contract-mock-forge-mcp.

Setup effort

One command — npm install -g zod-contract-mock-forge-mcp