Files
hanzo-dev a361b88677
CI/CD / gate (push) Canceled after 0s
CI/CD / containment (push) Canceled after 0s
CI/CD / image (push) Canceled after 0s
CI/CD / rollout (push) Canceled after 0s
CI/CD / reach (push) Canceled after 0s
CI/CD / fanout (push) Canceled after 0s
CI/CD / receipt (push) Canceled after 0s
engine: an operation is named for its product, and its summary is for the caller
An operation id is the generated SDK METHOD NAME and the CLI COMMAND, and a
summary is what the MCP tool list shows a model choosing between tools. This
plane stated neither, so both were defaults, and both defaults were wrong in a
way only a caller sees.

zip derives an unstated id from the path, so the four ops published
`get_v1_engine_status`, `get_v1_engine_models`, `get_v1_engine_model`,
`get_v1_engine_system` — path mangling where the rest of the fleet publishes the
product and the noun. The risk product's thirty-one operations are `riskScore`,
`riskState`, `riskDatasets`, `riskLabelCoverage`; these are now `engineStatus`,
`engineModels`, `engineModel`, `engineSystem`, which is also the rule this
package already applied to its own SCHEMA names and only to those.

A summary defaults to the first sentence of the Go doc comment, and a Go doc
comment opens with the Go IDENTIFIER — so the published summaries read "Status
reports whether the engine deployment is reachable", "Models lists the models
the engine serves", "Model reads one model's load state". A Go symbol name was
the first word a CLI user, an SDK reader and a model picking a tool saw. Each op
now states a summary written in the imperative for the person calling it, and
the doc comment stays a Go doc comment that zipdoc still lifts as the
description: two audiences, two sentences, one declaration.

FORWARDS-ONLY, and it costs nothing: this plane has no customers on it. No
alias, no redirect, no compat shim.

Regenerating from source changes exactly four operation ids. No path is added or
removed, no (path, method) pair moves, no schema changes, and openapi/floor.json
is byte-identical because the operation count did not move.

Co-authored-by: Hanzo Dev <dev@hanzo.ai>
2026-08-04 00:48:16 -07:00

132 lines
3.8 KiB
JSON

{
"openapi": "3.1.0",
"info": {
"title": "Hanzo Cloud API",
"description": "Package engine is Hanzo Engine: which models the serving runtime has loaded, and the GPUs under it.",
"version": "v1"
},
"servers": [
{
"url": "https://api.hanzo.ai"
}
],
"tags": [
{
"name": "engine"
}
],
"paths": {
"/v1/engine/model": {
"get": {
"operationId": "engineModel",
"summary": "Read one model's load state on the serving runtime",
"description": "Model reads one model's load state — loaded, unloading, or not_found, as\nthe engine itself reports it.",
"tags": [
"engine"
],
"parameters": [
{
"name": "model",
"in": "query",
"required": false,
"description": "Model is the model id to inspect, exactly as the model list reports it.",
"schema": {
"type": "string"
},
"example": "Qwen/Qwen3-4B"
}
],
"responses": {
"200": {
"content": {
"application/json": {
"schema": {}
}
},
"description": "ok"
}
}
}
},
"/v1/engine/models": {
"get": {
"operationId": "engineModels",
"summary": "List the models the serving runtime holds, with each one's load state",
"description": "Models lists the models the engine serves, each with its load state — the\nserver's own model table (its standard list envelope, load status\nincluded), relayed verbatim.",
"tags": [
"engine"
],
"responses": {
"200": {
"content": {
"application/json": {
"schema": {}
}
},
"description": "ok"
}
}
}
},
"/v1/engine/status": {
"get": {
"operationId": "engineStatus",
"summary": "Whether the serving runtime is reachable, and which build it runs",
"description": "Status reports whether the engine deployment is reachable and which build\nrevision it runs — an honest lens for \"is the serving runtime up\", never a\nfabricated ok.",
"tags": [
"engine"
],
"responses": {
"200": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/engineStatus"
}
}
},
"description": "ok"
}
}
}
},
"/v1/engine/system": {
"get": {
"operationId": "engineSystem",
"summary": "The serving host's own inventory: devices, memory and build capabilities",
"description": "System reads the engine host's inventory: OS, CPU, memory, every accelerator\ndevice with its VRAM and compute capability, and the build's capabilities\n(CUDA/Metal/flash-attention) — the real hardware under the serving runtime,\nrelayed verbatim.",
"tags": [
"engine"
],
"responses": {
"200": {
"content": {
"application/json": {
"schema": {}
}
},
"description": "ok"
}
}
}
}
},
"components": {
"schemas": {
"engineStatus": {
"properties": {
"reachable": {
"description": "Reachable is true when the engine answered its health probe.",
"type": "boolean"
},
"revision": {
"description": "Revision is the engine build's git revision, present only when\nreachable (the server's own build identity — it publishes no semver).",
"type": "string"
}
},
"type": "object"
}
}
}
}