CreateNewSubclient

Registers a client of an advertising agency in Yandex and creates an account in Yandex Direct.

Attention.

Disabled method. Use version 5 of the API.

For information about the compatibility of methods between versions 4 and 5, see the Migration guide.

This method is available only to advertising agencies, not to direct advertisers. For agencies, access is provided on request.

Attention.

As of October 10, 2016, advertising agencies can only register clients who are using a real currency. Registration of clients who use Yandex units has been disabled. Accordingly, the logic of the method has changed.

If the agency has a single currency available, the client is created in the agency's currency.

If the agency has multiple currencies available, the method returns an error. In this case, a client can be registered only by using the CreateNewSubclient (Live) method or in the web interface.

Available currencies are shown in the ClientCurrencies output parameter for the GetClientInfo (Live) method.

The CreateNewSubclient (Live) version also exists for this method.

Restrictions

No more than 100 clients can be registered per day.

Input data

The input data structure in JSON is shown below.

{
   "method": "CreateNewSubclient",
   "param": {
      /* CreateNewSubclientRequest */
      "Login": (string),
      "Name": (string),
      "Surname": (string)
   }
}

Parameters are described below.

Parameter Description Required
CreateNewSubclientRequest object
Login

Client's username (unique within Yandex).

The user's Yandex account is created for this username. If the username is not unique, the error message 252 is returned.

Yes
Name Client's name, no more than 20 characters. The following characters are not allowed: &=<>. Yes
Surname Client's last name, no more than 20 characters. The following characters are not allowed: &=<>. Yes
Parameter Description Required
CreateNewSubclientRequest object
Login

Client's username (unique within Yandex).

The user's Yandex account is created for this username. If the username is not unique, the error message 252 is returned.

Yes
Name Client's name, no more than 20 characters. The following characters are not allowed: &=<>. Yes
Surname Client's last name, no more than 20 characters. The following characters are not allowed: &=<>. Yes

Output data

The output data structure in JSON is shown below.

{
   "data": {
      /* CreateNewSubclientResponse */
      "Login": (string),
      "Password": (string),
      "FIO": (string),
      "Email": (string),
      "ClientID": (int)
   }
}

Parameters are described below.

Parameter Description
CreateNewSubclientResponse object
Login

The Yandex username.

Password

Automatically generated password.

The client can use this password and username to log in on Yandex.

FIO

Last name and initials.

Email

The email address to send notifications and news to.

ClientID Client ID.
Parameter Description
CreateNewSubclientResponse object
Login

The Yandex username.

Password

Automatically generated password.

The client can use this password and username to log in on Yandex.

FIO

Last name and initials.

Email

The email address to send notifications and news to.

ClientID Client ID.

Examples of input data

Python

{
   'Login': 'agrom',
   'Name': 'Alexander',
   'Surname': 'Gromov'
}

PHP

array(
   'Login' => 'agrom',
 'Name' => 'Alexander',
 'Surname' => 'Gromov'
)

Perl

{
 'Login' => 'agrom',
 'Name' => 'Alexander',
 'Surname' => 'Gromov'
}