Skip to main content
POST
/
api
/
v4
/
convert
/
estimate
curl --request POST \ --url https://whitebit.com/api/v4/convert/estimate \ --header 'Content-Type: application/json' \ --header 'X-TXC-APIKEY: <api-key>' \ --header 'X-TXC-PAYLOAD: <api-key>' \ --header 'X-TXC-SIGNATURE: <api-key>' \ --data ' { "amount": "35,103.1", "direction": "to", "from": "BTC", "to": "USDT" } '
{ "id": "123", "from": "BTC", "to": "USDT", "give": "50", "receive": "1714988.41577452", "rate": "34299.76831549", "expireAt": 1699016476 }

Authorizations

X-TXC-APIKEY
string
header
required

The public WhiteBIT API key.

X-TXC-PAYLOAD
string
header
required

Base64-encoded JSON request body.

X-TXC-SIGNATURE
string
header
required

HMAC-SHA512 signature of the payload, hex-encoded. Computed as hex(HMAC-SHA512(payload, api_secret)).

Body

application/json
from
string
required

From currency. Example: BTC

Example:

"BTC"

to
string
required

To currency. Example: USDT

Example:

"USDT"

direction
enum<string>
required

Convert amount direction, defines in which currency corresponding "amount" field is populated. Use "to" in case amount is in "to" currency, use "from" if amount is in "from" currency

Available options:
from,
to
Example:

"to"

amount
string
required

Amount to convert or receive.

Example:

"35,103.1"

nonce
integer

Nonce for request

Example:

1699260637

request
string

Request path

Example:

"{{request}}"

Response

Successful response

id
string

Quote ID

Example:

"123"

from
string

From currency

Example:

"BTC"

to
string

To currency

Example:

"USDT"

give
string

Amount to give

Example:

"50"

receive
string

Amount to receive

Example:

"1714988.41577452"

rate
string

Conversion rate expressed in the from→to direction: units of the 'to' currency received per one unit of the 'from' currency. Example: if from=BTC and to=USDT, a rate of "34299.76" means 1 BTC is worth approximately 34 299.76 USDT at the time of the quote.

Example:

"34299.76831549"

expireAt
integer

Quote expiration timestamp

Example:

1699016476