Device authorization

Poll for the agent token

Poll with the device_code until the human approves. Non-issued states are 400 with an RFC 8628 code in error (mirrored in code): authorization_pending, access_denied, expired_token, invalid_grant (unknown or already-redeemed code). Polling too fast yields 429 with slow_down and a Retry-After header. Each code is redeemable exactly once.

post/auth/device/token

Request

  • Base URL: https://dungbeetle.dev
  • URL: https://dungbeetle.dev/auth/device/token
  • Auth: none required

Request body

device_codestring required

Response

Approved — the agent token, shown exactly once.

tokenstring required

Bearer agent token (dbat_ prefix).

token_type'bearer' required
labelstring required
scopesAgentScope[] required

Changes

No recorded changes to this operation across all 1 revision of this API.