Boleto Bancario
Accept Boleto Bancário payments in Brazil with Bamboo. Learn how to integrate, request parameters, and test flows for this payment method.
Boleto Bancário is a popular payment method in Brazil that allows for paying bills and online purchases without a credit card. It generates a unique barcode that can be printed or accessed through a digital platform and paid at any bank or authorized payment center.
Redirect Flow for BoletoThis payment method uses a Redirect flow. The API response includes an
Action.URLand the purchase remains in Pending status until the customer completes the payment in a payment office or Internet Banking.
Request parameters
The following parameters are required specifically for this payment method.
Refer to the Purchase operation guide for standard fields and authentication requirements.
| Property | Type | Mandatory? | Description |
|---|---|---|---|
PaymentMethod | string | Yes | BLT - Review the table Payment Method. |
TargetCountryISO | string | Yes | Indicate the destination country. |
Customer → Email | string | Yes | Customer's email. |
Customer → FirstName | string | Yes | Customer's first name. |
Customer → LastName | string | Yes | Customer's last name. |
Customer → DocumentType | string | Yes | Customer's document type. Refer to the Document types table to see the possible values. |
Customer → DocumentNumber | string | Yes | Customer's Document Number. |
Customer → PhoneNumber | string | No | Customer's phone number. |
Customer → Address → Country | string | No | Customer's Country. |
Customer → Address → State | string | Yes | Customer's State. |
Customer → Address → City | string | Yes | Customer's City. |
Customer → Address → AddressDetail | string | No | Customer's Address Detail. |
Customer → Address → PostalCode | string | Yes | Customer’s Postal Code. The postal code must have eight digits—for example, 29018660. |
MetaDataIn → PaymentExpirationInMinutes | numeric | No | Configure the expiration time for the payment using this field, specifying the duration in minutes. The API applies a default value if you don't provide this information. |
MetadataIn → AddressStreet | string | Yes | Customer address street. |
MetadataIn → AddressNumber | string | Yes | Customer address number, floor, apartment. |
MetadataIn → AddressDistrict | string | Yes | Customer address district. |
Request example
To test this endpoint, use the API Reference or the Postman Collection
{
"PaymentMethod": "BLT",
"Order": "paymentID3022",
"Amount": 20000,
"Currency": "BRL",
"Description": "Purchase Test",
"MetaDataIn": {
"PaymentExpirationInMinutes": "7200",
"AddressStreet": "Avenida Anisio Fernandes Coelho",
"AddressNumber": "661",
"AddressDistrict": "PR"
},
"TargetCountryISO": "BR",
"Customer": {
"Address": {
"AddressDetail": "Avenida Anisio Fernandes Coelho, 661 ",
"PostalCode": "29060670",
"City": "Vitoria",
"State": "ES",
"Country": "Brasil"
},
"FirstName": "Jhon",
"LastName": "Doe",
"DocumentNumber": "47168892703",
"DocumentType": "CPF.BR",
"PhoneNumber": "3188060418",
"Email": "[email protected]"
}
}Response parameters
In the response, you will find the following parameters. For additional information about the response structure, refer to the Response parameters section of the Purchase creation guide.
| Property | Type | Description |
|---|---|---|
MetadataOut → PaymentCode | string | Payment code generated by Boleto Bancario |
MetadataOut → PaymentBarCode | string | Code of the barcode generated to complete the payment. |
MetadataOut → PaymentBarCodeUrl | string | URL of the payment page. You can redirect the payer to this page to download the boleto. |
MetadataOut → PaymentExpirationDate | date | Date when the payment will expire. Format DD/MM/YYYY HH:MM:SS. |
Payment page in Boleto
Response example
{
"TransactionId": "128635201747174176",
"Result": "COMPLETED",
"Status": "PENDING",
"ErrorCode": null,
"ErrorDescription": null,
"Created": "2024-12-20T20:46:20.199",
"AuthorizationDate": "2024-12-20T20:46:20.674",
"AuthorizationCode": "",
"Amount": 1000,
"Currency": "BRL",
"Installments": 1,
"TaxableAmount": null,
"Tip": null,
"Url": "https://api.stage.bamboopayment.com/Purchase/128635201747174176",
"MetadataOut": {
"PaymentCode": "bd88102f813cface085ea4ac63038a65cd5378228be2d5694f67b8a83af45931",
"PaymentBarCode": "10491814900000002009632034000900041179634666",
"PaymentBarCodeUrl": "https://pagar.sandbox.goboleto.com/?hash=bd88102f813cface085ea4ac63038a65cd5378228be2d5694f67b8a83af45931",
"PaymentExpirationDate": "09/01/2026 00:00:00"
},
"Action": null,
"PaymentMethod": {
"Brand": "Boleto",
"CardOwner": null,
"Bin": null,
"IssuerBank": null,
"Type": "BankTransfer",
"Expiration": null,
"Last4": null
}
}Discover the API
Once you’re familiar with how to create a purchase, you can test your integration using our API Reference:
Updated 15 days ago
