API Reference
Deposits and withdrawals

Create withdrawal order

POST/api/v1/customer/{customerId}/orders/withdrawal/account/{accountId}
Base URL: https://bloquo.mimicr.dev · provider: https://api.bloquo.io

Creates a withdrawal order from the specified account.

FIAT withdrawals: Provide a pixKey. Funds are sent via PIX. If autoExecuteWithdrawal: true on the account, the order is submitted to the payment provider automatically.

CRYPTO withdrawals: Provide walletAddress + blockchain. The destination wallet must be pre-registered in the customer's wallet whitelist (see POST /crypto/wallet/whitelist).

The fee formula: fee = max(min(amount × feePercentage, maxPercentageFee), flatFee) Total debited from balance: amount + fee.

Authorization

Bearer token in the Authorization: Bearer <token> header. See Authentication.

Path parameters

customerIdinteger<int64>required
accountIdinteger<int64>required

Body

application/json
amountnumberrequired

Amount to withdraw (before fees).

Example: 500
namestringrequired

Name of the recipient/beneficiary.

Example: "João Silva"
receiverTaxIdstring

CPF/CNPJ of the recipient (for FIAT withdrawals).

Example: "987.654.321-00"
receiverAccountKeystring

PIX key of the recipient (for PIX withdrawals). One of receiverAccountKey or receiverWalletAddress is required.

Example: "987.654.321-00"
receiverWalletAddressstring

Blockchain destination address for CRYPTO withdrawals. Must be pre-registered in the wallet whitelist.

Example: "0xabcdef1234567890abcdef1234567890abcdef12"
receiverBlockchainstring

Blockchain network for the destination wallet. Required with receiverWalletAddress.

Example: "Ethereum"
webhookUrlstring

URL to receive status update notifications for this order. Takes priority over the customer's notification preference URL.

Example: "https://your-system.example.com/webhooks/withdrawal"

Responses

201Withdrawal order created.
idinteger<int64>
Example: 300
customerIdinteger<int64>
Example: 42
accountIdinteger<int64>
Example: 10
requestedAmountnumber
Example: 500
totalAmountnumber

Total deducted from balance (requestedAmount + fee).

Example: 502.5
currencystring
Example: "BRL"
statusstring

Lifecycle status of an order. Key statuses: - PENDING_DEPOSIT, awaiting payment confirmation from the bank (FIAT deposits with auto-execute). - PENDING_TREASURY, manually reviewed or crypto orders waiting for treasury action. - WAITING_FUNDS, FX payment waiting for the funding deposit to be confirmed. - PENDING_APPROVAL, FX payment awaiting compliance review. - COMPLETED, order fully settled. - FAILED / REJECTED / EXPIRED: terminal failure states.

18 values
CREATEDACCEPTEDPENDING_DEPOSITPENDING_APPROVALPENDING_TREASURYSENT_TO_CONNECTORPENDING_IN_BANKPROCESSINGCOMPLETEDFAILEDCANCELLEDPROCESSING_REFUNDRETURNEDEXPIREDBLOCKEDREJECTEDWAITING_FUNDSWAITING_WITHDRAWAL
customerStatusstring | null

Human-readable status label for display.

Example: "COMPLETED"
originstring

How the order was created.

APIMANUALCSV_IMPORT
receiverNamestring | null
Example: "João Silva"
receiverTaxIdstring | null
Example: "987.654.321-00"
receiverAccountKeystring | null

PIX key of the recipient (for FIAT withdrawals).

Example: "987.654.321-00"
receiverWalletAddressstring | null

Blockchain destination address (for CRYPTO withdrawals).

receiverBlockchainstring | null
e2eIdstring | null

End-to-end transaction identifier returned by the payment provider.

Example: "E18236120202401151100XYZ"
webhookUrlstring | null
Example: "https://your-system.example.com/webhooks/withdrawal"
orderHistoryobject[]

Status change history for this order, oldest first.

Show child attributes
statusNamestring
Example: "COMPLETED"
descriptionstring | null
createdAtstring<date-time>
Example: "2024-01-15T11:00:00Z"
createdAtstring<date-time>
Example: "2024-01-15T10:30:00Z"
lastUpdatedAtstring<date-time>
Example: "2024-01-15T11:00:00Z"
400Business validation failed. Common reasons: - Insufficient balance - Wallet address not in whitelist (CRYPTO) - Missing required fields for FIAT or CRYPTO
statusboolean
resultany | null
messagestring