YooMoney API
Old versions of the API
Help
Sign up for YooMoney
Testing payouts

This is an old version of the API. Switch to the YooMoney API.

Before sending requests containing real data, you can check your integration and test payouts to wallets and bank cards, as well as the requests for payout account balance. The testing process is identical to the actual payout process, except the money is not transferred anywhere. Протестировать можно только выплаты физическим лицам.
Testing preparations
Step 1. Obtain the required certificates
Obtain the required certificates for interacting with YooMoney.
Step 2. Create a test gateway
The test gateway is similar to a real one. The main differences are that its only used for test payouts and you don’t need to add money to its payout balance.
You can create a test gateway either before or after signing up for YooMoney.
If you haven’t signed up for YooMoney
  1. Sign up using this link.
  2. In the process, you’ll see two options: continue sign-up or proceed to testing payments. Select testing payments. You’ll see the created demo Merchant Profile.
  3. Click on the block with the name of the store (or the store icon in the mobile version).
    Block with the name of the store (on desktop)
    Block with the name of the store (on mobile)
  4. Click Add a test gateway in the opened list. You will see the window for creating a test gateway.
    Window for creating a test gateway
  5. When creating a test gateway, specify that you’ll be using the old API, enter the necessary data, and click Add. The newly created test gateway will be displayed within a minute.
If you have a YooMoney Merchant Profile
  1. Click on the block with the name of the gateway (or the wallet icon in the mobile version).
    Block with the name of the gateway (on desktop)
    Block with the wallet icon (on mobile)
  2. Click Add a test gateway in the opened list. You will see the window for creating a test gateway.
    Window for creating a test gateway
  3. When creating a test gateway, specify that you’ll be using the old API, enter the necessary data, and click Add. The newly created test gateway will be displayed within a minute.

You can create up to 5 test gateways.

Step 3. Get the ID of the test gateway (agentId)
Find the agentId if the test gateway in the Merchant Profile. It must be used in all test requests to YooMoney.

Test and real gateways have different agentId. You can’t use the agentId of the real gateway for testing: YooMoney will return error code 41.

Step 4. Wait for the email from the YooMoney manager
The YooMoney manager will send you an email notifying that everything is properly configured and you can start testing.
Testing
When everything is ready, you can test:
When sending requests, use special testing data.
URL of the server for sending requests
https://payouts.yookassa.ru:9094
After verification, get your system ready for making real payouts.
Test payouts to wallets
Step 1. Transfer the money (makeDeposition)
Transfer the money to the wallet by sending the makeDeposition request with the agentId of the test gateway, payout amount (1 ruble or more) and dstAccount with one of the following numbers of test wallets:
  • anonymous wallet — 41001614575714;
  • reviewed wallet — 4100116075156746;
  • identified wallet — 4100116074720387.
Request example
XML
<makeDepositionRequest
              agentId="123"
              clientOrderId="12345"
              requestDT="2019-07-01T20:38:00.000Z"
              dstAccount="41001614575714"
              amount="10.00"
              currency="643"
              contract="Test payout"
              />
Example of the response
XML
<makeDepositionResponse
              clientOrderId="12345"
              status="0"
              processedDT="2019-07-01T20:38:01.000Z"
              balance="-19270338.94"
              identification="identified"
              />

A random negative number returns in the balance parameter.

Step 2. Check the idempotency of requests
Send the makeDeposition request with the same data used in step 2. The result of processing the request sent in step 1 returns in response.
Step 3. Check the payout error processing
You can check the processing of the payout errors to wallets by selecting the desired scenario and sending the makeDeposition request with the special number of the test wallet and a certain payout amount.
Payout error descriptionTest wallet number (dstAccount)Payout amount
41
YooMoney for Shopping wallet blocked. This operation is not allowed for this wallet.
410011788545536
1 ruble or more
42
There is no account with this ID
410011806060695
1 ruble or more
43
Exceeded the limit on a one-time transfer, or the limit on the recipient’s account balance
41001614575572
1 ruble or more
44
Exceeded the limit on the maximum amount of deposits per day
41001614575643
1 ruble or more
45
Not enough funds to perform the operation
410011806060766
1 ruble or more
46
The transaction amount is too small
41001614575714
Less than 1 ruble
57
This YooMoney wallet is not identified. Adding money to anonymous wallets is forbidden. The user needs to complete identification.
4100116103609421
1 ruble or more
Testing payouts to cards
ID of the transfer recipient (dstAccount): 25700120202056919
Если делаете обычные выплаты, не c расчетного счета, для проверки выплат на банковские карты в paymentParams необходимо передавать тестовые персональные данные получателя выплаты:
  • фамилия получателя — Иванов
  • имя получателя — Иван
  • отчество получателя — Иванович
  • номер паспорта — 1234567890
  • All other parameters — Any valid values
Step 1. Transfer the money (makeDeposition)
For depositing money to card:
  1. Get a bank card synonym independently or using the YooMoney form. Any bank card’s data is suitable.
  2. Send a makeDeposition request with the received synonym, agentId of the test gateway, test ID of the transfer recipient (dstAccount), and the amount of 100 rubles. Если делаете обычные выплаты, то также передайте тестовые персональные данные получателя выплаты (Иванов Иван Иванович, 1234567890).
Пример запроса для обычных выплат
XML
<makeDepositionRequest
    agentId="123"
    clientOrderId="12345"
    requestDT="2019-06-07T15:43:29.000Z"
    dstAccount="25700120202056919"
    amount="249.00"
    currency="643"
    contract="">
    <paymentParams>
    <skr_destinationCardSynonim>sRKjOLa32DBbBa-Oej5r9BvA.SC.000.201906</skr_destinationCardSynonim>
        <pdr_firstName>Иван</pdr_firstName>
        <pdr_middleName>Иванович</pdr_middleName>
        <pdr_lastName>Иванов</pdr_lastName>
        <pdr_docNumber>1234567890</pdr_docNumber>
        <pdr_postcode>194044</pdr_postcode>
        <pdr_country>643</pdr_country>
        <pdr_city>Санкт-Петербург</pdr_city>
        <pdr_address>3-я улица Строителей, д. 25</pdr_address>
        <pdr_birthDate>01.01.1940</pdr_birthDate>
        <pdr_birthPlace>гор.Ленинград</pdr_birthPlace>
        <pdr_docIssueYear>1999</pdr_docIssueYear>
        <pdr_docIssueMonth>07</pdr_docIssueMonth>
        <pdr_docIssueDay>30</pdr_docIssueDay>
        <pdr_docIssuedBy>ТП №20 по СПб и ЛО</pdr_docIssuedBy>
        <pof_offerAccepted>1</pof_offerAccepted>
        <smsPhoneNumber>79000000000</smsPhoneNumber>
    </paymentParams>
</makeDepositionRequest>
Example of the response
XML
<makeDepositionResponse
    clientOrderId="12345"
    status="0"
    processedDT="2019-06-07T15:43:31.606+03:00"
    balance="-100000"
    invoiceId="2000028645828"
/>

A random negative number returns in the balance parameter.

Step 2. Check the idempotency of requests
Send the makeDeposition request with the same data used in step 1. The result of processing the request sent in step 1 returns in response.
Step 3. Check the payout error processing
You can check the processing of the payout errors to cards by selecting the desired scenario and sending the makeDeposition request with the special test data.
Payout error descriptionBank card synonymPersonal detailsPayout amount
31
The transfer recipient declined the payout (the recipient refers to the mobile carrier or processing bank)
BFtJqriXvLaIOr0BDLdcjwgC.SC.000.201904
Иванов Иван Иванович, 1234567890
100 rubles or more
46
The transaction amount is too small
You can use any synonym, except for those specified in this table.
Иванов Иван Иванович, 1234567890
Less than 100 rubles
48
Error in the request for funds deposit to a bank account, card, or mobile phone
HW0xgquwIm-h4H9bfpiIRF3u.SC.000.201904
Иванов Иван Иванович, 1234567890
100 рублей или больше
48
Error in the request for funds deposition to a bank account, card, or mobile phone balance (techMessage= «Паспортные данные не прошли проверку")
You can use any synonym, except for those specified in this table.
Any data except test data
100 rubles or more
Checking the balance of payouts (balance)
To check the balance of the test gateway payouts, send the balance request with the agentId of the test gateway.
Request example
XML
<balanceRequest
    agentId="123"
    clientOrderId="12345"
    requestDT="2019-07-01T20:38:00.000Z"
/>
Example of the response
XML
<balanceResponse
    clientOrderId="12345"
    status="0"
    processedDT="2019-07-01T20:38:01.000Z"
    balance="-19270338.94"
/>

A random negative number returns in the balance parameter.

Real payouts
Consult with your manager to make sure everything is ready for launch. After that, send requests with the ID of the real gateway (agentId) and real data.

The test and real gateways have different agentId. You can’t use the agentId of the test gateway for real payouts: YooMoney will return the 41 error code.

See also
Payouts from a business account Activating payouts Funds deposit Data types Error codes