{"uid":"cap_kEA-bACTqNKj40mZvrDAc","slug":"24k-labs-json-schema-validator-1994f243","name":"24K Labs JSON Schema Validator","description":"Validate a JSON instance against a JSON Schema (draft 7 / 2020-12 subset); returns a valid flag plus per-field errors with codes and JSONPath.","url":"https://api.24klabs.ai/api/v1/jsonschema-validate","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"schema":{"type":"object"},"instance":{"type":"object"}}},"responseSchema":{"type":"json","example":{"valid":true,"errors":[]}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_W5haP22Mq37xvKHH7f2iu","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Validates a JSON instance against a JSON Schema (draft 7 / 2020-12 subset) and returns a valid flag with per-field errors including codes and JSONPath locations.","exampleAgentPrompt":"Check whether this JSON object is valid against my JSON Schema (draft 7): the instance is {\"name\":\"Alice\",\"age\":\"thirty\"} and the schema requires name as a string and age as an integer — give me the valid flag and any per-field errors with their JSONPaths.","exampleUseCases":[{"title":"API request body pre-flight check","prompt":"Before I send this payload to our orders API, validate it against our draft-7 schema — the instance has {\"orderId\":123,\"items\":[]} and the schema requires items to be a non-empty array. Tell me which fields fail and why."},{"title":"CI pipeline data contract enforcement","prompt":"In my CI pipeline I need to check that this generated config JSON matches our 2020-12 schema — run the validation and return all per-field errors with JSONPath so I can fail the build if anything's wrong."},{"title":"User-submitted form data validation","prompt":"A user just submitted a registration form and I got this JSON back: {\"email\":\"not-an-email\",\"age\":-1}. Validate it against our user schema (draft 7) and return the list of validation errors with field paths so I can show them the right error messages."}],"resultDescription":"Returns a JSON object containing a boolean 'valid' flag indicating overall schema compliance, plus an array of per-field error objects each with an error code, a human-readable message, and a JSONPath string pointing to the exact failing location in the instance.","failureModes":["Malformed JSON instance causes a parse error response","Invalid or unrecognized JSON Schema syntax returns a schema-error response","Use of JSON Schema features outside the draft 7 / 2020-12 subset may return unsupported-keyword errors","Empty or missing request body returns a 400 bad request","Extremely deeply nested schemas may time out or hit size limits"],"whenToPreferThis":"Choose this endpoint when you need per-field JSONPath-level error detail from a draft-7 or 2020-12 JSON Schema validation — especially useful in agent pipelines, CI/CD data contract checks, or form validation flows where you need structured, machine-readable error codes rather than a pass/fail only. Prefer over generic validators when you need the exact failing path and error code for downstream error handling or user feedback.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T06:57:27.247Z","isFirstParty":false}