Skip to main content

Convert Quote

ConvertQuote

GET /viewer/quote

Description

Calculate the price by passing the quantity rfq_size of from_asset and the target asset to_asset

Request

Request Parameters

NameTypeRequireDescriptionExample
from_assetstringtrueasset symbol"USDT"
to_assetstringtrueasset symbol"BTC"
rfq_sizedecimaltruerequest for quotation size"333"
rfq_size_assetstringtruerequest for quotation size asset"USDT"
  • support two http parameter transmission methods: application/json and query params
  • from_asset, to_asset, rfq_size, and rfq_size_asset should all be sent, and from_asset cannot be the same as to_asset
  • rfq_size_asset needs to be the same as either from_asset or to_asset to quote the price
  • if rfq_size_asset is the same as from_asset, rfq_size needs to be within the [from_asset_min_amount,from_asset_max_amount] range returned by the ConvertRange interface
  • if rfq_size_asset is the same as to_asset, rfq_size needs to be within the [to_asset_min_amount, to_asset_max_amount] range returned by the ConvertRange interface

Response

{
"from_asset": "USDT",
"to_asset": "BTC",
"px": "0.00000962",
"from_sz": "333",
"to_sz": "0.00320533",
"quote_id": "dd5091d4-1e90-48b3-83bc-bea1312660ab",
"quote_ts": 1747208733939,
"ttl_ms": 10000,
"rfq_size": "333",
"rfq_size_asset": "USDT"
}

Response Description

Attribute NameTypeDescriptionExample
from_assetstringasset symbol"USDT"
to_assetstringasset symbol"BTC"
pxdecimalprice"0.00000962"
from_szdecimalfrom size"333"
to_szdecimalto size"0.00320533"
quote_idstringconvert maker quote id"dd5091d4-1e90-48b3-83bc-bea1312660ab"
quote_tsnumberconvert maker quote timestamp1747208733939
ttl_msnumberconvert maker quote validity period10000
rfq_sizedecimalrequest for quotation size"333"
rfq_size_assetstringrequest for quotation asset"USDT"