YooMoney API
Old versions of the API
Help
Sign up for YooMoney
Form for HTTP notifications

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

Payment form parameters
Address for form submission
https://yoomoney.ru/eshop.xml
Parameters
ParameterTypeDescription
Required parameters
shopIdlongThe merchant ID issued when activating YooMoney.
scidlongID of the payment form, issued during activation of YooMoney.
sumCurrencyAmountOrder amount.
customerNumber
normalizedString, 128 characters
Customer ID used by merchant. The ID can be the customer’s contract number, username, or other.
More than one payment can be made using the same customer ID.
Allowed characters:
  • numbers from 0 to 9,
  • latin letters,
  • Russian letters,
  • symbols ~!@#$%^&<em>()_+{}|:"<>?-=[];./!"№;%:?</em>()_+/
  • spaces (spaces are not allowed at the beginning and end).
Optional parameters
orderNumber
normalizedString,
64 characters
Unique order number in the merchant’s system. YooMoney ensures that this number is unique in conjunction with the shopId parameter.
If a payment with the same order number was already successfully processed or there was an error during the payment process, YooMoney will decline any repeated attempts at this payment.
shopArticleIdlongProduct ID. Issued when activating YooMoney. Used if the store has multiple payment forms for various products.
shopSuccessURL
string, URL path,
250 characters
The URL for the Back to store link on the successful payment page. Depending on the store’s settings:
  • set in your personal dashboard (see the successURL option in the Settings section),
  • passed dynamically.
shopFailURL
string, URL path,
250 characters
The URL for the Back to store link on the payment error page.
Depending on the store’s settings:
  • set in your personal dashboard (see the failURL option in the Settings section),
  • passed dynamically.
shopDefaultUrl
string, URL path,
250 characters
The URL for the Back to store link when the YooMoney part of the payment process has concluded, but the user still has additional steps to complete in order to finish the payment.
Pages that show this link:
If this parameter is set, the same URL is used for the Back to store link on the payment confirmation page.
If shopDefaultUrl isn’t set, this link points to the Site address from settings.
cps_email
string,
100 characters
Payer’s email address. If passed, the corresponding box on the payment confirmation page will be pre-filled (step 3 in the payment process).
You can transmit only email address (we check it).

This parameter isn’t passed in checkOrder and paymentAviso requests.

cps_phonestring,
15 characters, digits only
Payer’s mobile phone number. If passed, the corresponding box on the payment confirmation page will be pre-filled (step 3 in the payment process).

This parameter isn’t passed in checkOrder and paymentAviso requests.

paymentType
normalizedString,
5 characters
Payment method. We recommend passing an empty value in this field so that the payment method will be selected in YooMoney.
Examples:
  • PC — payment from a YooMoney for Shopping wallet;
  • AC — payment from any bank card or via Mir Pay (for mobile devices on Android).

If the payment form specifies a payment method that the merchant doesn’t allow, the customer can’t complete the payment.

ym_merchant_receipt
string
Details for creating a receipt in the JSON format.
The parameter is transmitted and presents as mandatory if you set up interaction with your online sales register via YooMoney and transmits the details for creating the receipt in the payment form.

You don’t need to transmit the data for creating a receipt for B2B payments (paymentType=2S).

topped_up_phonestring,
max 15 characters, digits only

For those who add money to phone balance (MCC 4814) only

The phone number to be topped up. Example: 79110000000.
Required parameter when you process payments made from bank card (paymentType="AC"), via YooMoney wallet (paymentType="PC"), or if a payment method was selected on the YooMoney's side (paymentType="").
Additional parameters for B2B payments (paymentType=2S)
payment_purposestring,
210 characters
Payment purpose. Required parameter.
vatType
string
Type of VAT. Possible values:
  • calculated — taxable, all products have the same rate;
  • untaxed — non-taxable;
  • mixed — products in the payment are taxed differently.
vatRate
string
VAT rate. Required if vatType=calculated.
Possible values:
  • 0 — 0% VAT rate;
  • 7 — 7% VAT rate;
  • 10 — 10% VAT rate;
  • 18 — 18% VAT rate;
  • 20 — 20% VAT rate.
vatSumCurrencyAmountAmount of VAT. Required if vatType=calculated or vatType=mixed. You need to calculate the exact amount of VAT independently, then indicate it in the payment request. Also indicate the full amount to be paid by customer, including VAT, in the sum field.
Parameters that the merchant can add (optional)
custom_fieldstringIt is used for transmitting additional parameters.
Any names other than those listed above
string,
4096 characters (total length of all parameters)
Parameters that the merchant adds to the payment form are saved and passed to the merchant in checkOrder and paymentAviso requests.
Requirements for parameter names:
  • The names of added parameters can contain uppercase or lowercase Latin letters, numbers, the underscore, and the dash. Spaces, dots, and square brackets [] are not allowed.
  • The name must start with a letter, but it can’t begin with the combination xml.
Examples
Example of the payment form
HTML
<form action="https://yoomoney.ru/eshop.xml" method="post">
    <input name="shopId" value="1234" type="hidden"/>
    <input name="scid" value="4321" type="hidden"/>
    <input name="sum" value="100.50" type="hidden"/>
    <input name="customerNumber" value="abc000" type="hidden"/>
    <input name="paymentType" value="AC" type="hidden"/>
    <input name="orderNumber" value="abc1111111" type="hidden"/>
    <input name="cps_phone" value="79110000000" type="hidden"/>
    <input name="cps_email" value="user@domain.com" type="hidden"/>
    <input type="submit" value="Pay"/>
</form>
Example of a payment form with parameters for B2B payments
HTML
<form action="https://yoomoney.ru/eshop.xml" method="post">
    <input name="shopId" value="1234" type="hidden"/>
    <input name="scid" value="4321" type="hidden"/>
    <input name="sum" value="50.00" type="hidden" />
    <input name="customerNumber" value="abc000" type="hidden"/>
    <input name="paymentType" value="2S" type="hidden"/>
    <input name="orderNumber" value="abc1111111" type="hidden"/>
    <input name="cps_phone" value="79110000000" type="hidden"/>
    <input name="cps_email" value="user@domain.com" type="hidden"/>
    <input name="payment_purpose" value="Payment for order No. 2134О" type="hidden"/>
    <input name="vatType" value="calculated" type="hidden"/>
    <input name="vatRate" value="18" type="hidden"/>
    <input name="vatSum" value="9.00" type="hidden"/>
    <input type="submit" value="Pay"/>
</form>
Example of the payment form for adding money to phone balance
HTML
<form action="https://yoomoney.ru/eshop.xml" method="post">
    <input name="shopId" value="1234" type="hidden"/>
    <input name="scid" value="4321" type="hidden"/>
    <input name="sum" value="100.50" type="hidden"/>
    <input name="customerNumber" value="abc000" type="hidden"/>
    <input name="paymentType" value="AC" type="hidden"/>
    <input name="orderNumber" value="abc1111111" type="hidden"/>
    <input name="cps_phone" value="79110000000" type="hidden"/>
    <input name="cps_email" value="user@domain.com" type="hidden"/>
    <input required name="topped_up_phone" value="79000000000" type="hidden">
    <input type="submit" value="Pay"/>
</form>
See also
Test payment