Skip to main content

Preview a Crypto Withdrawal

Quotes a withdrawal to a counterparty without making it: the fee, what the counterparty receives, and whether the account's balance covers it. Nothing is stored and nothing is reserved; the id it answers cannot be looked up.

The fee is taken inside the amount: the counterparty receives amount minus fee. When the fee is larger than the amount asked for, it is added on top instead: amount becomes the amount asked for plus the fee, and the counterparty receives the amount asked for.

The minimum withdrawal and the minimum fee are set in US dollars and converted into the coin at its market price, so in units of the coin they move with the price.

Beta

Part of crypto v3, in beta. While crypto v3 withdrawals are off for the account, this answers 404 feature_not_enabled.

A workspace-scoped key names the account with account_id; an account-scoped key acts for its own account.

Replaces POST /api/v2/crypto/withdraw/preview.

Authorization:

Every request is signed with your API key: a short-lived JWT, signed with your private key, sent in one header on /v3/* and /api/v2/* alike.

Headers:
Authorization: APIKey {SIGNED_JWT}

How to build and sign the JWT: Authentication.

Endpoint

POST

/v3/crypto/withdrawals/preview

Query parameters​

ParameterTypeDescription
account_idstring (cst_…)The account to withdraw from. Required for a workspace-scoped key; an account-scoped key may omit it.

Request Body Sample​

{
"counterparty_id": "wlt_01k8z5q7r9s1t3v5w7x9y1z3a5",
"coin": "USDC",
"amount": "250",
"description": "Supplier payment"
}

Request Body Schema​

FieldTypeDescription
counterparty_idstring (wlt_…)Required. One of the account's counterparties.
coinstringRequired. The coin to send: the counterparty's coin. Any casing.
amountstring (decimal)Required. How much to withdraw, in the coin, greater than zero, as a decimal string.
descriptionstringOptional. Up to 255 characters.

Response Sample​

{
"id": "wtx_01k9a0x2y4z6a8b0c2d4e6f8g0",
"account_id": "cst_01h455vb4pex5vsknk084sn02q",
"status": "preview",
"coin": "USDC",
"amount": "250",
"fee": "10",
"total": "240",
"counterparty_id": "wlt_01k8z5q7r9s1t3v5w7x9y1z3a5",
"counterparty_address": "0x8f3b2c1d0e9a7b6c5d4e3f2a1b0c9d8e7f6a5b4c",
"description": "Supplier payment",
"estimate": {
"provider": "fireblocks",
"network_fee": "0.00042",
"provider_fee": "0",
"expires_at": "2026-10-20T18:05:00Z"
}
}

Response Schema​

FieldTypeDescription
idstring (wtx_…)A disposable id. Nothing is stored under it; pass it to the create as preview_id to record which preview was shown.
account_idstring (cst_…)The account.
statusstringAlways preview.
coinstringThe coin, upper case.
amountstring (decimal)What would leave the balance.
feestring (decimal)What the account would pay, inside amount.
totalstring (decimal)What the counterparty would receive: amount minus fee.
counterparty_idstring (wlt_…)The counterparty.
counterparty_addressstringIts address, without the memo.
descriptionstringAs sent; absent when empty.
estimateobjectThe custodian's own figures, when it can give them: provider; network_fee, its estimate of the network cost as it reports it; provider_fee; and expires_at, until when the estimate holds. For information only: they are not part of fee. Absent when the custodian gives none.

Amounts are decimal strings in the coin, without trailing zeros (see Amounts). The amounts are computed again when the withdrawal is created.

Errors​

StatusmessageWhen
400account_id_requiredA workspace-scoped key named no account_id.
400invalid_account_idaccount_id is not a cst_… id.
400failed to parse requestThe body is not valid JSON, counterparty_id is not a wlt_… id, coin is not a ticker, or amount is not a decimal.
400invalid_coincoin is a fiat currency, such as USD.
400invalid_amountamount is missing, zero or negative.
400counterparty_coin_mismatchcoin is not the counterparty's coin.
401unauthorizedMissing or invalid signature.
403forbiddenAn account-scoped key named another account.
404feature_not_enabledCrypto v3 withdrawals are not enabled for the account. See Turning it on.
404counterparty_not_foundcounterparty_id is missing, names no counterparty, or names another account's or a deleted one.
422withdrawal_below_minimumamount is below the minimum withdrawal for this coin.
422withdrawal_coin_unsupportedBlockWyre cannot send this coin.
422insufficient_balanceThe account's available balance in this coin does not cover amount.
422Validation failedcoin is missing, or description is longer than 255 characters; details names it.

Coming from v2​

v2 (POST /api/v2/crypto/withdraw/preview)v3
accountId in the bodyaccount_id in the query, optional for an account-scoped key
beneficiaryIdcounterparty_id (wlt_…): the same id as a TypeID
beneficiaryAddresscounterparty_address
—estimate

Support and Resources​

If you need assistance or have any questions, our support team is here to help. You can contact our support team at support@blockwyre.com.

Stay Updated​

Stay up-to-date with the latest news, updates, and features from BlockWyre by following us on social media:

We are excited to have you on board and look forward to seeing how you leverage BlockWyre's powerful tools to enhance your financial operations. Happy integrating!