Summarising the other answers, here are the JSON schema generators proposed so far:

Online:

  • https://www.liquid-technologies.com/online-json-to-schema-converter (1 input)
  • http://www.jsonschema.net (1 input)
  • https://easy-json-schema.github.io (1 input)
  • https://json.ophir.dev/ (1 input, nice UI)

Python:

  • https://github.com/gonvaled/jskemator (1 input but allows iteration)
  • https://github.com/perenecabuto/json_schema_generator (1 input)
  • https://github.com/rnd0101/json_schema_inferencer (1 input I think)
  • https://pypi.python.org/pypi/genson/ (multiple inputs)
  • https://pypi.python.org/pypi/skinfer (multiple inputs)

NodeJS:

  • https://github.com/Nijikokun/generate-schema (multiple inputs (pass object array))
  • https://github.com/easy-json-schema/easy-json-schema (1 input)
  • https://github.com/aspecto-io/genson-js (multiple inputs)

Ruby:

  • https://github.com/maxlinc/json-schema-generator (1 input)
Answer from Steve Bennett on Stack Overflow
🌐
PyPI
pypi.org › project › genson
genson · PyPI
GenSON is a powerful, user-friendly JSON Schema generator built in Python.
      » pip install genson
    
Published   May 15, 2024
Version   1.3.0
🌐
Pydantic
docs.pydantic.dev › latest › concepts › json_schema
JSON Schema - Pydantic Validation
The TypeAdapter class lets you create an object with methods for validating, serializing, and producing JSON schemas for arbitrary types. This serves as a complete replacement for schema_of in Pydantic V1 (which is now deprecated). Here's an example of generating JSON schema from a TypeAdapter:
🌐
GitHub
github.com › python-jsonschema › jsonschema
GitHub - python-jsonschema/jsonschema: An implementation of the JSON Schema specification for Python · GitHub
>>> from jsonschema import validate >>> # A sample schema, like what we'd get from json.load() >>> schema = { ... "type" : "object", ... "properties" : { ... "price" : {"type" : "number"}, ... "name" : {"type" : "string"}, ... }, ... } >>> # If no exception is raised by validate(), the instance is valid. >>> validate(instance={"name" : "Eggs", "price" : 34.99}, schema=schema) >>> validate( ... instance={"name" : "Eggs", "price" : "Invalid"}, schema=schema, ...
Starred by 4.9K users
Forked by 609 users
Languages   Python 99.8% | TypeScript 0.2%
🌐
W3Resource
w3resource.com › JSON › snippets › json-schema-generator-examples.php
JSON Schema Generator
Learn how to generate JSON schema easily using Python libraries and online tools. Step-by-step examples, explanations, and tips for validation and customization.
🌐
PyPI
pypi.org › project › json-schema-codegen
json-schema-codegen · PyPI
import jsonschemacodegen.cpp as ...rate(sampleSchema, 'Example', 'example') A Python3 class is generated for each schema node; the class encapsulating the data described by the schema....
      » pip install json-schema-codegen
    
Published   May 01, 2023
Version   0.6.3
🌐
GitHub
github.com › openapi-json-schema-tools › openapi-json-schema-generator
GitHub - openapi-json-schema-tools/openapi-json-schema-generator: OpenAPI JSON Schema Generator allows auto-generation of API client libraries with a focus on JSON schema given an OpenAPI document · GitHub
To get a list of general options available, please run java -jar target/openapi-json-schema-generator-cli.jar help generate · To get a list of python specified options (which can be passed to the generator with a config file via the -c option), please run java -jar target/openapi-json-schema-generator-cli.jar config-help -g python
Starred by 172 users
Forked by 14 users
Languages   Java 48.8% | Handlebars 48.6% | Python 1.5% | Shell 1.0% | Ruby 0.1% | Dockerfile 0.0%
Find elsewhere
🌐
GitHub
github.com › altair-viz › schemapi
GitHub - altair-viz/schemapi: Auto-generate Python APIs from JSON schema specifications
JSON Schema is a vocabulary that allows you to annotate and validate JSON documents. schemapi is a package that lets you auto-generate simple Python object-based APIs given a valid JSON schema specification.
Starred by 79 users
Forked by 12 users
Languages   Python 82.4% | Jupyter Notebook 17.4% | Makefile 0.2% | Python 82.4% | Jupyter Notebook 17.4% | Makefile 0.2%
🌐
GitHub
github.com › perenecabuto › json_schema_generator
GitHub - perenecabuto/json_schema_generator: A simple json schema generator from any json source
A simple json schema generator from any json source - perenecabuto/json_schema_generator
Starred by 261 users
Forked by 71 users
Languages   Python 100.0% | Python 100.0%
🌐
Unstructured
docs.unstructured.io › api-reference › partition › generate-schema
Generate a JSON schema for a file - Unstructured
You want to generate a schema for a JSON file that Unstructured produces, so that you can validate, test, and document related JSON files across your systems. Use a Python package such as genson to generate schemas for your JSON files.
🌐
DEV Community
dev.to › stefanalfbo › python-json-schema-3o7n
Python JSON schema - DEV Community
May 9, 2024 - JSON Schema can be a great tool to document this contract, define constraints and validate the contract. In Python we can use the jsonschema library to enable the power of JSON Schema in our projects.
🌐
GitHub
github.com › wolverdude › GenSON
GitHub - wolverdude/GenSON: GenSON is a powerful, user-friendly JSON Schema generator built in Python.
GenSON is a powerful, user-friendly JSON Schema generator built in Python. - wolverdude/GenSON
Starred by 704 users
Forked by 74 users
Languages   Python 100.0% | Python 100.0%
🌐
Libraries.io
libraries.io › pypi › generate-json-schema
generate-json-schema 0.1.5 on PyPI - Libraries.io - security & maintenance data for open source software
# Use the path of the directory already within your project from json_schema_converter.generate_schema import generate_json_schema schema = generate_json_schema("/pytests/schemas/teste.json")
🌐
JSON Type Definition
jsontypedef.com › docs › python-codegen
Generating Python from JSON Typedef schemas
You can generate Python with jtd-codegen using the --python-out option, whose value must be a directory that jtd-codegen can generate code into. For example, if you have this schema in schemas/user.jtd.json:
🌐
JSON Schema
json-schema.org › tools
JSON Schema - Tools
Toolings below are written in different languages, and support part, or all, of at least one recent version of the specification · Listing does not signify a recommendation or endorsement of any kind
🌐
GitHub
github.com › topics › json-schema-generator
json-schema-generator · GitHub Topics · GitHub
JSON (de)serialization, GraphQL and JSON schema generation using Python typing.
🌐
jsonschema
python-jsonschema.readthedocs.io
jsonschema 4.26.0 documentation
PyPI version Supported Python versions Build status ReadTheDocs status pre-commit.ci status Zenodo DOI jsonschema is an implementation of the JSON Schema specification for Python. It can also be us...
🌐
JSON Schema
json-schema.org › learn › getting-started-step-by-step
Creating your first schema
This tutorial guides you through the process of creating a JSON Schema.
🌐
Apidog
apidog.com › articles › how-to-create-json-schema-python
How to Create JSON Schema in Python
October 20, 2023 - Creating JSON schemas in Python is an essential skill for ensuring data quality and integrity in your applications. Python's "jsonschema" library simplifies the process of defining schemas and validating data against them.