Skip to main content
POST
/
api
/
auth
/
device
/
code
Request device + user code
curl --request POST \
  --url https://app.photon.codes/api/auth/device/code \
  --header 'Content-Type: application/json' \
  --data '
{
  "client_id": "<string>",
  "scope": "<string>"
}
'
{
  "device_code": "<string>",
  "user_code": "<string>",
  "verification_uri": "<string>",
  "verification_uri_complete": "<string>",
  "expires_in": 123,
  "interval": 123
}

Body

application/json
client_id
string
required

Public client id of the application requesting authorization.

scope
string

Optional space-separated list of scopes.

Response

Device authorization started.

device_code
string
user_code
string
verification_uri
string<uri>
verification_uri_complete
string<uri>
expires_in
integer

Device code lifetime in seconds.

interval
integer

Minimum polling interval in seconds.