The description (WSDL) of the service is located on the test server, which is available at https://3dsec.sberbank.ru/payment/webservices/merchant-loyalty-ws.
The request used for debiting a pre-authorized order is autoCompletion
.
In this document, the following data type conventions are used when describing request and response parameters:
Request parameters:
Name | Type | Mandatory | Description |
---|---|---|---|
|
ANS36 | Yes |
Identifier of the order in the payment system. It is unique within the system. The identifier is missing if the order registration failed due to an error detailed in errorCode. |
|
N..20 | Yes |
The amount to be debited, consisting of the amount in money and the amount of points. The amount can be equal to or less than the order remaining amount. If zero is passed in this parameter, completion will occur for the entire pre-authorized amount. |
|
A2 | No |
Language in the ISO 639-1 encoding. If the language is not specified, the default language defined in the store settings is used. |
Response parameters:
Name | Type | Mandatory | Description |
---|---|---|---|
|
ANS..3 | No |
Error code. |
|
|
No |
|
|
AN..512 | No |
Loyalty processing transaction identifier. |
|
AN..512 | Yes |
Operation type, the following values are possible:
|
|
AN..512 | No |
The identifier of the transaction in the payment gateway. |
|
N..20 | No | Amount in points. |
|
AN..512 | Yes |
A feature of the success of the operation, the following values are possible:
|
Request example:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:loy="http://engine.paymentgate.ru/webservices/merchant/loyalty"> <soapenv:Header/> <soapenv:Body> <loy:autoCompletion> <autoCompletionRequest orderId="8ebb4b7b-a976-42e4-92b5-cf4ab4c8adf3" compositeCompletionAmount="50"> </autoCompletionRequest> </loy:autoCompletion> </soapenv:Body> </soapenv:Envelope>
Response example:
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <ns1:autoCompletionResponse xmlns:ns1="http://engine.paymentgate.ru/webservices/merchant/loyalty"> <return errorCode="0" errorMessage="Success"> <operations xsi:type="ns3:sbrfSpasiboLoyaltyOperation" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns3="http://engine.paymentgate.ru/webservices/merchant/loyalty"> <amount>4975</amount> <operation>REFUND_PAYMENT</operation> <successful>true</successful> <transactionId>1032269</transactionId> <pcId>27407238</pcId> </operations> <operations xsi:type="ns3:sbrfSpasiboLoyaltyOperation" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns3="http://engine.paymentgate.ru/webservices/merchant/loyalty"> <amount>4975</amount> <operation>REFUND_AWARD</operation> <successful>true</successful> <transactionId>1032270</transactionId> <pcId>27407239</pcId> </operations> </return> </ns1:autoCompletionResponse> </soap:Body> </soap:Envelope>