Skip to content

Contracts under an event ​

GET /api/v1.0/quote/event-contract/contracts

Contracts under an event, plus recommended contracts. event is required, e.g. KS.KXNFLGAME-26SEP12PITNE. offset+count, count default 100 (max 1000). Returns contract_code / volume / status / is_tie; data.recommend_contracts are recommended KS symbols.

Parameters ​

NameTypeInRequiredDescription
eventstringqueryyesEvent symbol, e.g. KS.KXNFLGAME-26SEP12PITNE
page_flagstringquerynoPage cursor. Omit or pass empty on the first page; pass back pagination.page_flag. Stop only when pagination.completed is true
page_sizeintquerynoPage size, default 100, max 1000
milestonestringquerynoOptional milestone symbol; when set, returns contracts related to that milestone

Example ​

bash
curl -X GET 'https://webapi.moomoo.com/api/v1.0/quote/event-contract/contracts?event=value' \
  -H 'Authorization: Bearer <AccessToken>' | jq

Response parameters ​

NameTypeDescription
data.contractsobject[]
data.contracts[].contract_codestringContract symbol, e.g. KS.KXNFLGAME-26SEP12PITNE-PIT
data.contracts[].titlestringContract title
data.contracts[].volumestringContract volume (high-precision string)
data.contracts[].statusintContract status code
data.contracts[].is_tieboolWhether this is a tie contract
data.recommend_contractsstring[]Recommended KS contract symbols, up to about 3
pagination.totalint
pagination.completedboolTrue when this is the last page. Stop paging only when completed is true
pagination.page_flagstringNext page cursor. Pass it back as page_flag while completed is false; empty on the last page

Errors ​

ret_codeerror.codeDescription
0—Success
-3invalid_parameterMissing or invalid parameter
-8unsupportedNot supported
-10no_dataNo data

Response example ​

json
{
  "ret_code": 0,
  "ret_msg": "success",
  "data": {
    "contracts": [
      {
        "contract_code": "example",
        "title": "example",
        "volume": "example",
        "status": 0,
        "is_tie": false
      }
    ],
    "recommend_contracts": ["KS.example.CONTRACT"]
  },
  "pagination": {
    "page_flag": "",
    "completed": true,
    "total": 0
  }
}