# 同花顺板块列表

- 接口：ths_board_list
- 路径：/api/v1/market/data/ths-board-list
- 方法：GET
- 描述：获取同花顺全部板块列表，含**概念 / 行业 / 地区 / 证监会（csrc）**四类模块。返回数组（非分页），当前在线约 493 个板块（概念 351 / 行业 90 / 地区 33 / csrc 19）。每项含板块代码（如 886056）、板块名称、所属模块。
- 数据范围：无时间维度，实时/最新快照
- 单次限量：无入参、无分页，一次返回全部板块
- 提示：
  - 无入参，直接 GET 即可。
  - `csrc`（证监会行业分类）模块**无 K 线数据**，调用 K 线接口会被拒。
  - 板块代码在不同模块间不重复，可用作唯一键。

## 输入参数

无。


## 输出参数
成功响应外层固定为 `code`、`message`、`data`：

| 名称 | 类型 | 默认显示 | 描述 |
|------|------|---------|------|
| code | integer | Y | HTTP 状态码；成功固定为 200 |
| message | string | Y | 成功固定为 `success`；失败时为中文错误信息 |
| data | array / null | Y | 成功时为业务数据数组；失败时为 `null`。 |


data 数组：

| 名称 | 类型 | 默认显示 | 描述 |
|------|------|---------|------|
| module | string | Y | 板块模块：concept / csrc / industry / region |
| code | string | Y | 板块代码，如 886056 |
| name | string | Y | 板块名称（中文） |

## 接口示例

```bash
curl -sS "https://market.ft.tech/gateway/api/v1/market/data/ths-board-list"
```

Python（[`ftshare`](https://github.com/FTShare-Lab/FTShare-python-sdk.git) SDK，方法 `market.ths_board_list`，默认返回 pandas `DataFrame`）：

```python
import ftshare as ft

market = ft.market_api()

# 默认返回 DataFrame（无入参，返回全部同花顺板块代码表）
df = market.ths_board_list()
print(df.shape, list(df.columns))
# (493, 3) ['module', 'code', 'name']
print(df.head(5))
#     module  code    name
# 0  concept  886056  阿尔茨海默概念
# 1  concept  886071  AI PC
# 2  concept  886070  AI手机
# 3  concept  885531  光伏概念

# module 取值：concept / industry / region / csrc
print(df["module"].value_counts())

# 返回 Python 列表（as_dataframe=False）
rows = market.ths_board_list(as_dataframe=False)
```

## 数据样例

| module | code | name |
|--------|------|------|
| concept | 886056 | 阿尔茨海默概念 |
| concept | 886071 | AI PC |
| concept | 885525 | 白酒概念 |
| concept | 885789 | 宁德时代概念 |
| industry | 881101 | ... |
| region | 886001 | ... |
| csrc | 885001 | ... |
| ... | ... | ... |
