🇧🇷 Brazil
Learn everything you need to know about making payouts in Brazil.
Payment Methods
- Pix Instant
- Mercado Pago Instant
- TED (Bank Transfer)
Available Operations
- Local LATAM
- Cross Border
Payee Types
- B2B
- B2C
Payment Methods​
Checkout our SLAs for each payment method:
| Payment Method | SLA | B2B | B2C |
|---|---|---|---|
| < 2 minutes | check_circle_outline | check_circle_outline | |
| < 2 minutes | check_circle_outline | check_circle_outline | |
| Up to 3 days | check_circle_outline | check_circle_outline |
Instructions​
To create a payout using EBANX Direct API, follow the steps below.
- Define request parameters​
Provide the required parameters listed below to create a payout.
Field Description integration_keyYour EBANX integration key. external_referenceThe unique payout ID provided by you. countryThe two-letter country code for the customer country. In this case, we'll show the method to br (Brazil) amountThe amount in the specified currency (currency_code). currency_codeThree-letter code of the payout currency. In this case, we'll use BRL (Brazil) payeeA JSON object containing the details of the payee of your request. targetThe payment method that will be used. Can be left empty and the payout target will be assumed as Bank Transfer. More info below. Document Types Allowed
These document types are used to identify payees or shareholders.
Document type Description CPF An 11-digit Tax ID used to identify individuals. CNPJ A 14-digit Tax ID used to identify companies. - Send payout request to EBANX​
To create a new Payout, you will use the /ws/payout/create endpoint.
The following example is a payout create request to the payee's bank account sending bank data with bank details:
curl -X POST 'https://sandbox.ebanx.com/ws/payout/create' \
--header 'Content-Type: application/json' \
--data '{
"integration_key": "your_test_integration_key",
"external_reference": "PAYOUT_EBANX_04",
"country": "br",
"amount": 10,
"currency_code": "USD",
"payee": {
"name": "Han Solo",
"email": "chew@bac.ca",
"phone": "+554112345678",
"document": "85351346893",
"document_type": "cpf",
"bank_info": {
"bank_name": "104 Caixa Econômica",
"bank_branch": "3708",
"bank_account": "08251777-6",
"account_type": "C",
"bank_details": "001"
},
"address": {
"zipcode": "80320070",
"state": "PR",
"city": "Curitiba",
"street_address": "Fake Street",
"street_complement": "123"
}
}
}'When onboarding payees in Brazil, you can trigger a self-onboarding flow by submitting partial data. This sends an automatic email to the payee to finalize their registration.
When
bank_detailsis not provided (or is null), the Operation value defaults to the following mapping:Document type Account Type Operation CPF S (Savings) 013 CPF C (Checkings) 001 CNPJ S (Savings) 022 CNPJ C (Checkings) 003 warningThe
bank_detailsparameter is obligatory if the bank code is 104 (Caixa Econômica).Including
bank_detailsin the payload overrides the self-onboarding process. The API will use the provided data directly instead of requesting it from the payee.curl -X POST 'https://sandbox.ebanx.com/ws/payout/create' \
--header 'Content-Type: application/json' \
--data '{
"integration_key": "your_test_integration_key",
"external_reference": "PAYOUT_EBANX_04",
"country": "br",
"amount": 10,
"currency_code": "USD",
"payee": {
"name": "Han Solo",
"email": "chew@bac.ca",
"document": "85351346893",
"document_type": "cpf"
}
}'Choose the payment method for your payout request:
Pix
Mercado Pago
TED
Identifying the Payee:
You can initiate a Pix transfer using one of two methods:
Pix using bank account info: Identify the payee using their bank account details.
Pix Key: Identify the payee using a
pix_keya unique code linked to their account. (Seetarget_accountfor a list of valid key formats).- Pix Using Bank Account Info
- Pix Key
The following example demonstrates a request to send a Pix transaction using the payee's bank account information.
curl -X POST 'https://sandbox.ebanx.com/ws/payout/create' \
--header 'Content-Type: application/json' \
--data '{
"integration_key": "your_test_integration_key",
"external_reference": "PAYOUT_EBANX_04",
"country": "br",
"amount": 10,
"currency_code": "BRL",
"target": "pix",
"payee": {
"document": "08432961781",
"document_type": "CPF",
"name": "Carlos Machado",
"email": "carlos_machado_pix@gmail.com",
"bank_info": {
"bank_name": "104 Caixa Econômica",
"bank_branch": "3708",
"bank_account": "08251777-6",
"account_type": "C",
"bank_details": "001",
"bank_ispb": "00360305"
}
}
}'tipYou can use either
bank_ispborbank_name. We recommend choosing one of them.The following example demonstrates a request to send a Pix transaction using the payee's Pix Key.
noteA Pix Key is a unique identifier associated with the payee's account. (See
target_accountfor supported key types.)curl -X POST 'https://sandbox.ebanx.com/ws/payout/create' \
--header 'Content-Type: application/json' \
--data '{
"integration_key": "your_test_integration_key",
"external_reference": "PAYOUT_EBANX_04",
"country": "br",
"amount": 10,
"currency_code": "BRL",
"target": "pix_key",
"target_account": "carlos_machado_pix@gmail.com",
"payee": {
"document": "08432961781",
"document_type": "CPF",
"name": "Carlos Machado",
"email": "carlos_machado_pix@gmail.com"
}
}'A successful request returns the following JSON response:
{
"integration_key":"your_ebanx_integration_key",
"external_reference":"teste_mass_prod_2",
"country":"br",
"amount":"10",
"currency_code":"BRL",
"use_payee_hub":false,
"payee":{
"document":"08432961781",
"document_type":"cpf",
"name":"Carlos Machado",
"email":"carlos_machado_pix@gmail.com",
"birthdate":null,
"address":{
"zipcode":"80010-010",
"state":"PR",
"city":"Curitiba",
"street_address":"Rua Marechal Deodoro",
"street_complement":"630"
}
},
"target":"pix_key",
"target_account":"carlos_machado_pix@gmail.com"
}For Mercado Pago transactions, the
targetparameter must be set to "mercadopago". Additionally, thetarget_accountmust contain the email address linked to the payee's account.curl -X POST 'https://sandbox.ebanx.com/ws/payout/create' \
--header 'Content-Type: application/json' \
--data '{
"integration_key": "your_test_integration_key",
"external_reference": "PAYOUT_EBANX_04",
"country": "br",
"amount": 10,
"currency_code": "BRL",
"target": "mercadopago",
"target_account": "chew@bac.ca",
"payee": {
"document": "85351346893",
"document_type": "CPF",
"name": "Han Solo",
"email": "chew@bac.ca"
}
}'To use TED (Bank Transfer) as the payment method, the
targetfield needs to be filled in as "bank_transfer" or it can be left as blank.A successful creation will return a JSON Object with type "success" and a payout object with all the details of the newly created payout.
{
"type": "success",
"payout": {
"uid": "a1352f5341c3c8c1e40ea9c06715f05778ff35ee",
"external_reference": "PAYOUT_EBANX_04",
"status": "OP",
"request_date": "2020-09-18 13:26:53",
"status_date": null,
"paid_date": null,
"cancel_date": null,
"payee": {
"name": "Han Solo",
"email": "chew@bac.ca",
"phone": "554112345678",
"document": "85351346893",
"document_type": "CPF",
"birthdate": null,
"bank_info": {
"bank_name": "104 Caixa Econ\u00f4mica",
"bank_branch": "3708",
"bank_account": "8251777-6",
"account_type": "C",
"bank_details": "001"
}
},
"request_amount": "10.00",
"request_currency": "USD",
"request_exchange_rate": "1.0000",
"debit_amount": "10.00",
"debit_fee": "0.15",
"debit_amount_total": "10.15",
"debit_currency": "USD",
"local_tax_amount": "0.12",
"local_amount_total": "32.88",
"local_currency": "USD",
"local_exchange_rate": "3.2997"
}
} - Send commit request to EBANX​
Once the new payout record is created it'll be committed automatically after 6 hours. Or you can use the /ws/payout/commit endpoint to start the payment process.
Here's an example of a commit operation using the payout we've just created:
curl -X POST 'https://sandbox.ebanx.com/ws/payout/commit' \
--header 'Content-Type: application/json' \
--data '{
"integration_key": "your_test_integration_key",
"uid": "0e495f7a4409c032d54376084b10b9c771e9b39f0"
}'Once the new payout is commited, a JSON Object with type "success" will be returned.
{
"type": "success",
"message": "Payout has already been committed"
} - Congratulations!​
You have successfully Created a Payout in Brazil.
Creating a Payout using the Dashboard​
You can also create a payout through our Dashboard in the Overview section of the Payout tab. Click on Create Payout, fill in the payee information, payout amount and click on Create. Additionally, you can create a Mass Payout by sending a spreadsheet to be processed in bulks.
Verify the bank branch code. For many digital banks, such as Nubank, Inter, and C6, the required branch is typically 0001. Entering a different number may cause the payment to be rejected.
Available Banks​
| Bank Code | Institution Name |
|---|---|
| 001 | Banco do Brasil S.A. |
| 033 | Banco Santander (Brasil) S.A. |
| 104 | Caixa Econômica Federal |
| 237 | Banco Bradesco S.A. |
| 341 | Itaú Unibanco S.A. |
| 260 | Nu Pagamentos S.A. (Nubank) |
| 077 | Banco Inter S.A. |
| 336 | Banco C6 S.A. |
| 290 | PagSeguro Internet S.A. |
| 380 | PicPay Serviços S.A. |
| 323 | Mercado Pago |
| 212 | Banco Original S.A. |
| 655 | Banco Votorantim (Neon) |
| 041 | Banrisul |
| 070 | BRB – Banco de BrasÃlia |
| 748 | Sicredi |
| 756 | Bancoob (Sicoob) |
| 074 | Banco Safra S.A. |
| 422 | Banco Safra (Carteira Digital) |
| 654 | Banco Digimais (antigo Renner) |
| 218 | Banco BS2 S.A. |
| 069 | BPN Brasil / Crefisa |
| 121 | Banco Agibank S.A. |
| 318 | Banco BMG S.A. |
| 208 | Banco BTG Pactual S.A. |
Possible Errors​
Click here and check out our Payout Error Code page to learn more about the possible errors.
Still need help?
We hope this article was helpful. If you still have questions, you can explore the following options:
- Merchant support: Contact our support team at sales.engineering@ebanx.com for assistance.
- Not a partner yet? Please complete the Merchant Signup Form, and our commercial team will reach out to you.