Typed json data
Project description
Jata - Typed Json Data
Simple class to convert to and from json with benefits of IDE autocomplete. Designed primarily for using Json web APIs directly without an unnecessary wrapper client. See example.py for usage
Features
- Allows to declare types and defaults in class definition
- No restriction on the order of default and non-default fields even for inherited fields
- Does no validation, all fields are optional and can be set later
- Allows python keywords as fields with
pykw_
prefix. The prefix is automatically removed/added on json conversion - Does not care about extra unexpected fields. They just silently exist. Beware of typhos!
TODO
- Tool for generating constructor stubs (They don't work for IDE autocomplete)
- Tool for generating class from a sample json
- unit tests
- write doc - Using StrEnum, constructor example, Comparison table
- Continuous integration
- Optionally do validation before serializing
Related
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
python-jata-1.2.tar.gz
(9.0 kB
view hashes)
Built Distribution
Close
Hashes for python_jata-1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3c05e3008721ebf19b95b6c51495afa9df6017f88356e4d48853034a20011579 |
|
MD5 | c522ce71192e23097d8cb5e73d914328 |
|
BLAKE2b-256 | 9d3500808b48ec65b860d1f097e3fc85aa27921a28ddddb1e0d3595ea9998543 |