JSON Schema builder
Project description
Build JSON schemas easily in Python.
See documentation for more informations.
Installation
pip install jsonschema-builder
Usage
import jsonschema
import jsb
schema = jsb.typed(
jsb.schema(id='/schemas/myschema#', meta=jsb.draft04()),
type='object',
properties={
'foo': jsb.typed(jsb.schema(), type='string'),
'bar': jsb.typed(jsb.schema(), type='integer')
}
)
data = {
'foo': 'bar',
'bar': 42
}
jsonschema.validate(data, schema)
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
File details
Details for the file jsonschema-builder-0.1.1.tar.gz
.
File metadata
- Download URL: jsonschema-builder-0.1.1.tar.gz
- Upload date:
- Size: 5.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fa2eaa4e69effff4495c6abe8d93bfc22ed27b8de3a46a19b1d5fbc1dfb3bc13 |
|
MD5 | 822d87b8bf3e09b7d5dbdaa840eeaa1a |
|
BLAKE2b-256 | 67e4c9f806675c901f72e24d4974431b08120d988bcc9657db523ad931c95391 |
File details
Details for the file jsonschema_builder-0.1.1-py3-none-any.whl
.
File metadata
- Download URL: jsonschema_builder-0.1.1-py3-none-any.whl
- Upload date:
- Size: 8.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 99785f7b24be1159020ea210403b9eff3f488630c45c1b5bd473a424e866ced2 |
|
MD5 | 25de36b1ad80c5f71c65e3e2f6ffdfa5 |
|
BLAKE2b-256 | 3dfa64da23a4e3b0b236ebc71cfed8b6df8bb87e5af3529d9f90d0302811d8c2 |