> This page is for Internet banking (beta).

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://en.docs.api.corpx.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://en.docs.api.corpx.com/_mcp/server.

# Your account

Balance, deposit details, statement, exports and account close. Routes
are `GET` (except creating an export and closing the account) on `https://client.api.corpx.com`, with the
[signing](/ib/guias/autenticacao/assinatura-de-requisicoes) headers. `{accountId}` is the credential’s.

## Balance

`GET /v1/accounts/{accountId}/balance`

```bash
curl -X GET "https://client.api.corpx.com/v1/accounts/$ACCOUNT_ID/balance" \
  -H "Authorization: Bearer $TOKEN" \
  -H "X-Tenant-Id: $TENANT_ID" \
  -H "X-Request-Timestamp: $TS" \
  -H "X-Content-SHA256: e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" \
  -H "X-Request-Signature: $SIG"
```

```json
{
  "accountId": "6ff57bc1-e4a9-403b-be62-42378b8aafd7",
  "total": 18254.17,
  "locked": 500.00,
  "available": 17754.17,
  "currency": "BRL",
  "updatedAt": "2026-02-05T22:00:00Z"
}
```

`available` is what you can send. `locked` is the total held (for example
a MED dispute); the response does not list each hold. `includeLocks` is
accepted for compatibility and has no effect.

`409 account_not_ready` means the account has no counterpart at the
settlement bank yet — it is not a zero balance. `409 account_not_entitled`
means the service was not enabled; retrying does not help, talk to the
bank.

## Bank details

`GET /v1/accounts/{accountId}/bank-account` returns COMPE, branch and
number for TED deposits or internal transfers, without relying on a PIX
key.

```json
{
  "accountId": "6ff57bc1-e4a9-403b-be62-42378b8aafd7",
  "holderDocument": "62452650000125",
  "holderName": "Example Company LTDA",
  "bankCode": "681",
  "bankIspb": "50871921",
  "bankName": "Settlement bank",
  "branch": "0001",
  "accountNumber": "8339086",
  "status": "active"
}
```

To receive a TED, the counterparty types bank **681** (Compe), not the
ISPB.

## Statement

`GET /v1/accounts/{accountId}/statement`

The response is always a list: `items`, `totalElements`, `totalPages`,
`page`, `size`, `hasNext`, `hasPrevious`. Pagination is **zero-based**
(`page=0` is the first page).

| Query                   | Use                                                                                                |
| ----------------------- | -------------------------------------------------------------------------------------------------- |
| `endToEndId`            | 0 or 1 PIX by E2E. Ignores filters and page                                                        |
| `identifier`            | 0 or 1 PIX with that reference (tried before the E2E when both are sent). Ignores filters and page |
| `startDate` / `endDate` | Window (YYYY-MM-DD)                                                                                |
| `operation`             | `PIX`, `TED`, `BOLETO`, `INTERNAL_TRANSFER`                                                        |
| `order`                 | `asc` or `desc` (default `desc`)                                                                   |
| `size`                  | Page ceiling (max 100; a larger value is capped). `items` may be shorter                           |

`size` is a ceiling, not a promise: advance with `hasNext`, do not assume
`len(items) == size`.

Order is by instant, with one-second resolution and no guaranteed
tie-break when several entries share the same second. Prefer `order=asc`,
page until `hasNext` is false, and dedupe by `endToEndId` or `partnerId`.
For real-time credits, subscribe to `pix.in.completed`,
`pix.refund.received` and `transfer.internal.in`.

A PIX refund line has `reversal: true`, `partnerType: PIX_REFUND` and
`originalEndToEnd` (the PIX being refunded). `operation` stays `PIX`. The
original PIX, once refunded, carries `refundEndToEnd`, including a partial
refund.

Each item has a signed `amount` (negative = debit), `direction` (`IN` /
`OUT`) and a payer/payee pair. **This** account’s side has name, document
and bank; the counterparty has name and document — branch, account and
the other side’s key usually do not appear. For the full outbound PIX
payload, use `GET /v1/accounts/{accountId}/pix/payments/lookup`.

## Advanced statement (expensive)

`GET /v1/accounts/{accountId}/statement/advanced` filters by PIX key,
counterparty, amount range, direction and status — fields the settlement
bank does **not** filter. Each call walks the statement page by page. It
is for one-off investigation. **Do not poll it.** To track incoming PIX,
subscribe to `pix.in.completed`.

Thousands of entries a day and you only want the end of it? Use
`order=desc` with `occurredAfter` (RFC 3339 with offset): the scan starts
from the newest and stops once it crosses the instant. Details and
continuation by time in [Advanced statement search](/baas/guias/conta/extrato-avancado#i-only-want-the-most-recent-ones).

## Exports

`POST /v1/accounts/{accountId}/exports` queues CSV, XLSX or PDF. Response
`202`. Poll `GET .../exports` until `COMPLETED` and download at
`GET .../exports/{exportId}/download` (pre-signed URL).

```json
{
  "type": "statement",
  "startDate": "2026-05-01",
  "endDate": "2026-05-07",
  "format": "csv"
}
```

CSV/XLSX use the requested window in full. Headers are in Portuguese. `Valor` uses Brazilian formatting (`-1.234,56`). The last column is `Chave Pix`.
Balance after each row is not included.

## Daily balance

`GET /v1/accounts/{accountId}/daily-balance?startDate=2026-06-04&endDate=2026-06-05`
returns opening balances (total / blocked / available) and daily flows in
Brasília time. Max window 30 days. Closings exist only from 2026-06-04.

Flows are summed by type: Pix (`pixIn`, `pixOut`, `pixBillingOut`), TED
(`tedIn`, `tedOut`, `tedBillingOut`), internal transfer
(`internalTransferIn`, `internalTransferOut`, `internalTransferBillingOut`),
boleto (`bankSlipOut`), BRMT (`stablecoinMint`, `stablecoinBurn`) and card
settlement (`cardSettlementIn` for debit, credit and receivables
prepayment; `cardSettlementOut` for outflows). Every field is always
present, `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`, with `Idempotency-Key`. The
credential needs the `accounts.close` scope; without it,
`403 insufficient_scope`.

When no other tenant operates the account, the closure goes to the
settlement bank, which only closes a zeroed account: no available balance
and no locked balance. The balance is checked first:

* available balance other than zero: **422**
  [`account_has_balance`](/ib/guias/referencia/erros#account_has_balance) —
  withdraw it and retry;
* zero available with a locked balance (for example a MED hold): **422**
  [`account_has_locked_balance`](/ib/guias/referencia/erros#account_has_locked_balance)
  — wait for the release and retry.

In both cases the account stays active and the body carries `balance`
(`total`, `available`, `locked`, `currency`). With the balance zeroed, the
response is `200` (`accountId` and `message`): the closure is requested from
the settlement bank and the account becomes `status=closed` in the same
call. The bank account itself is closed when the settlement bank processes
the request.

## Transaction timeline

Two paths:

* `GET /v1/accounts/{accountId}/transactions/timeline?endToEndId=` (or
  `identifier`) — exactly one of the two
* `GET /v1/transactions/{transactionId}/timeline` — by `paymentId`,
  partner id, E2E or QR `txid`

The timeline gathers confirmations, outbound webhooks, fees, refunds and
QR lifecycle.