← Back to News
Research

JSON Structure: A Type-First Alternative to JSON Schema

JSON Structure: A Type-First Alternative to JSON Schema

A Type-First Take on Describing JSON

JSON Structure is a data-definition language for JSON, introduced as an individual IETF Internet-Draft (draft-vasters-json-structure-core) by Clemens Vasters of Microsoft and revised through mid-2026. It is not an IETF work item and has no standards standing yet — but it is a substantial, actively-developed proposal worth watching.

Where JSON Schema layers validation rules onto existing documents, JSON Structure treats a schema as a declaration of a type system. The stated goals are strict typing, determinism, and modularity, so that a document maps cleanly to programming-language types and database columns. It deliberately avoids polymorphism — a sub-type value cannot be assigned to a base-type property — to sidestep the mapping ambiguities that make code generation from JSON Schema hard.

An Extended Type System

The core draft defines a richer primitive set than JSON's four base types. Alongside string, number, boolean, and null, it adds:

  • Sized integersint8/int16/int32 (aliased integer), int64, int128, and the uint variants.
  • Floating point and high-precision decimal — decimals are carried as strings to preserve accuracy beyond IEEE 754 doubles.
  • Temporal and identifier typesdate, datetime (RFC 3339), time, duration, uuid, uri, jsonpointer.
  • Binary — base64-encoded by default, with optional compression.

Compound types cover the shapes real data takes: object, array, set (unordered, unique), map (string-keyed), tuple (fixed-length, named elements), choice (discriminated unions), and any.

Modularity and Inheritance

A schema document is rooted by three keywords — $schema (the meta-schema URI), $id, and name — with reusable types organized under definitions and referenced by JSON Pointer via $ref.

Reuse comes in two forms. Abstract base types marked abstract: true are merged into concrete types through $extends (multiple inheritance is allowed via pointer arrays), and extending types may not redefine inherited properties. Optional "add-ins" are advertised at the document level with $offers and applied to instances with $uses, letting schemas compose enhancements without editing the base type.

A Family of Drafts

The core is one of several coordinated drafts. Companion specifications cover Validation (constraint keywords without structural impact), Import (pulling in external schema documents), Conditional Composition, Alternate Names and Descriptions (multilingual metadata), Symbols/Scientific Units/Currencies, and Relations (identity and inter-type constraints).

For anyone generating types or database schemas from JSON today, JSON Structure is a notably different bet than JSON Schema — and a reminder that the question of "how do we describe JSON precisely?" is still open. If you want a stricter contract for the JSON you ship, validate the syntax first, then decide whether a schema language is doing structural typing or just spot-checks.

Sources

Related on fixjson.org