Skip to content
Indexes and Sectors

Get Index Constituents

Returns the constituents of an index with quote summaries (last price, change, net capital inflow, turnover, turnover rate, market capitalization, and more), paginated and sorted by an indicator. Use it for the Constituents list on the index detail page. Paginate with offset and limit: pass 0 as offset for the first page and add limit for each further page. Stop loading when the number of loaded items reaches total.

GEThttps://api.lbkrs.com/v2/discovery/index-constituents

Parameters

counter_idstringqueryRequired

Security ID (counter_id) of the index, such as IX/HK/HSTECH

offsetintegerqueryRequired

Offset, starting from 0

limitintegerqueryRequired

Number of items per page. Broker App passes 200

indicatorintegerquery

Sort indicator:

  • 1 - Change percentage (default)
  • 2 - Last price
  • 3 - Turnover
  • 4 - Capital flow
  • 5 - Turnover rate
  • 6 - Market capitalization

For indexes without quotes, Broker App always passes 12.

orderintegerquery

Sort direction:

  • 0 - Descending (default)
  • 1 - Ascending

01

sort_typeintegerquery

Legacy sort mode, superseded by indicator and order. Broker App always passes 0:

  • 0 - Change, high to low
  • 1 - Change, low to high
  • 2 - Last price, high to low
  • 3 - Last price, low to high

0123

bmpbooleanquery

Whether the current user receives Hong Kong BMP (snapshot) quotes

Responses

HTTP 200The request succeeded. The response body contains the result of the “Get Index Constituents” operation.
Standard response envelopecodemessagedata
dataobjectdata structure
totalinteger

Total number of constituents

stocksarray<object>

Constituents on the current page

Child attributes
counter_idstring

Security ID of the constituent

namestring

Security name

marketstring

Market, such as HK or US

last_donestring

Last price

prev_closestring

Previous close

chgstring

Change percentage

inflowstring

Net capital inflow

balancestring

Turnover

amountstring

Volume

turnover_ratestring

Turnover rate

market_capstring

Market capitalization

total_sharesstring

Total shares

circulating_sharesstring

Shares in circulation

extend_stateinteger

Extended-hours state:

  • 0 - Regular session
  • 1 - Pre-market
  • 2 - After-hours
Values
0
1
2
extend_pricestring

Last price in pre-market or after-hours trading

extend_chgstring

Change percentage in pre-market or after-hours trading

Whale Docs