Account

Poll for the session minted by an approved device code (no auth)

Changed on

Polls a device login: pending until the user approves, then returns the CLI session credential exactly once; denied or expired codes say so. RFC 8628-style polling: while the code is pending, answers 400 authorization_pending; faster than the returned interval, 429 slow_down; denied, 403 access_denied; expired or unknown, 410 expired_token. On the first poll after approval, mints and returns the one-time CLI session credential; every poll after that (the code was already collected) also answers expired_token, so the token is delivered to exactly one caller.

Requires no authentication.

post/v1/cli-auth/token

Request

  • Base URL
    https://api.openrelay.inc
  • URL
    https://api.openrelay.inc/v1/cli-auth/token
  • Auth
    none required

Request body

deviceCodestring required

Response

Approved; here is the session

emailstring required
expiresAtstring date-time required
orgIdstring required
orgNamestring
sessionIdstring required

This session's id: what orl auth logout revokes with DELETE /v1/me/cli-sessions/{id}.

tokenstring required

Bearer credential, prefix ocs_; shown once.

tokenTypestring required

Always Bearer.

userIdstring required

Changes

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      endpoint added