获取指数最新分时数据(分钟级别),包括开高低收、成交量、成交额
基本信息
| 项目 | 值 |
| 爬虫名称 | eastmoney_index_intraday |
| 平台 | 东方财富 |
| 版本 | 2.0.0 |
| 作者 | noimank |
请求参数
| 参数名 | 类型 | 必填 | 默认值 | 说明 |
index_code | str | ✓ | - | 指数代码,如 000001(上证指数)、399001(深证成指)、399006(创业板指)、000300(沪深300)、000688(科创50) |
limit | int | ✗ | 0 | 获取最近多少条分时数据,0表示全部 |
data_format | Literal['json', 'dict', 'markdown', 'string'] | ✗ | json | 返回数据格式,可选值:json, dict, string, markdown |
使用示例
API 调用
curl -X POST http://localhost:8380/api/v1/spiders/run -H "Content-Type: application/json" -d '{
"spider_name": "eastmoney_index_intraday",
"params": { ... }
}'
Python SDK
import httpx
async with httpx.AsyncClient() as client:
resp = await client.post(
"http://localhost:8380/api/v1/spiders/run",
json={
"spider_name": "eastmoney_index_intraday",
"params": { ... }
}
)
result = resp.json()
返回格式
{
"success": true,
"message": "执行成功",
"data": { ... },
"execution_time": 1.23
}