宏观指标图表点
GET/api/v1.0/quote/macro/indicator-chart获取宏观指标图表点。period 为周期代码,默认 1。
请求参数
| 参数 | 类型 | 位置 | 必填 | 说明 |
|---|---|---|---|---|
indicator_id | int | 查询 | 是 | 宏观指标 ID |
period | int | 查询 | 否 | 图表周期,周期代码,默认 1 |
请求示例
bash
curl -X GET 'https://webapi.moomoo.com/api/v1.0/quote/macro/indicator-chart?indicator_id=1' \
-H 'Authorization: Bearer <AccessToken>' | jq响应参数
| 参数 | 类型 | 说明 |
|---|---|---|
data.items | object[] | |
data.items[].data_time | int | 数据日期,Unix 微秒 |
data.items[].release_time | int | 公布时间,Unix 微秒 |
data.items[].value | string | 公布值 |
错误码
| ret_code | error.code | 说明 |
|---|---|---|
| 0 | — | 成功 |
| -3 | invalid_parameter | 参数不合法 |
| -8 | unsupported | 不支持 |
| -10 | no_data | 没有数据 |
响应示例
json
{
"ret_code": 0,
"ret_msg": "success",
"data": {
"items": [
{
"data_time": 1710000000000000,
"release_time": 1710000000000000,
"value": "example"
}
]
}
}