指数基本信息/指数日线/成分权重/行业分类/行业成分,共 5 个实体
注意:index_basic 与 index_daily 的指数代码列名为 ts_code,其余实体为 index_code。行业链路:index_classify → index_member → index_daily。
指数清单:名称、市场、发布方、类别、基日、基点。
当前 market 仅有 SSE / SZSE / CSI 三种取值,其他市场筛选会返回空结果。
GET /api/v1/entities/index_basic
| 参数 | 类型 | 说明 |
|---|---|---|
market | string | 市场筛选。 |
| 字段 | 类型 | 说明 |
|---|---|---|
ts_code | string | 指数代码 |
name | string | 指数名称 |
market | string | 市场 |
publisher | string | 发布方 |
category | string | 类别 |
base_date | string | 基日 |
base_point | float64 | 基点 |
list_date | string | 上市日 |
{
"entity": "index_basic",
"data_version": "2026-08-14T22:50:21+00:00",
"columns": [{"name": "ts_code", "dtype": "string"}, {"name": "name", "dtype": "string"}, {"name": "market", "dtype": "string"}, {"name": "publisher", "dtype": "string"}, {"name": "category", "dtype": "string"}, {"name": "base_date", "dtype": "string"}, {"name": "base_point", "dtype": "float64"}, {"name": "list_date", "dtype": "string"}],
"rows": [["000001.SH", "上证指数", "SSE", "中证指数有限公司、上海证券交易所", "综合指数", "19901219", 100.0, "19910715"]],
"count": 1,
"truncated": false,
"next_cursor": null
}
import requests
r = requests.get(f"{BASE}/api/v1/entities/index_basic",
params={"limit": 10},
headers={"Authorization": f"Bearer {TOKEN}"})
d = r.json()
print(d["columns"], d["rows"][0])
全市场指数日线(含行业指数),基准对比与行业指数行情。
GET /api/v1/entities/index_daily
| 字段 | 类型 | 说明 |
|---|---|---|
ts_code | string | 指数代码 |
trade_date | string | 交易日期 YYYYMMDD |
close | float64 | 收盘点位 |
open | float64 | 开盘点位 |
high | float64 | 最高点位 |
low | float64 | 最低点位 |
pre_close | float64 | 昨收点位 |
change | float64 | 涨跌点 |
pct_chg | float64 | 涨跌幅(%) |
vol | float64 | 成交量 |
amount | float64 | 成交额 |
{
"entity": "index_daily",
"data_version": "2026-08-14T22:50:21+00:00",
"columns": [{"name": "ts_code", "dtype": "string"}, {"name": "trade_date", "dtype": "string"}, {"name": "close", "dtype": "float64"}, {"name": "open", "dtype": "float64"}, {"name": "high", "dtype": "float64"}, {"name": "low", "dtype": "float64"}, {"name": "pre_close", "dtype": "float64"}, {"name": "change", "dtype": "float64"}, {"name": "pct_chg", "dtype": "float64"}, {"name": "vol", "dtype": "float64"}, {"name": "amount", "dtype": "float64"}],
"rows": [["000001.SH", "20090105", 1880.716, 1849.02, 1880.716, 1844.094, 1820.805, 59.911, 3.2904, 67136715.0, 46100959.083]],
"count": 1,
"truncated": false,
"next_cursor": null
}
import requests
r = requests.get(f"{BASE}/api/v1/entities/index_daily",
params={"limit": 10},
headers={"Authorization": f"Bearer {TOKEN}"})
d = r.json()
print(d["columns"], d["rows"][0])
宽基成分权重(宽基每日/行业周五更新)。
GET /api/v1/entities/index_weight
| 字段 | 类型 | 说明 |
|---|---|---|
index_code | string | 指数代码 |
con_code | string | 成分股代码 |
trade_date | string | 交易日期 |
weight | float64 | 权重 |
{
"entity": "index_weight",
"data_version": "2026-08-14T22:50:21+00:00",
"columns": [{"name": "index_code", "dtype": "string"}, {"name": "con_code", "dtype": "string"}, {"name": "trade_date", "dtype": "string"}, {"name": "weight", "dtype": "float64"}],
"rows": [["000016.SH", "600000.SH", "20090430", 5.02]],
"count": 1,
"truncated": false,
"next_cursor": null
}
import requests
r = requests.get(f"{BASE}/api/v1/entities/index_weight",
params={"limit": 10},
headers={"Authorization": f"Bearer {TOKEN}"})
d = r.json()
print(d["columns"], d["rows"][0])
申万 L1/L2/L3 行业分类体系。
GET /api/v1/entities/index_classify
| 参数 | 类型 | 说明 |
|---|---|---|
level | string | 行业级别(L1/L2/L3)。 |
| 字段 | 类型 | 说明 |
|---|---|---|
index_code | string | 行业代码 |
industry_name | string | 行业名称 |
level | string | 级别(L1/L2/L3) |
industry_code | string | 行业代码 |
is_pub | string | 是否发布 |
parent_code | string | 父级代码 |
src | string | 来源 |
{
"entity": "index_classify",
"data_version": "2026-08-14T22:50:21+00:00",
"columns": [{"name": "index_code", "dtype": "string"}, {"name": "industry_name", "dtype": "string"}, {"name": "level", "dtype": "string"}, {"name": "industry_code", "dtype": "string"}, {"name": "is_pub", "dtype": "string"}, {"name": "parent_code", "dtype": "string"}, {"name": "src", "dtype": "string"}],
"rows": [["801010.SI", "农林牧渔", "L1", "110000", "1", "0", "SW2021"]],
"count": 1,
"truncated": false,
"next_cursor": null
}
import requests
r = requests.get(f"{BASE}/api/v1/entities/index_classify",
params={"limit": 10},
headers={"Authorization": f"Bearer {TOKEN}"})
d = r.json()
print(d["columns"], d["rows"][0])
成分股进出场记录,行业中性化/持仓行业暴露基础。
GET /api/v1/entities/index_member
| 参数 | 类型 | 说明 |
|---|---|---|
as_of | YYYYMMDD | point-in-time 锚点:只返回 公告日 <= as_of 的行,防未来函数(强烈建议显式传)。 |
| 字段 | 类型 | 说明 |
|---|---|---|
index_code | string | 行业指数代码 |
con_code | string | 成分股代码 |
in_date | string | 纳入日期 |
out_date | string | 剔除日期(空表示仍为成分) |
is_new | string | 是否新纳入 |
{
"entity": "index_member",
"data_version": "2026-08-14T22:50:21+00:00",
"columns": [{"name": "index_code", "dtype": "string"}, {"name": "con_code", "dtype": "string"}, {"name": "in_date", "dtype": "string"}, {"name": "out_date", "dtype": "string"}, {"name": "is_new", "dtype": "string"}],
"rows": [["801010.SI", "000019.SZ", "20211213", null, "Y"]],
"count": 1,
"truncated": false,
"next_cursor": null
}
import requests
r = requests.get(f"{BASE}/api/v1/entities/index_member",
params={"limit": 10},
headers={"Authorization": f"Bearer {TOKEN}"})
d = r.json()
print(d["columns"], d["rows"][0])