Skip to content

POST /auth/requestcode ​

This endpoint is used to get an authorization code which can be exchanged for an authorization token to the companion server.

Request ​

FieldTypeRequirementsSince Version
appIdstringlowercase alphanumeric, 2-32 characters2.0.0
appNamestring2-32 characters2.0.0
appVersionstringsemver compliant2.0.0

Example ​

json
{
  "appId": "my-example-companion",
  "appName": "Example YTMDesktop Companion",
  "appVersion": "0.0.1-dev"
}

Response ​

FieldTypeSince Version
codestring2.0.0

Example ​

json
{
  "code": "1337"
}