Skip to content

Authorization

Description

To be authorized you need to have access to a portal by email and password cdn.beeline.ru. Authorization is provided by OAuth protocol, you will need to forward your email and password in a request.

To get a token, you have to make a POST-request to https://api.cdn.beeline.ru/app/oauth/v1/token/

Warning!

  1. There is a limit on the number of API calls:
    • no more than 20 requests per minute;
    • if you send an incorrect password 7 times, the account will be banned for 3 hours.

Attention

The token is valid for 6 hours.

Response Codes and Their Meanings

Status Code Response Data Response Format Description
200 auth_token: token for api usage, type: string; person_id: internal user identificator, type: integer; status: operation status, type: integer; lifetime: time until the token is expired in milliseconds, type: integer JSON successful authentication
400 None None Bad Request
401 None None wrong login/password
403 None None Forbidden
500 None None Internal Server Error
503 None None Service Unavailable

Request example

Response example

curl "https://api.cdn.beeline.ru/app/oauth/v1/token/" --data-urlencode 'username=example@test.com' --data-urlencode 'password=1'

Successful response example

{
  "person_id": 17,
  "status": 200,
  "token": "cdn1_ZH67NHKOFUJ7AMXS6Q6FGMEUMB0VB2",
  "lifetime": 21599000
}