期货行情
期货行情提供合约当日分时和历史日 K 数据。
通用约定
- Base URL:
https://fuyao.aicubes.cn。 - 必需请求头:
X-api-key;认证与权限错误通过业务code表达。 - 期货合约使用完整
thscode,品种代码使用大写形式;接口返回统一ApiResponse信封。 - ISO 日期按
Asia/Shanghai解释,Unix 时间戳为毫秒。金融数值与日期来源缺失时可为null,合法无数据时返回[]。
期货当日分时
GET /api/futures/prices/intraday
MCP Tool:get_futures_prices_intraday
请求参数
| 参数 | 类型 | 必需 | 默认值 | 说明 |
|---|---|---|---|---|
thscode | string | 是 | — | 期货合约完整同花顺代码。 |
session | enum | 否 | — | pre_market、intraday 或 post_market;省略时使用 intraday。 |
请求示例
curl 'https://fuyao.aicubes.cn/api/futures/prices/intraday?thscode=CU2601.SHF&session=intraday' \
-H 'X-api-key: <your-api-key>'
响应示例
{
"code": 0,
"message": "success",
"request_id": "request-id",
"data": {
"timestamp": 1789036800000,
"thscode": "CU2601.SHF",
"date": "2026-09-10",
"session": "intraday",
"item": [
{
"timestamp": 1789036860000,
"price": 78200,
"volume": 12,
"turnover": 4692000
}
]
}
}
返回字段
| 字段 | 类型 | 说明 |
|---|---|---|
timestamp | long | 数据时间。 |
thscode / date / session | string | 合约代码、交易日期与会话。 |
item[] | array | 分时点;每项含可空的 timestamp、price、volume、turnover。 |
期货日K
GET /api/futures/prices/daily
MCP Tool:get_futures_prices_daily
请求参数
| 参数 | 类型 | 必需 | 默认值 | 说明 |
|---|---|---|---|---|
thscode | string | 是 | — | 期货合约完整同花顺代码。 |
start | long | 否 | — | 与 end 成对提供的正毫秒时间戳;两者均省略时查询最近 100 根。 |
end | long | 否 | — | 与 start 成对提供,且不早于 start。 |
请求示例
curl 'https://fuyao.aicubes.cn/api/futures/prices/daily?thscode=CU2601.SHF' \
-H 'X-api-key: <your-api-key>'
响应示例
{
"code": 0,
"message": "success",
"request_id": "request-id",
"data": {
"timestamp": 1789036800000,
"thscode": "CU2601.SHF",
"interval": "1d",
"item": [
{
"timestamp": 1788950400000,
"open_price": 78000,
"high_price": 78400,
"low_price": 77800,
"close_price": 78200,
"volume": 120000,
"turnover": 46920000000
}
]
}
}
返回字段
| 字段 | 类型 | 说明 |
|---|---|---|
timestamp | long | 数据时间。 |
thscode | string | 期货合约代码。 |
interval | string | 固定为 1d。 |
item[] | array | 日 K;每项含可空的 timestamp、open_price、high_price、low_price、close_price、volume、turnover。 |