BlooBank organizes all financial movement around the Payment Order — a single resource type that represents any operation that moves money, in either direction, through any supported network. There are no separate “Pix-In” or “Pix-Out” resources; both are payment orders with a differentDocumentation Index
Fetch the complete documentation index at: https://developers.bloobank.com/llms.txt
Use this file to discover all available pages before exploring further.
direction field.
The model
Every payment order has:| Field | Notes |
|---|---|
direction | IN (cash-in) or OUT (cash-out). |
network | The payment network (currently br.gov.bcb.pix). |
amount | Integer minor units (e.g., cents for BRL). |
currency | ISO 4217 code. |
instrument | Discriminated union — five PIX variants today. See Instrument types. |
idempotencyKey | Caller-supplied; makes the create safe to retry. See Idempotency. |
status | Lifecycle state. See Payment lifecycle. |
metadata | Free-form caller-supplied tags. |
Direction defines the workflow
| Direction | Workflow |
|---|---|
IN | One-step. POST creates the order, the platform immediately submits it to the provider, and the order starts in PENDING. The payer settles when they pay the QR/key. |
OUT | Two-step. POST creates the order in AWAITING_APPROVAL. A subsequent PUT .../approve submits it to the provider; PENDING follows. This gates outbound flows behind an explicit human (or automated) approval. |
Identifiers
Every payment order carries three identifiers:id
Server-assigned at creation:
ord_3KpFvBwYzNqMxA7eHbRdJ. Immutable. Use as your database key.idempotencyKey
Caller-supplied at creation. Bound to the
(wallet, idempotencyKey) tuple. Makes the create safe to retry.endToEndId
PIX-network-assigned end-to-end identifier. Populated after the provider returns it (typically on settlement).
endToEndId is what the PIX network uses. For your internal records, id is the BlooBank-side identifier and idempotencyKey is your client-side identifier.
A complete example — inbound (cash-in)
Create the payment order
201 Created with status: "PENDING" and the instrument populated (qrcode, copypaste, expiresAt).Render the QR code to your customer
The
instrument.qrcode and instrument.copypaste fields contain provider-rendered PIX payloads. Display them; the customer pays via their bank app.Wait for the webhook (or poll)
When the customer pays, the order transitions to
SUCCESS and a webhook fires. See Webhooks overview.A complete example — outbound (cash-out)
Create the payment order
201 Created with status: "AWAITING_APPROVAL". No money has moved yet.Approve
200 OK with status: "PENDING". The order is now submitted to the PIX network. locked increases by the amount.Or cancel (alternative to approval)
200 OK with status: "CANCELED". The order never reaches the provider.Amounts
All amounts are integers in minor units:| Display | API amount |
|---|---|
| R$ 1.00 | 100 |
| R$ 250.00 | 25000 |
| R$ 1,234.56 | 123456 |
Idempotency
For payment orders, always supply anidempotencyKey. Retrying without one creates a duplicate payment. The pattern:
- Persist the key in your local database before calling the API.
- Include it in the create body.
- On any network failure, retry with the same key.
- Use the API response to reconcile your local state.
Networks today
| Network | Code | Direction | Notes |
|---|---|---|---|
| Pix (Brazil) | br.gov.bcb.pix | IN / OUT | The current network for both directions. |
ProviderNetwork enum). The direction + network + instrument.type triple determines which provider handles the order.
Next
Lifecycle
The state machine: AWAITING_APPROVAL → PENDING → PROCESSING → final.
Instrument types
The five PIX variants and when to use each.
Pix cash-in tutorial
End-to-end inbound flow.
Pix cash-out tutorial
End-to-end outbound flow with approval.