P2P - OCT (Paritetbank)
P2P - OCT (Paritetbank)
General description
For withdrawing funds on your website, the payer is allowed to use payment cards of MASTERCARD, VISA, BELKART systems issued by any Belarusian bank, as well as cards of the MIR payment system. Cards issued by foreign banks are not available for payouts according to payment system rules.
Payment module development
The WEBPAY system provides two methods for initiating funds withdrawal using the OCT type:
- JSON API.
- Forming a standard POST request.
Forming a standard POST request
To perform an OCT funds withdrawal, you need to form a standard POST request (Order creation for payment) to the address https://securesandbox.webpay.by/payout/ for the sandbox environment or https://payment.webpay.by/payout/ for the production environment, with the following additional fields:
Please Note
When forming a funds withdrawal request:
- The fields
wsb_test,wsb_invoice_item_name,wsb_invoice_item_quantity,wsb_invoice_item_priceare optional; - The field
wsb_return_urlis mandatory.
| Field Name | Mandatory | Description | Notes |
|---|---|---|---|
wsb_payout_type | Yes | Payout type | Field value: octThis transaction type is used to send funds to the recipient's card |
wsb_sender_surname | Yes | Sender — last name | Field length: from 1 to 35 characters |
wsb_sender_first_name | Yes | Sender — first name | Field length: from 1 to 35 characters |
wsb_sender_address | Yes | Sender — address (street, house) | Field length: from 1 to 35 characters |
wsb_recipient_surname | Yes | Recipient — last name | Field length: from 1 to 35 characters |
wsb_recipient_first_name | Yes | Recipient — first name | Field length: from 1 to 35 characters |
The electronic signature wsb_signature for forming a funds withdrawal request must be generated according to the following rule from the values of the following fields:
wsb_seedwsb_storeidwsb_order_numwsb_currency_idwsb_totalSecretKey
The fields must be concatenated into a single string, and the concatenation order must not be violated. Then, depending on the specified protocol version (wsb_version), the MD5 hash (if the version is not specified) or the SHA1 hash (for version 2) of the concatenated string is calculated.
<form action="https://securesandbox.webpay.by/payout" method="post">
<input type="hidden" name="wsb_storeid" value="240869199">
<input type="hidden" name="wsb_order_num" value="ORDER-1234567822223">
<input type="hidden" name="wsb_currency_id" value="BYN">
<input type="hidden" name="wsb_seed" value="dfdasf3i232m13ijdsmcvm">
<input type="hidden" name="wsb_return_url" value="https://yoursiteurl.com/success.php">
<input type="hidden" name="wsb_total" value="1.00">
<!-- The SecretKey value in the example is 1 -->
<input type="hidden" name="wsb_signature" value="12fd269743d3017bf0a0607eb371a042">
<input type="hidden" name="wsb_payout_type" value="oct">
<input type="hidden" name="wsb_sender_surname" value="IVANOU">
<input type="hidden" name="wsb_sender_first_name" value="IVAN">
<input type="hidden" name="wsb_sender_address" value="Shafarnyanskaya 11">
<input type="hidden" name="wsb_recipient_surname" value="PETROV">
<input type="hidden" name="wsb_recipient_first_name" value="PETR">
<input type="submit" value="Pay Out">
</form>