Provided that a store has corresponding permissions, it can get the list of all bindings that relate to a certain bank card. This can be done by a card number or by a known binding identifier. The method used for getting the list of bindings of a bank card is getBindingsByCardOrId
. The response returns all the bindings available to the merchant in accordance with their settings.
Use the following URL to connect to the Test Service (WSDL):
https://3dsec.sberbank.ru/payment/webservices/merchant-ws?wsdl.
In this document, the following data type conventions are used when describing request and response parameters:
Name | Type | Mandatory | Description |
---|---|---|---|
|
N12…19 | Required if bindingId is not indicated. |
Masked number of the card that has been used for the payment. This parameter is to be specified only after the order has been paid. In the case of payment via Apple Pay, DPAN is used as the card number: a number associated with the buyer's mobile device and acting as a payment card number in the Apple Pay system. |
|
AN..255 | No |
The identifier of the previously created binding. Can only be used if the merchant has permission to work with bindings. If this parameter is passed in the given request, it means that: |
|
boolean | No |
This parameter defines the necessity to display bindings with expired card validity periods. The available values are: true, false. By default the parameter has the false value. |
|
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. |
Name | Type | Mandatory | Description |
---|---|---|---|
|
ANS..3 | Yes |
Error code. |
|
|
Yes |
|
bindings element (contains blocks that consist of the bindingId, maskedPan, expiryDate and clientId parameters): |
|||
|
AN..255 | No |
The identifier of the previously created binding. Can only be used if the merchant has permission to work with bindings. If this parameter is passed in the given request, it means that: |
|
N..19 | No |
Masked number of the card that has been used for the payment. This parameter is to be specified only after the order has been paid. |
|
N6 | No |
Expiry date of the card in the format YYYYMM. This parameter is to be specified only after the order has been paid. |
|
ANS..255 | No |
Identifier of the Customer in the Store system. This parameter is used for the binding functionality. May be present if the store is allowed to create bindings. Specifying this parameter when processing payments with the use of bindings is mandatory. Otherwise, a payment will be unsuccessful. |
Error code | Error text |
---|---|
0 |
The request has been processed without system errors. |
1 |
Search parameters |
2 |
The information is not found. |
5 |
Access denied. |
5 |
The user must change the password. |
7 |
System error. |
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:mer="http://engine.paymentgate.ru/webservices/merchant"> <soapenv:Header/> <soapenv:Body> <mer:getBindingsByCardOrId> <request pan="4111111111111111" bindingId=" " showExpired="true" language="ru"/> </mer:getBindingsByCardOrId> </soapenv:Body> </soapenv:Envelope>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <ns1:getBindingsByCardOrIdResponse xmlns:ns1="http://engine.paymentgate.ru/webservices/merchant"> <return errorCode="0" errorMessage="Success"> <bindings> <binding bindingId="9f43e86d-9744-42a5-8646-c4bb7cf8799a" maskedPan="411111**1111" expiryDate="201912" clientId="12345"/> <binding bindingId="51c0750b-1a23-424b-8989-5e8f669124b4" maskedPan="411111**1111" expiryDate="201512" clientId="123456"/> <binding bindingId="6a8c0738-cc88-4200-acf6-afc264d66cb0" maskedPan="411111**1111" expiryDate="201912" clientId="666"/> <binding bindingId="97a70989-c1fb-49f7-8a42-27c19dc160dw" maskedPan="411111**1111" expiryDate="201512" clientId="666"/> </bindings> </return> </ns1:getBindingsByCardOrIdResponse> </soap:Body> </soap:Envelope>