Hanzo
OpenapiIam

Resolve a SECRET key to the principal it authenticates

Answers who a secret key belongs to — the owner and name a gateway needs to attribute and bill a request that arrived carrying an `sk-`.

GET /v1/iam/keys/principal

Addresshttps://api.hanzo.ai/v1/iam/keys/principal
MethodGET
Operationget_iam_keys_principal
AuthAuthorization: Bearer $HANZO_API_KEY

Answers who a secret key belongs to — the owner and name a gateway needs to attribute and bill a request that arrived carrying an sk-. This is the noun spelling of /v1/iam/get-user?accessKey=, the same handler at the address that replaces it; both answer while callers migrate.

It resolves a KEY and nothing else. The verb it replaces also reads a user by ?id=, and carrying that here would make this a second address for the user read — the exact thing being retired. Ask for a person by name at the user read; ask here only what a credential resolves to.

Requires a confidential caller: the resolver authenticates as an app, so a request without that credential resolves nothing rather than falling back to an anonymous lookup. An unresolvable key answers with a code distinguishing expired from wrong-door from unknown, so the holder can be told which one cure applies.

Request

GET /v1/iam/keys/principal takes no parameters and no body — the credential is the whole request.

Response

The document declares no response body for this operation. It answers 200 on success and the platform error shape on failure — see Errors.

Examples

hanzo has no subcommand for this operation — the CLI serves only what cloud's live route table confirms. Use HTTP or an SDK.


IAM API · All Hanzo APIs · Interactive reference

How is this guide?

On this page