> ## Documentation Index
> Fetch the complete documentation index at: https://docs.floprouter.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Withdrawals

> Send your prepaid balance back to your wallet.

`POST /v1/balance/withdraw` sends FLOP from the deposit wallet to the wallet that owns your key. It cannot send anywhere else.

```bash theme={null}
curl -X POST https://api.floprouter.com/v1/balance/withdraw \
  -H "Authorization: Bearer $FLOPROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"amount": "0.5"}'
```

| Field | Meaning |
| - | - |
| `amount` | Decimal FLOP, or `"all"` for the whole available balance. |
| `to` | Optional. When given, it must equal the wallet that owns the key. |

The amount is held first, so a withdrawal cannot race a session or another withdrawal. The chain fee is estimated and taken out of the amount sent.

## Response

`200` once the transfer is final on chain. The shape, with placeholder values:

```json theme={null}
{
  "object": "withdrawal",
  "id": "...",
  "to": "5...",
  "status": "sent",
  "requested": "0.5",
  "sent": "<amount minus the fee estimate>",
  "chain_fee": "<fee the chain charged>",
  "tx": "0x...",
  "block": 4498929,
  "balance_after": "<what is left>"
}
```

`sent` is the requested amount minus the fee estimate. `chain_fee` is the fee the chain charged. The ledger in `GET /v1/balance` books both, as `withdrawal` and `withdrawal_fee`.

## Limits and errors

* One withdrawal per wallet at a time, and at most 10 per wallet per hour.

| HTTP | `code` | What it means |
| - | - | - |
| 400 | `invalid_amount`, `amount_too_small`, `invalid_destination` | The amount or `to` is not valid. Nothing was sent. |
| 402 | `insufficient_balance` | The available balance is less than the amount. Nothing was sent. |
| 409 | `withdrawal_in_progress` | Another withdrawal for this wallet is in flight. Wait for it. |
| 429 | `rate_limited` | More than 10 in the hour. Wait for `Retry-After`. |
| 503 | `withdrawals_unavailable`, `treasury_insufficient`, `withdrawal_failed` | The transfer was not sent. Your balance is unchanged. Retry later. |
| 503 | `withdrawal_outcome_unknown` | The transfer's outcome is not known yet. The amount stays held until the router reconciles it. Do not retry; check `GET /v1/balance`. |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.