Payments via bank card
You can accept payments by Visa, Mastercard, or Mir cards.
Card payment scenario
- Create a payment session that is separate from the actual payment (
session/create
) or a single combined session (session/init/payment
). At this point, you can connect the payment form widget or tokenize the bank card to accept payments without the widget. - If you are not using the widget and have created the session separately from the start of the payment, then send a
session/start/payment
request. - Bank 131 will send you a
ready_to_confirm
webhook, which means that the Bank is ready to make the payment and is waiting for your confirmation. - Confirm (
session/confirm
) or cancel (session/cancel
) the payment. - Bank 131 will send you an
action_required
webhook in case additional actions are required for the payment, e. g. 3D Secure verification. Redirect the user to the address for 3D Secure.If you are using our widget and receive an
action_required
webhook, just send the 200 HTTP code in response, while the customer will be redirected by us. - Get a
ready_to_capture
webhook from Bank 131, then capture the funds (session/capture
) or decline the payment (session/cancel
). - Bank 131 will send you a
payment_finished
webhook containing the result of the payment. If the status issucceeded
, this tells you that the payment was successful.
Card payment diagram
This diagram shows the card payment stages for a session created separately from the start of the payment.
Tokenize card without widget
Bank 131 can store tokenized data for Russian cards on the Bank's side. This may be convenient in case your PCI DSS level is insufficient to store card data or if you decide not to use the tokenization widget for some reason. You can pass tokenized data to Bank 131 after the first payout transaction and use it for further payouts.
You can also reuse the card data received during a payment transaction to make payouts to the same card later. This works both for hashed acquiring data and tokens.
To tokenize card data without the widget, use the tokenize/elements
method. Use the token returned by the method in further payment or payout requests.
All data tokenized in this way is not project dependent (e.g., a payout project token can be used to accept payments in another project, etc.)