Skip to main content
POST
Start a sign-in the account owner can approve from any device
How an agent with no credential gets a live key: mint a code, show the human one sentence, then poll. No authentication required.
name is what the human sees on the approval screen and becomes the key’s label. An empty body is valid.

What to do with the response

Send an existing zn_test_ sandbox key as the bearer and the sandbox comes along: on approval its orders move onto the owner’s account, the sandbox key keeps working, and the account may earn a starter credit.
Show human_message and wait. Do not open a browser yourself, and do not start a second code while one is pending.

Authorizations

Authorization
string
header
required

Zinc API key (Bearer zn_...)

Headers

authorization
string | null

Body

application/json
name
string | null

What to call yourself on the approval screen and as the key's label, e.g. 'Claude Code' or 'acme-restock-agent'.

Maximum string length: 100

Response

Successful Response

device_code
string
required

Your half of the handshake. Keep it; send it when polling. Never show it to the human.

user_code
string
required

The short code the human sees on the approval page.

verification_uri
string
required

Where the human approves; they will be asked for user_code.

verification_uri_complete
string
required

Same page with the code filled in. Show this one.

expires_in
integer
required

Seconds until this code stops working.

interval
integer
required

Minimum seconds between polls of POST /device/token.

human_message
string
required

One sentence to show your operator, ready to paste.

next
string
required

What to do now.