Returns an unsigned Solana transaction that transfers USDC from your personal smart wallet back to your wallet. You can only withdraw up to your withdrawable balance (smart wallet balance minus amounts committed to open orders).
Request body
The Solana wallet public key (base58-encoded).
Amount of USDC to withdraw in raw units (6 decimals). For example, "50000000" = $50 USDC.
Response
Base64-encoded unsigned VersionedTransaction. Sign and submit to Solana.
Human-readable description of the transaction.
curl -X POST https://api.pmx.trade/v2/clob/account/withdraw \
-H "Content-Type: application/json" \
-d '{ "pubkey": "7xKXabc123...", "amount": "50000000" }'
{
"transaction": "AQAAAAAAA...base64...",
"message": "Withdraw 50.000000 USDC from smart wallet"
}
Errors
| Code | HTTP Status | Meaning |
|---|
INSUFFICIENT_WITHDRAWABLE | 400 | The requested withdraw amount exceeds your available (non-committed) smart wallet balance. Cancel open orders to free committed collateral. |
{
"error": "INSUFFICIENT_WITHDRAWABLE",
"message": "Requested withdrawal of 50000000 exceeds withdrawable balance of 32500000. Cancel open orders to free committed collateral."
}
Check your withdrawable balance via GET /v2/clob/account/balances before withdrawing. USDC committed to open orders cannot be withdrawn until those orders are cancelled or filled.