facet-json-schema
facet-json-schema
Generate JSON Schema from facet type metadata.
This crate uses facet's reflection capabilities to generate JSON Schema definitions
from any type that implements Facet. The generated schemas can be used for:
- API documentation (OpenAPI/Swagger)
- Runtime validation
- Cross-language type generation
- Editor autocompletion
Usage
use Facet;
use to_schema;
let schema = ;
println!;
Output
LLM contribution policy
Sponsors
Thanks to all individual sponsors:
...along with corporate sponsors:
...without whom this work could not exist.
Special thanks
The facet logo was drawn by Misiasart.
License
Licensed under either of:
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.