hanzo-client
The Rust client for the Hanzo API. Generated from
hanzoai/cloud's openapi.yaml, which cloud emits by projecting its own
routers, so it cannot describe a route the binary does not serve. Every Hanzo
SDK reads that one document, so this crate and the Go, TypeScript and Python
clients describe the same product. Which commit of it this crate is a projection
of is written beside the code, in the repository's .spec-lock.
Every service, one crate.
[]
= "0.1"
= { = "1", = ["full"] }
Use
Every request carries a bearer token. Configuration::default() already points
at https://api.hanzo.ai; set the token and go.
use ;
async
Org-scoped services (kv, agents) also need an X-Org-Id header — build
cfg.client with it as a default header.
Flows
Six runnable journeys, the same six in every Hanzo SDK, live in this
repository's examples/:
HANZO_API_KEY=sk-...
hello, chat, money, store, agent, tools.
Do not edit
src/ is generated. The document comes from hanzoai/cloud; run
./scripts/generate.sh from the repository root to project it again, and
./scripts/generate.sh --check to prove the committed tree has not drifted.
License
MIT OR Apache-2.0.