Enforce JSON Contracts Without Surprises

POST /validate with payload and either inline schema or schemaUrl (HTTPS). Get valid, errors[] with stable code values, and summary.errorCount. No type coercion; extra properties are EXTRA_FIELD. Supports type, required, properties, items, and nesting up to 100 levels—not full JSON Schema (no $ref, enum, format, etc.). Stateless; serialized payload up to ~10MB.

Try on RapidAPI Basic: 100 requests/month free

Important: schema violations often return HTTP 200 with valid: false. For automation, always check valid (or summary.errorCount), not only status codes.

Real-world use cases

  • API gateways & BFFs — Reject or flag requests before hitting business logic.
  • CI contract tests — Assert sample responses against a checked-in schema.
  • Ingestion — Validate partner webhooks or files on the way in.
  • Centralized schema URL — Pull the latest schema from your CDN (within size/timeout limits).

Who this API helps

  • Backend and API engineers
  • DevOps / CI owners
  • Data teams validating batches against a declared shape

Illustrative output

Valid

{ "valid": true,
  "errors": [],
  "summary": { "errorCount": 0 } }

Invalid (fragment)

{ "valid": false,
  "errors": [
    { "code": "TYPE_MISMATCH",
      "field": "age", ... }
  ] }

What the API does

POST /validate — JSON body: payload (any JSON value to validate) plus either schema or schemaUrl, not both.

GET /health — Liveness.

For cross-sample drift (same field sometimes string, sometimes number across rows) without a fixed schema, use the JSON Payload Consistency Checker. For two versions of a document, use JSON Diff Checker.

Supported schema subset

Structural rules only: types, required keys, nested properties, arrays with items, nullability. Unsupported features include $ref, anyOf / oneOf / allOf, enum, pattern, minLength, format, and conditionals.

Request, response & codes

Endpoint: POST https://json-schema-validator-api.p.rapidapi.com/validate with x-rapidapi-key and x-rapidapi-host: json-schema-validator-api.p.rapidapi.com (verify in your RapidAPI app).

· · ·

Try it in the playground

Choose a sample or edit JSON. Add your RapidAPI key.

Body must be JSON with payload and schema (or schemaUrl).

Subscribe on RapidAPI for production quotas.

Get code

Snippets follow the playground. Path: /validate.

Integration tip: Treat valid === false as failure even when HTTP status is 200.

Real-world examples

1. CI gate

POST a captured API response as payload with your committed schema; exit non-zero if valid is false.

2. Shared schema URL

Publish schema.json on HTTPS; clients send only schemaUrl and payload to avoid huge inline schemas.

3. Strict public API

Combine required + explicit properties so unknown fields surface as EXTRA_FIELD during partner onboarding.

Pricing & tiers (RapidAPI)

Built for teams running high-volume validation at the edge or in CI.

Plans on RapidAPI:

Basic

$0/mo

100 requests/month included

Pro

$9.99/mo

10,000 requests/month included

Mega

$99.99/mo

250,000 requests/month included

Overage and plan changes follow the live RapidAPI listing.

What to expect

Most successful calls return 200. Read valid and errors. 400 for malformed requests or schema fetch/parse issues; 413 for oversized payload.

About this API

Also known as

JSON schema checker, contract validation API, structural JSON validator, request/response schema API.

See the README for the exhaustive unsupported-feature list and security rules for schemaUrl.

Frequently asked questions

  • payload plus exactly one of schema or schemaUrl.
  • No—check valid. Many validation failures use 200 with valid: false.
  • Yes, HTTPS only; private hosts blocked; ~1MB and ~5s limits.
  • About 10MB serialized; larger triggers 413.
  • No. Stateless.
  • No—a strict structural subset; no $ref, enum, format, etc.
  • RapidAPI: Basic 100/mo; Pro $9.99/10k; Ultra $49.99/100k; Mega $99.99/250k.
  • Yes—fail on !valid or errorCount > 0.