Skip to content

Trading Days

GET /api/v1.0/quote/trading-days

Get the trading calendar for a specified market within a date range.

Parameters

NameTypeInRequiredDescription
marketstringqueryyesMarket code, e.g. HK, US, SH. See Naming Dictionary.
startstringqueryyesStart date (yyyy-MM-dd).
endstringqueryyesEnd date (yyyy-MM-dd).

Request Example

bash
curl 'https://webapi.moomoo.com/api/v1.0/quote/trading-days?market=HK&start=2026-04-22&end=2026-05-22' | jq

Response Fields

Returns data.trading_days[], one element per trading day. Non-trading days (full-day closures, weekends, special holidays) are filtered out.

FieldTypeDescription
timestringTrading date, format yyyy-MM-dd
trade_date_typestringTrading day type. See Naming Dictionary > trade_date_type
trade_secondintTotal trading seconds for the day; used to identify half-day sessions and shortened trading (e.g. HK Christmas Eve approx. 9000s)

Supported Markets

  • Markets: HK / US / SH / SZ / BJ / SG / JP / CA / AU / JP_FUTURE / SG_FUTURE
  • No category distinction (returns the trading calendar for the market as a whole)
  • Both start and end are inclusive; full-day closures, weekends, and special holidays are implicitly filtered

Error Codes

ret_codeerror.codeTrigger ConditionRecommended Action
-3invalid_parameterMissing market/start/end; market not in enum; start/end not in yyyy-MM-dd format; start > endCorrect parameters and retry
-4 / -6internal_errorGateway internal error (request construction / response conversion failed)Retry; contact support if persistent

Response Example

json
{
  "ret_code": 0,
  "ret_msg": "success",
  "data": {
    "trading_days": [
      {"time": "2025-12-22", "trade_date_type": "WHOLE", "trade_second": 19800},
      {"time": "2025-12-23", "trade_date_type": "WHOLE", "trade_second": 19800},
      {"time": "2025-12-24", "trade_date_type": "MORNING", "trade_second": 9000}
    ]
  }
}