A converter from JSONSchema to Pydantic classes
Project description
JSONSchema Converter
JSONSchema Converter is a tool that performs conversions from a json-schema file to pydantic classes
installation
pip install jsonschema-converter
requirements
pydantic>=2.5.3 loguru>=0.7.1
usage
script main.py
from jsonschema_converter.main_parser import parse_json_schema
from jsonschema_converter.utils import parse_args
if __name__ == "__main__":
file_name, module_name = parse_args()
parse_json_schema(file_name, module_name)
CLI
python main.py --file_name myjsonschema.json --module_name schemas
examples
you can find examples of jsonschema input and pydantic classes output in the examples folder
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for jsonschema_converter-0.1.7.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2d05740f7d444d6c8964a0fedbdf3b31740740241d64655a6993e81b22316a39 |
|
MD5 | b98f37313aa581c31d8d5dcc623d5644 |
|
BLAKE2b-256 | bcd7a25ca6af4c7ce1d38fddca0aee6c523a906a522aba94b3d1808286ea372b |
Close
Hashes for jsonschema_converter-0.1.7-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 98a826c0fb80762be8387a2da2970967665d5e4b236224e16d4129e608987fd1 |
|
MD5 | 29a6a01cb2b80de0edd01206f2034561 |
|
BLAKE2b-256 | 27e786311e7e0ff00aa5cde85622d4a95ea0a570e20eedbd3129e00c8ade0c7a |