Transfer form
The YooMoney form is a set of fields with information about a transfer. You can embed payment form into your interface (for instance, a website or blog). When the sender pushes the button, the details from the form are sent to YooMoney and an order for a transfer to your wallet is initiated.
The form is sent using the
POST
method.Address for sending requests
https://yoomoney.ru/quickpay/confirm
Parameters
Parameter | Type | Description |
---|---|---|
Required parameters | ||
receiver | string | Number of the YooMoney wallet which money from senders is credited to. |
quickpay-form | string | Form type. Fixed value: button . |
paymentType | string | Payment method. Possible values:
|
sum | CurrencyAmount | Transfer amount (the amount debited from the sender). |
Optional parameters | ||
label | string, up to 64 characters | The label that a site or app assigns to a certain transfer. For instance, a code or order identifier may be used for this label. |
successURL | string, URL path | URL where the user is redirected after the transfer. |
Calculating commission
You can calculate the commission charge (for instance, to show it to the transfer sender) by applying a multiplier using a formula with the following parameters:
amount_due
for the amount to be received;sum
for the amount to be debited;a
for the commission multiplier.
The
amount_due
and a
parameters aren’t passed anywhere: they are only used for calculations. You send the sum
parameter in the form to the YooMoney service.Payment type | Commission multiplier (a) | Where the commission comes from | Formula for calculation | Example |
---|---|---|---|---|
YooMoney walletPC | 0,01 | from the recipient, off the amount to be received | amount_due = sum — sum * (a / (1 + a)) | The sender transfers 1,000 rubles from the wallet. The recipient will get 990 rubles and 9 kopecks. |
Bank cardAC | 0,03 | from the recipient, off the amount to be debited | amount_due = sum * (1 — a) | The sender transfers 1,000 rubles from the card. The recipient will get 970 rubles. |
Sample form
HTML
<form method="POST" action="https://yoomoney.ru/quickpay/confirm"> <input type="hidden" name="receiver" value="41001xxxxxxxxxxxx"/> <input type="hidden" name="label" value="$order_id"/> <input type="hidden" name="quickpay-form" value="button"/> <input type="hidden" name="sum" value="4568.25" data-type="number"/> <label><input type="radio" name="paymentType" value="PC"/>YooMoney</label> <label><input type="radio" name="paymentType" value="AC"/>Bank card</label> <input type="submit" value="Transfer"/> </form>
See also