確認報價
信息
- 該接口是異步的, 請通過查詢請求確認最終兌換結果
- 確保您在報價單過期前確認該報價, 否則失效
HTTP 請求
POST /v5/asset/exchange/convert-execute
請求參數
參數 | 是否必需 | 類型 | 說明 |
---|---|---|---|
quoteTxId | true | string | 報價單ID, 來自於提交報價的響應 |
響應參數
參數 | 類型 | 說明 |
---|---|---|
quoteTxId | string | 報價單ID |
exchangeStatus | string | 兌換狀態 |
請求示例
- HTTP
- Python
- Node.js
POST /v5/asset/exchange/convert-execute HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN: XXXXXX
X-BAPI-API-KEY: XXXXXX
X-BAPI-TIMESTAMP: 1720071899789
X-BAPI-RECV-WINDOW: 5000
Content-Type: application/json
Content-Length: 52
{
"quoteTxId": "10100108106409343501030232064"
}
const { RestClientV5 } = require('bybit-api');
const client = new RestClientV5({
testnet: true,
key: 'apikey',
secret: 'apisecret',
});
client
.confirmConvertQuote({
quoteTxId: '10100108106409343501030232064',
})
.then((response) => {
console.log(response);
})
.catch((error) => {
console.error(error);
});
響應示例
{
"retCode": 0,
"retMsg": "ok",
"result": {
"exchangeStatus": "processing",
"quoteTxId": "10100108106409343501030232064"
},
"retExtInfo": {},
"time": 1720071900529
}