> For the complete documentation index, see [llms.txt](https://docs.aevo.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.aevo.xyz/api-reference/urls/private-api/postwithdraw.md).

# POST /withdraw

Withdraws USDC from the exchange to L1 Ethereum.

`POST https://api.aevo.xyz/withdraw`

> **Authentication required.** Include your `AEVO-KEY` and `AEVO-SECRET` headers. See [Authentication](/api-reference/urls/authentication.md).

## Body Parameters

| Field                  | Type   | Required | Description                                                                                                                          |
| ---------------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| `account`              | string | Yes      | Account's Ethereum address. Example: `0xE9b3a48d15BE316A8e34FAd53fFDFDddf0C3D24b`                                                    |
| `collateral`           | string | Yes      | Ethereum address of the collateral asset. Example: `0xE9b3a48d15BE316A8e34FAd53fFDFDddf0C3D24b`                                      |
| `to`                   | string | Yes      | Ethereum address to send withdrawals to. Example: `0xE9b3a48d15BE316A8e34FAd53fFDFDddf0C3D24b`                                       |
| `amount`               | string | Yes      | Amount in USDC. In 6 decimals fixed number. Example: `1000000`                                                                       |
| `salt`                 | string | Yes      | A randomly generated number to guarantee transaction uniqueness. In 6 decimals fixed number. Example: `12345678`                     |
| `signature`            | string | Yes      | Hash of order payload signature signed by the account. Example: `0x4c55895aa6f2dfc2da8189a71a054348ce63abbc1ae27267977e0d9cc6848e91` |
| `recipient`            | string | No       | A recipient account's Ethereum address. Example: `0xE9b3a48d15BE316A8e34FAd53fFDFDddf0C3D24b`                                        |
| `socket_fees`          | string | No       | The socket gas fees. Example: `194670186373086`                                                                                      |
| `socket_msg_gas_limit` | string | No       | The socket message gas limit. Example: `500000`                                                                                      |
| `socket_connector`     | string | No       | The socket connector address. Example: `0x2b42AFFD4b7C14d9B7C2579229495c052672Ccd3`                                                  |

## Example Request

```bash
curl --request POST \
     --url https://api.aevo.xyz/withdraw \
     --header 'accept: application/json' \
     --header 'AEVO-KEY: <your-api-key>' \
     --header 'AEVO-SECRET: <your-api-secret>' \
     --header 'content-type: application/json' \
     --data '{ ... }'
```

## Responses

**`200`** — Withdraw status.

| Field     | Type    | Required | Description                                                 |
| --------- | ------- | -------- | ----------------------------------------------------------- |
| `success` | boolean | Yes      | Request successful if true. Example: `true` Example: `True` |

**`400`** — Bad request.

| Field   | Type   | Required | Description                                     |
| ------- | ------ | -------- | ----------------------------------------------- |
| `error` | string | Yes      | Error message. Example: `ERR_MALFORMED_REQUEST` |

**`401`** — Unauthorized.

| Field   | Type   | Required | Description                            |
| ------- | ------ | -------- | -------------------------------------- |
| `error` | string | Yes      | Error message. Example: `UNAUTHORIZED` |

**`429`** — Rate limit exceeded.

| Field   | Type   | Required | Description                                   |
| ------- | ------ | -------- | --------------------------------------------- |
| `error` | string | Yes      | Error message. Example: `RATE_LIMIT_EXCEEDED` |

**`500`** — Internal server error.

| Field   | Type   | Required | Description                              |
| ------- | ------ | -------- | ---------------------------------------- |
| `error` | string | Yes      | Error message. Example: `INTERNAL_ERROR` |
