curl --request POST \
--url https://whitebit.com/api/v4/main-account/withdraw-pay \
--header 'Content-Type: application/json' \
--header 'X-TXC-APIKEY: <api-key>' \
--header 'X-TXC-PAYLOAD: <api-key>' \
--header 'X-TXC-SIGNATURE: <api-key>' \
--data '
{
"ticker": "ETH",
"amount": "0.9",
"address": "0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c",
"uniqueId": "24529041",
"request": "{{request}}",
"nonce": 1594297865000
}
'import requests
url = "https://whitebit.com/api/v4/main-account/withdraw-pay"
payload = {
"ticker": "ETH",
"amount": "0.9",
"address": "0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c",
"uniqueId": "24529041",
"request": "{{request}}",
"nonce": 1594297865000
}
headers = {
"X-TXC-APIKEY": "<api-key>",
"X-TXC-PAYLOAD": "<api-key>",
"X-TXC-SIGNATURE": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-TXC-APIKEY': '<api-key>',
'X-TXC-PAYLOAD': '<api-key>',
'X-TXC-SIGNATURE': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
ticker: 'ETH',
amount: '0.9',
address: '0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c',
uniqueId: '24529041',
request: '{{request}}',
nonce: 1594297865000
})
};
fetch('https://whitebit.com/api/v4/main-account/withdraw-pay', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://whitebit.com/api/v4/main-account/withdraw-pay",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'ticker' => 'ETH',
'amount' => '0.9',
'address' => '0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c',
'uniqueId' => '24529041',
'request' => '{{request}}',
'nonce' => 1594297865000
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-TXC-APIKEY: <api-key>",
"X-TXC-PAYLOAD: <api-key>",
"X-TXC-SIGNATURE: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://whitebit.com/api/v4/main-account/withdraw-pay"
payload := strings.NewReader("{\n \"ticker\": \"ETH\",\n \"amount\": \"0.9\",\n \"address\": \"0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c\",\n \"uniqueId\": \"24529041\",\n \"request\": \"{{request}}\",\n \"nonce\": 1594297865000\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-TXC-APIKEY", "<api-key>")
req.Header.Add("X-TXC-PAYLOAD", "<api-key>")
req.Header.Add("X-TXC-SIGNATURE", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://whitebit.com/api/v4/main-account/withdraw-pay")
.header("X-TXC-APIKEY", "<api-key>")
.header("X-TXC-PAYLOAD", "<api-key>")
.header("X-TXC-SIGNATURE", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"ticker\": \"ETH\",\n \"amount\": \"0.9\",\n \"address\": \"0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c\",\n \"uniqueId\": \"24529041\",\n \"request\": \"{{request}}\",\n \"nonce\": 1594297865000\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://whitebit.com/api/v4/main-account/withdraw-pay")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-TXC-APIKEY"] = '<api-key>'
request["X-TXC-PAYLOAD"] = '<api-key>'
request["X-TXC-SIGNATURE"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"ticker\": \"ETH\",\n \"amount\": \"0.9\",\n \"address\": \"0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c\",\n \"uniqueId\": \"24529041\",\n \"request\": \"{{request}}\",\n \"nonce\": 1594297865000\n}"
response = http.request(request)
puts response.read_bodyCreate withdraw request with the specific withdraw amount (fee is not included)
The endpoint has the similar logic as /main-account/withdraw, but with the only difference: amount that is specified will not include fee (it will be calculated to make target withdraw amount equal to the specified amount).
Example:
- When creating a base withdraw with amount = 100 USD, the receiver receives 100 USD minus the fee, and the balance decreases by 100 USD.
- When using this endpoint with amount = 100 USD, the receiver receives 100 USD, and the balance decreases by 100 USD plus the fee.
Rate limit: 1000 requests/10 sec.
The API does not cache the response.
curl --request POST \
--url https://whitebit.com/api/v4/main-account/withdraw-pay \
--header 'Content-Type: application/json' \
--header 'X-TXC-APIKEY: <api-key>' \
--header 'X-TXC-PAYLOAD: <api-key>' \
--header 'X-TXC-SIGNATURE: <api-key>' \
--data '
{
"ticker": "ETH",
"amount": "0.9",
"address": "0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c",
"uniqueId": "24529041",
"request": "{{request}}",
"nonce": 1594297865000
}
'import requests
url = "https://whitebit.com/api/v4/main-account/withdraw-pay"
payload = {
"ticker": "ETH",
"amount": "0.9",
"address": "0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c",
"uniqueId": "24529041",
"request": "{{request}}",
"nonce": 1594297865000
}
headers = {
"X-TXC-APIKEY": "<api-key>",
"X-TXC-PAYLOAD": "<api-key>",
"X-TXC-SIGNATURE": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-TXC-APIKEY': '<api-key>',
'X-TXC-PAYLOAD': '<api-key>',
'X-TXC-SIGNATURE': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
ticker: 'ETH',
amount: '0.9',
address: '0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c',
uniqueId: '24529041',
request: '{{request}}',
nonce: 1594297865000
})
};
fetch('https://whitebit.com/api/v4/main-account/withdraw-pay', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://whitebit.com/api/v4/main-account/withdraw-pay",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'ticker' => 'ETH',
'amount' => '0.9',
'address' => '0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c',
'uniqueId' => '24529041',
'request' => '{{request}}',
'nonce' => 1594297865000
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-TXC-APIKEY: <api-key>",
"X-TXC-PAYLOAD: <api-key>",
"X-TXC-SIGNATURE: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://whitebit.com/api/v4/main-account/withdraw-pay"
payload := strings.NewReader("{\n \"ticker\": \"ETH\",\n \"amount\": \"0.9\",\n \"address\": \"0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c\",\n \"uniqueId\": \"24529041\",\n \"request\": \"{{request}}\",\n \"nonce\": 1594297865000\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-TXC-APIKEY", "<api-key>")
req.Header.Add("X-TXC-PAYLOAD", "<api-key>")
req.Header.Add("X-TXC-SIGNATURE", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://whitebit.com/api/v4/main-account/withdraw-pay")
.header("X-TXC-APIKEY", "<api-key>")
.header("X-TXC-PAYLOAD", "<api-key>")
.header("X-TXC-SIGNATURE", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"ticker\": \"ETH\",\n \"amount\": \"0.9\",\n \"address\": \"0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c\",\n \"uniqueId\": \"24529041\",\n \"request\": \"{{request}}\",\n \"nonce\": 1594297865000\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://whitebit.com/api/v4/main-account/withdraw-pay")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-TXC-APIKEY"] = '<api-key>'
request["X-TXC-PAYLOAD"] = '<api-key>'
request["X-TXC-SIGNATURE"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"ticker\": \"ETH\",\n \"amount\": \"0.9\",\n \"address\": \"0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c\",\n \"uniqueId\": \"24529041\",\n \"request\": \"{{request}}\",\n \"nonce\": 1594297865000\n}"
response = http.request(request)
puts response.read_body- When creating a base withdraw with amount = 100 USD, the receiver receives 100 USD minus the fee, and the balance decreases by 100 USD.
- When calling the endpoint with amount = 100 USD, the receiver receives 100 USD, and the balance decreases by 100 USD + fee amount.
Used in these guides
- Crypto-as-a-Service integration — paying out an exact amount, with the fee charged on top.
Authorizations
Body
Currencies ticker. Example: BTC. Currencies ticker must have "can_withdraw" status equal to "true". Use Asset Status endpoint to know more about currency.
"ETH"
Withdraw amount (including fee). To add the fee to the specified amount, use the /main-account/withdraw-pay request
"0.9"
Target address: wallet address for cryptocurrencies, account identifier or IBAN for fiat bank rails, or the card token for VISAMASTER. Do not send a card number (PAN). Obtain the card token with Issue card token.
"0x0964A6B8F794A4B8d61b62652dB27ddC9844FB4c"
Required if currency is memoable. See memo for details.
"48565488244493"
Fiat currency provider. Example: VISAMASTER ⚠️ Currency provider should be taken from Asset Status endpoint response. Required if currency is fiat.
"VISAMASTER"
Cryptocurrency network. Available for multinetwork currencies. Example: OMNI ⚠️ Currency network should be taken from Asset Status endpoint response. Default for USDT is ERC20
"ERC20"
Optional parameter for FIAT withdrawals with increased Maximum Limit if set as "true". To use this parameter, the application must support "Partially successful" withdrawal status and latest updates in deposit/withdrawal history.
false
Beneficiary information data. Required if currency ticker is USD or EUR.
Travel Rule information data. Required if currency is crypto and the account is from EEA
Response
Validation succeeded and withdraw creation process is started. Check the request status by uniqueId in deposit/withdraw history.
When two withdrawals compete for the same balance and one fails processing, that withdrawal is retried; if processing still fails, the withdrawal ends as canceled (status 4) and withdraw.canceled is sent.
Was this page helpful?