Installment cards
Installment cards
Processing payments with "Priorbank" OJSC and MTBank CJSC installment cards
To process payments using "Priorbank" JSC or MTBank CJSC (Halva) installment cards, you need to generate a JSON API request or a standard authorization request (HTML form).
Goods paid for with "Priorbank" JSC or MTBank CJSC (Halva) installment cards fall under a specific installment type. A service provider may have several installment types (1 month, 3 months, etc.). Each installment type corresponds to a terminal number registered with "Priorbank" JSC or MTBank CJSC (Halva) for the service provider. Specifying which installment type to use for a given order is handled on the service provider's side. Suppose there are two active installment types:
| Installment type | Terminal number |
|---|---|
| 1 month | 90000001 |
| 3 months | 80000003 |
To specify the installment type in the authorization request, you must additionally pass the wsb_terminal parameter, which should contain the terminal number corresponding to the installment type. This value is provided to the Merchant by the acquiring bank when the contract is signed. The example below shows a request for an order with a 3-month installment type.
This parameter must participate in the formation of the order signature. Thus, when specifying the installment type in the authorization request, the order signature calculation algorithm changes. The electronic signature wsb_signature must be formed according to the following rule from the values of the following fields:
wsb_seedwsb_storeidwsb_order_numwsb_testwsb_currency_idwsb_totalwsb_terminalSecretKey
The fields must be combined into a single string, and the concatenation order must not be violated. Then, depending on the specified protocol version (wsb_version), the MD5 (if the version is not specified) or SHA1 (for version 2) of the combined string is calculated.
Features of working with "Priorbank" JSC installment cards
When sending a request, a payment scenario will be initiated where only "Priorbank" JSC installment cards are allowed for payment. When working with only one installment type, the wsb_terminal field can be omitted.
Features of working with MTBank CJSC (Halva) installment cards
When sending a request, a payment scenario will be initiated where only MTBank CJSC (Halva or X-card linked to a Halva installment card) installment cards are allowed for payment. When working with only one installment type, the wsb_terminal field can be omitted. The WEBPAY system will identify the card entered by the payer, and based on it, the payment will be processed through the corresponding terminal.
If the client has the capability to accept payments via MTBank CJSC (Halva) installment cards enabled, a page with a payment information block will be displayed.

When the payer enters a bank card corresponding to the MTBank CJSC X-card product, after clicking the "Pay" button, the payer will be offered a choice of payment methods from the cards linked to this product.

<form action="https://securesandbox.webpay.by/" method="post">
<input type="hidden" name="*scart">
<input type="hidden" name="wsb_version" value="2">
<input type="hidden" name="wsb_language_id" value="russian">
<input type="hidden" name="wsb_storeid" value="11111111">
<input type="hidden" name="wsb_store" value="Your Store Name">
<input type="hidden" name="wsb_order_num" value="ORDER-12345678">
<input type="hidden" name="wsb_test" value="0">
<input type="hidden" name="wsb_currency_id" value="BYN">
<input type="hidden" name="wsb_seed" value="1242649174">
<input type="hidden" name="wsb_return_url" value="http://yoursiteurl.com/success.php">
<input type="hidden" name="wsb_cancel_return_url" value="http://yoursiteurl.com/cancel.php">
<input type="hidden" name="wsb_notify_url" value="http://yoursiteurl.com/notify.php">
<input type="hidden" name="wsb_invoice_item_name[0]" value="Product 1">
<input type="hidden" name="wsb_invoice_item_quantity[0]" value="2">
<input type="hidden" name="wsb_invoice_item_price[0]" value="10">
<input type="hidden" name="wsb_invoice_item_name[1]" value="Product 2">
<input type="hidden" name="wsb_invoice_item_quantity[1]" value="1">
<input type="hidden" name="wsb_invoice_item_price[1]" value="0.5">
<input type="hidden" name="wsb_total" value="20.90">
<!-- SecretKey value in the example is 1 -->
<input type="hidden" name="wsb_signature" value="950f99293b3aa0d26ab11f69af7f4ba5441e42b5">
<input type="hidden" name="wsb_shipping_name" value="Shipping Cost">
<input type="hidden" name="wsb_shipping_price" value="0.98">
<input type="hidden" name="wsb_discount_name" value="Product Discount">
<input type="hidden" name="wsb_discount_price" value="0.58">
<input type="hidden" name="wsb_terminal" value="80000003">
<input type="submit" value="Buy">
</form>Payments with Halva Plus card
To process payments with a Halva Plus card, it is sufficient to generate a standard authorization request. When entering a Halva Plus card on the payment page and having permission to pay with accumulated bonus points, the buyer will see a separate page with a payment type selection. On this page, they can choose how to pay for the order.

If permission to pay with accumulated bonus points is not available, the page with payment method selection will not be shown, and a regular payment in BYN with the Halva Plus card will occur automatically.