JSON Schema Validator
Validate a JSON document against a JSON Schema (draft 2020-12) with precise error paths — the exact check agents need before trusting structured output. Returns valid/invalid plus every violation with its JSON Pointer location and message.
Worked examples
Valid object
GET /api/v1/dev/json-schema-validator?schema=%7B%22type%22%3A%22object%22%2C%22required%22%3A%5B%22id%22%5D%2C%22properties%22%3A%7B%22id%22%3A%7B%22type%22%3A%22number%22%7D%7D%7D&data=%7B%22id%22%3A%2042%7D
Result: ✓ Valid — data conforms to the schema
Wrong type
GET /api/v1/dev/json-schema-validator?schema=%7B%22type%22%3A%22object%22%2C%22required%22%3A%5B%22id%22%5D%2C%22properties%22%3A%7B%22id%22%3A%7B%22type%22%3A%22number%22%7D%7D%7D&data=%7B%22id%22%3A%20%2242%22%7D
Result: ✗ Invalid — 1 violation(s)
Nested array constraints
GET /api/v1/dev/json-schema-validator?schema=%7B%22type%22%3A%22object%22%2C%22properties%22%3A%7B%22tags%22%3A%7B%22type%22%3A%22array%22%2C%22items%22%3A%7B%22type%22%3A%22string%22%7D%2C%22minItems%22%3A1%7D%7D%7D&data=%7B%22tags%22%3A%20%5B%5D%7D
Result: ✗ Invalid — 1 violation(s)
Machine API (x402)
$0.003 / callThis tool is also a JSON API for AI agents. Requests without payment receive 402 Payment Required plus instructions; agents pay USDC on Base via the x402 protocol — no accounts, no API keys.
GET /api/v1/dev/json-schema-validator?schema=%7B%22type%22%3A%22object%22%2C%22required%22%3A%5B%22id%22%5D%2C%22properties%22%3A%7B%22id%22%3A%7B%22type%22%3A%22number%22%7D%7D%7D&data=%7B%22id%22%3A%2042%7D HTTP/1.1
Host: agentstoolshub.com
→ 402 (payment required, instructions in headers)
→ 200 (after X-PAYMENT header; JSON body below)
{
"tool": "dev/json-schema-validator",
"input": {"schema":"{\"type\":\"object\",\"required\":[\"id\"],\"properties\":{\"id\":{\"type\":\"number\"}}}","data":"{\"id\": 42}"},
"result": { "value": 1, "answer": "✓ Valid — data conforms to the schema" }
}Agent docs: /llms.txt · OpenAPI spec · integration guide
About this tool
Runs real draft-2020-12 JSON Schema validation (the current standard) and reports every violation with its JSON Pointer path, not just the first error. The deterministic way for an agent to check that a payload or tool output matches the structure it claims.
Frequently asked questions
Which JSON Schema drafts are supported?
Draft 2020-12 (the current standard). Older draft-07 schemas are almost always compatible; $schema declarations for other dialects are ignored.
How many errors are returned?
All of them are collected; the API response lists up to 20 with exact JSON Pointer locations, plus the keyword that failed (required, type, minItems…).