JSON Schema

Infer a schema from JSON, validate against one, and export TypeScript and Zod.

Runs in browser

Use from your agent

Streamable HTTP at https://benchline.fabwaseem.com/mcp. No key. The tool name is validate_json_schema.

mcp.jsonjson
1{
2 "mcpServers": {
3 "benchline": {
4 "url": "https://benchline.fabwaseem.com/mcp"
5 }
6 }
7}
tools/calljson
1{
2 "jsonrpc": "2.0",
3 "id": 1,
4 "method": "tools/call",
5 "params": {
6 "name": "validate_json_schema",
7 "arguments": {
8 "json": "{}"
9 }
10 }
11}

How it works

Free JSON Schema generator and validator. Infer a schema from a sample, check a document against a schema you paste, and export TypeScript types and a Zod object. Errors include the path that failed.

  1. 01

    Paste JSON

    A sample is enough to infer a schema, TypeScript, and Zod.

  2. 02

    Or paste a schema

    Switch to Validate and add a schema. Each error names a path such as /year.

  3. 03

    Copy the export

    The TypeScript type and the Zod object can be copied on their own.

FAQ