Hanzo
OpenapiAgents

Mints (or rotates) the claim key a `hanzo code --serve` daemon presents to…

Mints (or rotates) the claim key a `hanzo code --serve` daemon presents to claim work for this machine, and returns it ONCE: only its SHA-256 hash is…

POST /v1/agents/targets/{id}/key

Addresshttps://api.hanzo.ai/v1/agents/targets/{id}/key
MethodPOST
Operationpost_agents_targets_by_id_key
AuthAuthorization: Bearer $HANZO_API_KEY

Mints (or rotates) the claim key a hanzo code --serve daemon presents to claim work for this machine, and returns it ONCE: only its SHA-256 hash is stored. Rotating supersedes any prior daemon, so only the machine's owner — or an org admin — may call it; every other caller gets the same not-found an unknown id gets, and learns nothing about what exists.

Request

1 field.

FieldInTypeRequiredDescription
idpathstringyesID is the target to act on, from the path.

Response

StatusBodyMeaning
200claimKeyOutok

200 body — 2 fields.

FieldInTypeAlwaysDescription
claimKeybodystringClaimKey is the capability itself.
targetIdbodystringTargetID is the machine the key authenticates.

Failure carries the platform error shape — see Errors.

Examples

hanzo agents targets key <id>

Agents API · All Hanzo APIs · Interactive reference

How is this guide?

On this page