Sessions flow Component
Before-You-Begin
Requirements
Add-Parameters-Sessions-Request
Add additional parameters to your /sessions request
When you create a payment session, add the following parameters:
If you leave the
shopperStatement empty, it is populated with the following default Portuguese text:
Import
Import Boleto Bancário
When you import Adyen Web, includeBoleto.
Import
Add-Configuration
Add additional configuration for Boleto Bancário
Configure the Component with the following configuration object: You can add the following optional configuration for collecting the shopper details:- If you already have the required shopper details, you can turn off the form sections where these details are collected.
- You can pre-fill some of the fields. To collect the missing details, turn on the corresponding form sections.
If you want to add optional configuration, include this in a configuration object. The following example shows how to configure the Component to remove the shopper details fields and prefill the form.
Create a configuration object
Initialize
Initialize the Component for Boleto Bancário
To initialize Boleto Bancário, use theBoleto class.
Initialize the Component
Test and go live
Boleto Bancário is an offline payment method. In the test environment, you can simulate a Boleto payment by promoting the pending payment to a sale.- Log in to your test Customer Area.
- Go to Transactions > Offers.
- Select the PSP reference of the pending Boleto payment.
- Select the Promote this offer to a sale button.
- Boletos that are pending or that have expired are under Transactions > Offers.
- Boletos that have been paid (including test offers that you manually promoted to sale) are under Transactions > Payments.
Advanced flow Component
Requirements
Import
Import Boleto Bancário
When you import Adyen Web, includeBoleto.
Import
Initialize
Initialize the Component for Boleto Bancário
To initialize Boleto Bancário, use theBoleto class.
Initialize the Component
Add-Parameters-Payments-Request
Add additional parameters to your /payments request
When you make a payment, add the following parameters to the /payments request:
If you leave the
shopperStatement empty, it is populated with the following default Portuguese text:
The response includes the
action.type: voucher, and the following:
-
pspReference: Our unique reference for the payment. -
resultCode: PresentToShopper -
action: Object containing information about the voucher:downloadUrl: Link to the downloadable Boleto in PDF format.expiresAt: The date and time when the due date expires.paymentMethodType: Indicates the issuing bank.reference: The barcode number for the payment.totalAmount: Thecurrencyandvalueof the amount due.
Test and go live
Boleto Bancário is an offline payment method. In the test environment, you can simulate a Boleto payment by promoting the pending payment to a sale.- Log in to your test Customer Area.
- Go to Transactions > Offers.
- Select the PSP reference of the pending Boleto payment.
- Select the Promote this offer to a sale button.
- Boletos that are pending or that have expired are under Transactions > Offers.
- Boletos that have been paid (including test offers that you manually promoted to sale) are under Transactions > Payments.
