查詢交割價格
查詢平台交割產品的交割價格,支持反向交割, USDC交割和期權
覆蓋範圍: USDC交割 / 反向交割 / 期權
信息
- 期權: 當不指定symbol時, 僅返回處於交割中狀態的(UTC8~UTC12)的數據
HTTP請求
GET /v5/market/delivery-price
請求參數
參數 | 是否必需 | 類型 | 說明 |
---|---|---|---|
category | true | string | 產品類型. linear , inverse , option |
symbol | false | string | 合約名稱 |
baseCoin | false | string | 交易貨幣. 默認: BTC . 僅支持option |
limit | false | integer | 每頁數量限制. [1 , 200 ]. 默認: 50 |
cursor | false | string | 游標,用於分頁 |
響應參數
參數 | 類型 | 說明 |
---|---|---|
category | string | 產品類型 |
list | array | Object |
> symbol | string | 合約名稱 |
> deliveryPrice | string | 交割價格 |
> deliveryTime | string | 交割時間戳 (毫秒) |
nextPageCursor | string | 游標,用於分頁 |
請求示例
- HTTP
- Python
- GO
- Java
- Node.js
GET /v5/market/delivery-price?category=option&symbol=ETH-26DEC22-1400-C HTTP/1.1
Host: api-testnet.bybit.com
from pybit.unified_trading import HTTP
session = HTTP()
print(session.get_option_delivery_price(
category="option",
symbol="ETH-26DEC22-1400-C",
))
import (
"context"
"fmt"
bybit "github.com/wuhewuhe/bybit.go.api"
)
client := bybit.NewBybitHttpClient("", "", bybit.WithBaseURL(bybit.TESTNET))
params := map[string]interface{}{"category": "linear", "symbol": "ETH-26DEC22-1400-C"}
client.NewUtaBybitServiceWithParams(params).GetDeliveryPrice(context.Background())
import com.bybit.api.client.domain.CategoryType;
import com.bybit.api.client.domain.market.request.MarketDataRequest;
import com.bybit.api.client.service.BybitApiClientFactory;
var client = BybitApiClientFactory.newInstance().newAsyncMarketDataRestClient();
var deliveryPriceRequest = MarketDataRequest.builder().category(CategoryType.OPTION).baseCoin("BTC").limit(10).build();
client.getDeliveryPrice(deliveryPriceRequest, System.out::println);
const { RestClientV5 } = require('bybit-api');
const client = new RestClientV5({
testnet: true,
});
client
.getDeliveryPrice({ category: 'option', symbol: 'ETH-26DEC22-1400-C' })
.then((response) => {
console.log(response);
})
.catch((error) => {
console.error(error);
});
響應示例
{
"retCode": 0,
"retMsg": "success",
"result": {
"category": "option",
"nextPageCursor": "",
"list": [
{
"symbol": "ETH-26DEC22-1400-C",
"deliveryPrice": "1220.728594450",
"deliveryTime": "1672041600000"
}
]
},
"retExtInfo": {},
"time": 1672055336993
}