行业排行榜
按市场和指标获取行业排行榜。返回的 Counter ID 可直接传入 industry_peers 查询子行业树。
SDK Links
Python | longport.openapi.FundamentalContext.industry_rank |
Rust | longport::fundamental::FundamentalContext#industry_rank |
Go | FundamentalContext.IndustryRank |
Node.js | FundamentalContext#industryRank |
Parameters
SDK 方法参数。
| Name | Type | Required | Description |
|---|---|---|---|
| market | string | 是 | 市场代码:US / HK / CN / SG |
| indicator | string | 是 | 排行指标:leading-gainer / today-trend / popularity / market-cap / revenue / revenue-growth / net-profit / net-profit-growth |
| sort_type | string | 是 | 排序方式:single(单一排序)/ multi(多维排序) |
| limit | uint32 | 是 | 返回条数,默认 20 |
Request Example
Response
Response Example
json
{
"code": 0,
"message": "success",
"data": {
"items": [
{
"lists": [
{
"name": "Technology",
"counter_id": "BK/US/IN00258",
"chg": "0.0231",
"leading_name": "NVIDIA",
"leading_ticker": "NVDA.US",
"leading_chg": "0.0512",
"value_name": "",
"value_data": ""
}
]
}
]
}
}Response Status
| Status | Description | Schema |
|---|---|---|
| 200 | 成功 | IndustryRankResponse |
| 400 | 请求错误 | None |
Schemas
IndustryRankResponse
| Name | Type | Required | Description |
|---|---|---|---|
| items | object[] | 否 | 排行分组列表 |
| ∟ lists | object[] | 否 | 行业条目列表 |
| ∟ ∟ name | string | 否 | 行业名称 |
| ∟ ∟ counter_id | string | 否 | 行业唯一标识(BK/市场/ID 格式),可直接传入 industry_peers |
| ∟ ∟ chg | string | 否 | 当日涨跌幅(小数) |
| ∟ ∟ leading_name | string | 否 | 涨幅领先个股名称 |
| ∟ ∟ leading_ticker | string | 否 | 涨幅领先个股代码 |
| ∟ ∟ leading_chg | string | 否 | 涨幅领先个股涨跌幅(小数) |
| ∟ ∟ value_name | string | 否 | 指标名称(按指标类型填充,可能为空) |
| ∟ ∟ value_data | string | 否 | 指标数值(可能为空) |