Skip to content

組合期權詢價 ​

POST /api/v1.0/quote/combo-option-quote

按調用方給出的組合腿(合約 + BUY/SELL + 數量)獲取組合報價。side 必須由調用方傳入,不會根據策略類型推斷。 返回每組的 price / bid_price / ask_price / bid_volume / ask_volume / volume / turnover / last_close_price(價格和成交額均爲實際金額),並回顯 legs。 不返回 Greeks、IV、盈虧平衡點或 OHLC 數據。 支持美股和港股期權合約。美股備兌組合可包含一條標的正股腿(如 US.AAPL BUY 100)。港股不支持正股腿(擔保策略),返回 -8。單個組合的錯誤通過 item.rsp_code 返回。 實時行情,需登錄且該市場有實時權限。

請求參數 ​

參數類型位置必填說明
combo_liststring請求體是組合列表。每元素一套組合,腿在 legs[]。美股/港股期權合約;美股備兌可再帶一條標的正股。港股不可帶正股。一組最多一條正股腿,同組市場必須相同。

請求示例 ​

bash
curl -X POST 'https://webapi.moomoo.com/api/v1.0/quote/combo-option-quote' -H 'Content-Type: application/json' -d '{}' | jq

響應字段 ​

參數類型說明
data.quote_listobject[]
data.quote_list[].rsp_codestring單組詢價結果碼,0=成功
data.quote_list[].legsstring回顯的請求腿(code / side / quantity)
data.quote_list[].pricestring組合市價(实际价格)
data.quote_list[].bid_pricestring買一價(实际价格)
data.quote_list[].ask_pricestring賣一價(实际价格)
data.quote_list[].bid_volumestring買一量
data.quote_list[].ask_volumestring賣一量
data.quote_list[].volumestring組合成交量
data.quote_list[].turnoverstring組合成交額
data.quote_list[].last_close_pricestring昨收價(实际价格)

錯誤碼 ​

ret_codeerror.code說明
0—成功
-3invalid_parameter參數缺失或不在允許範圍內
-7invalid_symbol標的在證券庫中不存在
-8unsupported市場或品類不在本接口範圍內
-9permission_denied已登錄但沒有對應行情權限
-10no_data當前沒有可返回的數據
-11rate_limited調用過於頻繁

響應示例 ​

json
{
  "ret_code": 0,
  "ret_msg": "success",
  "data": {
    "quote_list": [
      {
        "rsp_code": "example",
        "legs": "example",
        "price": "example",
        "bid_price": "example",
        "ask_price": "example",
        "bid_volume": "example",
        "ask_volume": "example",
        "volume": "example",
        "turnover": "example",
        "last_close_price": "example"
      }
    ]
  }
}