Boleto payment
Creates a boleto linked to an existing order. Returns the PDF link and the digitable line.
The boleto is an offline payment option: the customer pays at a bank, a lottery outlet, or through internet banking, outside your checkout.
Show the boleto on the success page
Offer the option to download the PDF (pdf_url) and to copy the
digitable line (digitable_line) on the success page, so the customer
can pay through the channel they prefer.
Don't open the PDF in an iframe
The boleto download (pdf_url) must redirect the customer to
another page, and must not be opened embedded in an iframe on your
checkout/success page.
Testing in the sandbox
In the sandbox, the boleto is automatically approved about 5 seconds
after it is generated. The scenario depends on the document_number:
document_number |
Result in the sandbox |
|---|---|
Any valid CPF or CNPJ (e.g., 19100000000) |
Approved in ~5 s and then integrated |
CPF 40827365144 or CNPJ 40827365000109 |
Stays pending (the payment is not confirmed) |
Both scenarios are ready in the Request Body, in the Sandbox: approved and Sandbox: pending tabs. Webhooks received in each one: Test Pix and boleto in the sandbox.
Authorizations
Bearer token of the merchant obtained via POST /oauth2/token using the
merchant's credentials (not the app's). See
Authentication.
Request Body
Responses
Boleto generated successfully.