TransferMoney
Transfers funds between clients' shared accounts.
This method is only available to advertising agencies.
There is a slight delay before transferring funds, usually no more than five minutes.
Restrictions
Funds can be transferred from one client's shared account to another client's shared account, provided they both use the same currency.
Only one transfer can be made in a single call of the action.
No more than 3 transfers per day can be made for a single account.
Input data
The input data structure in JSON is shown below.
Alert
It is mandatory to include the finance_token
and operation_num
parameters in the request. For information on generating the token, see the section Working with the shared account.
{
"method": "AccountManagement",
"finance_token": (string),
"operation_num": (int),
"param": {
/* AccountManagementRequest */
"Action": (string),
"Transfers": [
{ /* Transfer */
"FromAccountID": (int),
"ToAccountID": (int),
"Amount": (float),
"Currency": (string)
}
...
]
}
}
Parameters are described below.
Parameter |
Description |
Required |
AccountManagementRequest object |
||
|
Action: TransferMoney. |
Yes |
|
Array containing a single |
Yes |
Transfer object |
||
|
ID of the shared account that funds are being deducted from. |
Yes |
|
ID of the shared account that funds are being deposited to. |
Yes |
|
The transfer amount (in the currency specified in the Before deducting or crediting the amount, it is mathematically rounded to the second decimal point (for all currencies, including the tenge). Use the Get operation to find out the amount available for transfer. |
Yes |
|
The currency that the amount is shown in. Acceptable values: RUB, CHF, EUR, KZT, TRY, UAH, USD, BYN. The value must match the currency of the shared account; otherwise, an error is returned with code 245. |
Yes |
Output data
The output data structure in JSON is shown below.
{
"data": {
/* AccountManagementResponse */
"ActionsResult": [
{ /* AccountActionResult */
"AccountID": (int)
"Errors": [
{ /* Error */
"FaultCode": (int),
"FaultString": (string),
"FaultDetail": (string)
}
...
]
}
...
]
}
}
Parameters are described below.
Parameter |
Description |
AccountManagementResponse object |
|
|
Array of
The items in the array are in the same order as the objects in the |
AccountActionResult object |
|
|
ID of the shared account that funds were deducted from. |
|
Array of |
Error object |
|
|
Error code. |
|
Textual message about the error. |
|
Detailed description of the reason for the error. |
Examples of input data
Python
{
'Action': 'TransferMoney',
'Transfers': [
{
'FromAccountID': 1327837,
'ToAccountID': 1327944,
'Amount': 25000.0,
'Currency': 'RUB'
}
]
}
PHP
array(
'Action' => 'TransferMoney',
'Transfers' => array(
array(
'FromAccountID' => 1327837,
'ToAccountID' => 1327944,
'Amount' => 25000.0,
'Currency' ='RUB'
)
)
)
Perl
{
'Action' => 'TransferMoney',
'Transfers' => [
{
'FromAccountID' => 1327837,
'ToAccountID' => 1327944,
'Amount' => 25000.0,
'Currency' ='RUB'
}
]
}