Bug Days

JSON Schema Validator / Schema Doctor

Find the field. Understand the rule. Share the reproducer. All checks run on your device.

Try an example:
Local reference schemas (0)

For external $ref, add JSON files with matching absolute $id values. Relative references resolve against the root schema’s $id. No URLs are fetched. Up to 12 files; 500 KB each, 1 MB combined.

    Diagnosis

    Paste a schema, or try an example above.

    Review your shared example

    The link includes both inputs, settings, and attached reference schemas below. Use a small fictional example. Anyone with the link can read it; sharing does not redact secrets.

    Walk through a failing API responseFix types, enums, nested constraints, and extra keys with a runnable example.Just need valid JSON syntax?Format, inspect a tree, and copy paths in the JSON Formatter.Compare the response before and afterUse JSON Diff to inspect what changed between API versions.

    Validate JSON against a schema, not just its syntax

    A response can be perfectly valid JSON and still break a client. An ID might arrive as a string, a status might use the wrong enum value, or a nested array item might omit a required field. This JSON Schema validator checks the document against your contract and reports a JSON Pointer, line, and schema rule for each failure. Select a finding to jump to the relevant input. Missing fields point to the containing object.

    Required fields, additional properties, and union errors

    properties describes fields; it does not make them mandatory. Put mandatory names in required. An explicit null differs from a missing property and must be allowed by its schema. additionalProperties: false rejects undeclared keys. For anyOf, one or more branches may match; oneOf needs exactly one. The diagnosis preserves branch errors so you can see the rule behind the union failure. Data is never coerced, stripped, or filled with defaults.

    Choose the right draft and format behavior

    The $schema declaration determines the dialect. Draft 7 tuple arrays use an array under items; Draft 2020-12 uses prefixItems. Auto defaults to 2020-12 only when no declaration is present. Format assertions are optional: turn them on to validate supported formats such as email and date-time. Unknown formats or keywords produce diagnostics rather than a silent promise that they were enforced. Custom vocabularies, legacy drafts, and asynchronous validation are outside this tool’s scope.

    Check structured-output schemas before making an API call

    The optional OpenAI profile checks a documented subset independently of ordinary JSON Schema validation. A schema can validate your sample while failing a provider-specific rule. Review proposed changes to object requirements before applying them; tightening a schema changes which data it accepts. This is a local troubleshooting aid, not a model call, and it needs no API key. For generated application models, try JSON to TypeScript, Zod, and Pydantic.

    Share the actual validation problem

    A useful bug report includes the schema, a minimal failing document, and the chosen dialect. Share example restores those inputs and reruns the diagnosis. Review the visible preview before choosing an embedded link or optional stored short link. Report exports exclude the original documents but retain field paths and diagnostic text, so review them too. Files stay local during validation; there is no automatic remote reference loading or background document upload.

    JSON Schema validator questions

    What is the difference between JSON validation and JSON Schema validation?

    JSON validation checks syntax. JSON Schema validation checks the shape and rules of a document: required keys, types, arrays, enums, ranges, and more. Schema Doctor checks the schema itself before validating your data.

    Which JSON Schema drafts are supported?

    Draft 7, 2019-09, and 2020-12. Auto reads $schema and defaults to 2020-12 when it is absent. A conflicting selection is reported rather than silently changing dialects.

    Can I validate $ref without uploading files?

    Yes. Internal references work directly. Add local reference files with absolute $id values that match the resolved reference URLs. The validator never downloads remote schemas.

    Does a passing structured-output check guarantee OpenAI will accept my schema?

    No. The optional OpenAI profile is a dated set of local checks, not an API call or a complete model-specific compatibility guarantee. Review its scope and test your chosen model.

    Are my JSON and schemas uploaded?

    Validation happens on this device. Sharing is optional: review both inputs and reference files before creating a link. Embedded links carry data in the URL fragment; choosing a stored short link uploads the selected share state.