Getting started
Two commands add honig to your crate:
cargo honig init path/to/openapi.yaml
cargo honig generate
init adds the [package.metadata.honig.api] section and the honig dependency to your Cargo.toml.
generate writes the module to src/api and toggles honig features as needed by the generated code.
Then you can declare the module in src/lib.rs or src/main.rs:
pub mod api;
Recipes builds a server and a client from an example description, then whole setups around them.
Update the API
cargo honig generate updates the module after every change to the description.
Every place your code must change becomes a compile error: a new operation is a missing method, a new response is a missing match arm.
Run cargo honig check in CI to assert that the module is up to date with the description or the generator.