Run
Package platform is Hanzo PaaS: deploy containers to your own tenant namespace — builds, releases, environments, logs, custom domains.
Package platform is Hanzo PaaS: deploy containers to your own tenant namespace — builds, releases, environments, logs, custom domains.
| Base URL | https://api.hanzo.ai |
| Operations | 1 |
| Auth | Authorization: Bearer $HANZO_API_KEY |
run
POST /v1/run
Runs a container image and gives back a URL.
The one-call shortcut over project → app → deploy: give it a name and an
image and it creates or updates an image-source application in your org's
DEFAULT project, deploys it through the same operator Service-CR writer
everything else uses, and answers its id, name, live URL, status and shape.
Re-running the same name UPDATES it in place, so the call is idempotent by name.
What it produces is a first-class application, not a special object: it is listable, stoppable and redeployable through the /v1/platform routes like any other app.
minScale is the replica floor. maxScale above it declares an autoscaling
ceiling; maxScale: 0 means no autoscaler at all — a fixed run at the floor.
Both are clamped to the deployment's limits. runtime and shape are accepted
for the client contract and echoed back: the image is the runtime unit and sizing
is the operator's default.
It is BILLING-GATED before it touches the cluster: a flat per-run fee is authorized against the org's own prepaid balance first, so an org that cannot pay is refused without anything being created. An unreachable cluster is 503 — a run never reports a URL it did not create. Secret env is sealed into KMS and fails closed without it.
Requires a validated principal; 403 without one. The org is resolved from that validated identity and is what both pays and owns the namespace — it is never read from the body.
Request body — application/json (required)
| Field | Type | Required | Description |
|---|---|---|---|
env | EnvVarJSON[] | — | Env is the run's environment. Keys must match ^[A-Za-z_][A-Za-z0-9_]*$; a variable marked secret: true is sealed… |
gpu | integer | — | GPU is how many GPUs the run asks for; a negative value is 400. |
image | string | — | Image is the container image to run. |
maxScale | integer | — | MaxScale above the floor declares an autoscaling ceiling; 0 means no autoscaler at all — a fixed run at the floor. |
minScale | integer | — | MinScale is the replica floor, clamped to the deployment's limit. |
name | string | — | Name is the run's name, and the slug is derived from it. |
port | integer | — | Port is the container port the run listens on. |
runtime | string | — | Runtime is accepted for the client contract and echoed nowhere: the image IS the runtime unit. |
shape | string | — | Shape is a compute size label, echoed back; sizing is the operator's default. |
How is this guide?
Router
Package ai is Hanzo AI — the model API on /v1 (/v1/chat/completions, /v1/messages, /v1/models and the rest of hanzoai/ai's surface) — mounted into a cloud binary with the money, ingest and telemetry…
Runner
Package platform is Hanzo PaaS: deploy containers to your own tenant namespace — builds, releases, environments, logs, custom domains.