Skip to main content

Convert Guideline

info
  • All convert api need authentication
  • API key permission: "Exchange"

Workflow

Step1 Get Convert Coin List

  • Query the supported coin list of convert from / to in the different account types.
  • The balance is also given when querying the convert from coin list.

Step2 Request a Quote

  • Select fromCoin, toCoin, acccountType, define the qty of fromCoin to get a quote
  • There is balance pre-check at this stage.

Step3 Confirm a Quote

  • Confirm your quote in the valid time slot (15 secs). Once confirmed, the system processes your transactions.
  • This operation is async, so it can be failed if you have funds transferred out. Please check the transaction result by step 4.

Step4 Get Convert Status

Check the final status of the coin convert.

Error

CodeMsgComment
790000system error, please try again later
700000parameter error
700001quote fail: no deler can be used
700002quote fial: not support quote typewhen requestCoin=toCoin during request quote stage
700003order status not allowed
700004order does not exit1. check if quoteTxId is correct; 2. check if quoteTxId is matched with accountType
700005Your available balance is insufficient or wallet does not exist
700006Low amount limitthe request amount cannot be smaller than minFromCoinLimit
700007Large amount limitthe request amount cannot be larger than maxFromCoinLimit
700008quote fail: price time out1. the quote is expired; 2. The quoteTxId does not exist
700009quoteTxId has already been usedget this error when you call confirm quote more than once before expiry time
700010INS loan user cannot perform conversion
700011illegal operationwhen request a quote with user A, but confirm the quote with user B

API Rate Limit

MethodPathLimitUpgradable
GET/v5/asset/exchange/query-coin-list100 req/sN
POST/v5/asset/exchange/quote-apply50 req/sN
POST/v5/asset/exchange/convert-execute50 req/sN
GET/v5/asset/exchange/convert-result-query100 req/sN
GET/v5/asset/exchange/query-convert-history100 req/sN