Balance, daily balance and account close
Current balance, daily balance series and closing an account, on
https://tenant.api.corpx.com. Every call carries
Authorization: Bearer {token} and X-Tenant-Id.
Balance
GET /v1/accounts/{accountId}/balance
available is what the account can send. locked is the total held (for
example a MED hold); the response does not list each
hold. includeLocks is accepted for compatibility and has no effect.
Daily balance
GET /v1/accounts/{accountId}/daily-balance?startDate=2026-06-04&endDate=2026-06-05
Returns, per day, the opening balance (total / blocked / available) and the
day’s flows, in Brasília time. Max window 30 days; without dates, the last 30
days. Closings exist only from 2026-06-04 (cutoffDate).
Flows are summed by type, always present, and 0 when there was no
movement:
A day’s opening balance is the previous day’s opening plus that day’s inflows, minus its outflows and fees.
Close the account
POST /v1/accounts/{accountId}/close
Removes your tenant’s access to the account. People need the
tenant_manager or admin role; credentials need the accounts.close
scope (legacy api2/write still passes). Send an Idempotency-Key so the
call can be retried safely.
The 200 is the same whether another CorpX tenant still operates the
account or yours is the last one. The account is not deleted: it becomes
status=closed. Repeating the request on an account already closed in your
tenant returns the same 200, with no new closure request.
When the account is yours alone, the closure is requested from the settlement bank, which only accepts a zeroed account: no available balance and no locked balance. The settlement-bank balance is checked first:
In both 422 cases the account stays active and the body carries the
settlement-bank balance:
The bank account itself is closed when the settlement bank processes the
request; the 200 does not say when.
Other errors: