Use Phaseo when your Rust service needs a synchronous Phaseo Gateway client.
Create a client
Load the API key and optional base URL from the environment:
Or pass the key directly:
Phaseo redacts the API key and custom header values from its Debug output.
Send a Responses request
The complete JSON response remains available in response.body.
Send a Chat Completions request
Call another JSON endpoint
Use post(...) for a Phaseo endpoint that does not yet have a high-level helper:
The path may include or omit its leading slash.
Handle Gateway errors
PhaseoError contains an HTTP status and parsed JSON body when the Gateway returned an error. Transport and configuration failures have no HTTP status.
Next
Last modified on July 26, 2026