Consult Balance
This guide quickly demonstrates how to consult your balance available for payouts in EBANX. We will walk you through the basic steps to achieve this goal using your already existing Direct API integration.
Instructions
Follow the steps below:
Consult a payout using the /ws/payout/balance end-point
To consult your available balance, you will use the /ws/payout/balance endpoint.
Your integration key is the only required parameter.
curl -X POST 'https://sandbox.ebanxpay.com/ws/payout/balance' \
-d 'integration_key=your_test_integration_key'And a successful call will return a JSON Object with type "success" and your available balance.
{
"type": "success",
"currency_code": "USD",
"balance": 150
}It is possible to query whether there is a balance for a different
currency_code
:curl -X POST 'https://sandbox.ebanxpay.com/ws/payout/balance' \
-d 'integration_key=your_test_integration_key' \
-d 'currency_code=BRL'{
"type": "success",
"currency_code": "BRL",
"balance": 490
}And, also, look up the consolidated balance of the previous days (only
CrossBorder
environment, actually):curl -X POST 'https://sandbox.ebanxpay.com/ws/payout/balance' \
-d 'integration_key=your_test_integration_key' \
-d 'date=2020-01-02'{
"type": "success",
"currency_code": "USD",
"date": "2020-01-02",
"balance": 291
}look up the consolidated balance of the previous days by
currency_code
:curl -X POST 'https://sandbox.ebanxpay.com/ws/payout/balance' \
-d 'integration_key=your_test_integration_key' \
-d 'currency_code=ARS' \
-d 'date=2020-01-02'{
"type": "success",
"currency_code": "ARS",
"date": "2020-01-02",
"balance": 2000
}
Balance Error Codes
When an API call fails, EBANX will return a JSON object containing the error details as the example below:
{
"type":"invalid_request_error",
"message":"Invalid currency code",
"status_code":"HP-BA-01",
"code":"HP-BA-01"
}
Observe the following table and verify the codes and error messages that EBANX uses.
Code | Message |
---|---|
HP-BA-01 | Invalid currency code |
HP-BA-02 | Invalid date |
Consulting Balance via Dashboard
You can also consult your available balance through your Dashboard in the Overview section of the Payout tab.
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.