Documentation for version v73
Add a new account
Description
Create a new platform account
Request URL
Method: POST
https://example.com/api/v1.1/admin/accounts/save
Request parameters
| Parameter | Type | Example | Required | Description |
|---|---|---|---|---|
| token | string | "abcdefghijklmnqrstuvwxyz" | Yes | API token |
| format | string | "json" | No | Response data format (By default – json) |
| id | int | 1 | No | Account ID |
| name | string | "Account name" | Yes | Account name |
| title | string | "example title" | Yes | Account title |
| tz | string | "UTC" | Yes | Account time zone |
| tariff | int/string | "example tariff" | Yes | Tariff ID or name |
| web_version_policy | int/string | "0" | No | Web version policy ID or name |
| account_postgresql | int/string | "2" | No | Postgresql account ID or name |
| account_cache_clickhouse | int/string | "3" | No | Clickhouse account ID or name |
| external_data_connectors | int | [1,2,3,4] | No | External data connectors |
| reports_day | int | 4 | Yes | Day of the report |
| reports_hour | int | 18 | Yes | Time of the report |
| force_2fa_auth | bool | false | No | Requirement of mandatory use of two-factor authentication |
| enable_push | bool | true | No | Enabling Push Notifications |
| custom_push_domain | string | "example.com" | No | Domain of custom push notifications |
| enable_smart_settings | bool | true | No | Access to smart settings |
| enable_pixel | bool | true | No | Enabling a pixel |
| enable_track_email_replies | bool | false | No | Tracking email replies |
Request example
- JSON
- XML
{
"token": "aabcdefghijklmnqrstuvwxyz",
"name": "Steve",
"title": "ASdf",
"tz": "UTC",
"tariff": "example tariff",
"reports_day": 5,
"reports_hour": 22
}
<xml>
<token>abcdefghijklmnqrstuvwxyz</token>
<name>Steve</name>
<title>ASdf</title>
<tz>UTC</tz>
<tariff>example tariff</tariff>
<reports_day>5</reports_day>
<reports_hour>22</reports_hour>
</xml>
Response example
- JSON
- XML
{
"data": {
"saved_id": 6
},
"error": 0,
"error_text": "Successful operation"
}
<xml>
<data>
<saved_id>6</saved_id>
</data>
<error>0</error>
<error_text>Successful operation</error_text>
</xml>
Response parameters
| Parameter | Type | Description |
|---|---|---|
| error | int | Error code |
| error_text | string | Error text |
| saved_id | int | Account ID |