Skip to content

Logging in and receiving an authentication session key

Method login.user
Description Logging in and receiving an authentication session key
Who has access Partner, Customer

Request parameters

Name Type Required Description
login string yes User login
password string yes User password

Response parameters

Name Type Required Description
access_token string yes Authentication session key
expire_at number yes Timestamp after which the token is no longer valid
app_id number yes Customer unique ID

The lifetime of an authentication session key after calling login.user is 1 hour. After that, you need to request a new authentication session key — that is, call login.user again.

To make a request to the API, you can also use a permanent authentication key, available in your client area at the user level.

Example request

{
    "jsonrpc": "2.0",
    "id": "number",
    "method": "login.user",
    "params": {
        "login": "string",
        "password": "string"
    }
}

Example response

{
    "jsonrpc": "2.0",
    "id": "number",
    "result": {
        "data": {
            "access_token": "string",
            "expire_at": "number",
            "app_id": "number"
        }
    }
}

List of returned errors

See the section "List of errors common to all methods".