Search and jump to any tool. Type to filter; use arrow keys to move and Enter to select.
The JSON Schema generator infers a draft 2020-12 schema from one example document.
The JSON Schema generator infers a draft 2020-12 schema from one example document. It records types, marks the keys it saw as required, and recognizes common string formats such as dates, emails, URLs and UUIDs. The result is a solid first draft of a contract you can tighten by hand for validation or API documentation.
{"id":1,"price":9.99,"email":"a@b.co","created":"2024-05-01T10:00:00Z","nick":null}(the $schema line naming draft 2020-12 comes first, then) "title": "Product", "type": "object", properties id = integer, price = number, email = string with format email, created = string with format date-time, nick = null, and "required" listing all five keys.
Good to know. A schema inferred from one sample is a starting point: it cannot know minimum lengths, numeric ranges or which fields are truly optional. Add those constraints yourself.
Added as the root `title` when set.