confirmPayment method
This is an old version of the API. Switch to the YooMoney API.
Description
Complete a successful transfer to the merchant’s account. Used for deferred payments.
In order to complete confirmation requests (
confirmPayment
) and cancel deferred payments (cancelPayment
), you must register a separate store. For more information, contact your YooMoney manager.Specifics
- If a store has deferred payments set up in YooMoney, all payments to this store will be deferred. This means they are performed in two steps: first money is reserved on the payer’s bank card, then it is debited from the card.
- The amount specified in the request to confirm a deferred payment may be less than the reserved amount. In this case, the amount remaining is automatically refunded to the Payer’s bank card.
- If the confirmation period has expired for a deferred payment, the response will contain an error, even if the request parameters are correct. The confirmation period is defined by the bank that is processing the operation. Each bank sets this time individually.
Request
Address for calling the operation
https://shop.yookassa.ru/webservice/mws/api/confirmPayment
Request parameters
Parameter | Type | Description |
---|---|---|
requestDT | dateTime | Time in the merchant’s system when the request to perform the operation was made. |
orderId | long | Transaction number of the deferred payment, issued by YooMoney in the invoiceId parameter. |
amount | CurrencyAmount | Amount to transfer. |
currency | string, 3 characters | 3-letter currency code for the transfer. Specified in accordance with ISO 4217:2008. |
ym_merchant_receipt | string | Data for creating the receipt in the JSON format (as in payment form). The parameter is transmitted and deemed mandatory in the following cases:
|
Request example
requestDT=2011-07-02T20:38:00.000Z&orderId=12345&amount=10.00¤cy=RUB
Response
The response contains parameters that are shared for all types of financial transaction request.
Example of the response
XML
<confirmPaymentResponse orderId="12345" status="0" error="0" processedDT="2011-07-02T20:38:01.000Z" />
See also