Skip to content
iTick
  1. 文檔
  2. REST API
  3. 基礎數據
  4. 市場狀態

市場狀態

查詢指定國家或地區的市場當前狀態,返回是否開市、狀態、交易時段、時區和當地時間。

市場狀態查詢

GET/market/status

請求參數

codeenum必填

國家/地區代碼

回應參數

codenumber

回應代碼

msgstring

回應描述

dataarray(object)▶回應結果
cstring

國家/地區代碼

rstring

國家/地區名稱

ostring

是否開市

sstring

市場狀態;`PRE_MARKET` 盤前,`OPEN` 盤中,`LUNCH_BREAK` 盤中休盤(如午休),`POST_MARKET` 盤後,`CLOSED` 非交易時段,`CLOSED_WEEKEND` 週末休市,`CLOSED_HOLIDAY` 假期休市,`HOLIDAY_HALF_DAY` 假期半日市開市中

hstring

當天假期名稱,僅在 `status = CLOSED_HOLIDAY / HOLIDAY_HALF_DAY` 時有值

tstring

交易時段配置

zstring

時區編碼

lstring

當前地區本地時間,格式 `yyyy-MM-dd HH:mm:ss`

程式碼範例

import requests

url = "https://api.itick.org/market/status?code=HK"

headers = {
"accept": "application/json"
"token": "Your Token"
}

response = requests.get(url, headers=headers)

print(response.text)

查詢 URL

GEThttps://api.itick.org/market/status?code=HK

,執行查詢

回應結果

{
  "code": 0,
  "msg": "ok",
  "data": {
    "c": "es",
    "r": "Spain",
    "o": false,
    "s": "CLOSED_WEEKEND",
    "h": null,
    "t": "08:00-09:00,09:00-17:30,",
    "z": "Europe/Madrid",
    "l": "2026-07-05 18:47:44"
  }
}