周
根据服务、资产与周期选择本接口。先核对请求参数,再用响应字段和单位解释结果。
查询指数周线行情。tradedate 为周线周期结束交易日;不传日期时返回最新周线周期。
接口名称 index_weekly
请求方法 POST /api
- https://sz.meoz.cn:6688
- https://sh.meoz.cn:6688
返回字段
| 字段 | 名称 | 类型 | 描述 | 单位 |
|---|---|---|---|---|
| tradedate | 周期结束交易日 | string | 日期格式:YYYYMMDD。 | |
| symbol | 指数代码 | string | 6 位指数代码。 | |
| name | 指数名称 | string|null | 指数简称。 | |
| code | 完整指数代码 | string | 包含市场后缀的指数代码。 | |
| index_type | 指数类型 | string|null | 数据源中的指数类型。 | |
| open | 开盘点位 | number|null | 当前周期的开盘点位;单位:点。 | 点 |
| high | 最高点位 | number|null | 当前周期的最高点位;单位:点。 | 点 |
| low | 最低点位 | number|null | 当前周期的最低点位;单位:点。 | 点 |
| close | 收盘点位 | number|null | 当前周期的收盘点位;单位:点。 | 点 |
| pre_close | 上周期收盘点位 | number|null | 上一周期的收盘点位;单位:点。 | 点 |
| change | 涨跌点位 | number|null | 当前周期收盘点位与上周期收盘点位之差;单位:点。 | 点 |
| pct_chg | 涨跌幅(%) | number|null | 当前周期相对上一周期收盘价或点位的涨跌幅;返回百分数,1 表示 1%,不是 0.01。 | |
| vol | 成交量(手) | number|null | 当前周期累计成交量,单位:手;1 手 = 100 股。 | |
| amount | 成交额(元) | number|null | 当前周期累计成交金额,单位:元。 |
请求
{"content":{"application/json":{"example":{"apikey":"","apiname":"index_weekly","fields":"tradedate,symbol,name,open,high,low,close,pre_close,change,pct_chg,vol,amount","params":{"symbols":"000300","tradedate":"20260724"}},"schema":{"properties":{"apikey":{"default":"","description":"浏览器中的 Test Request 会在发送时自动注入;其他调用请[前往个人中心获取](/console)。","type":"string"},"apiname":{"default":"index_weekly","description":"接口名称","enum":["index_weekly"],"type":"string"},"fields":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"tradedate,symbol,name,open,high,low,close,pre_close,change,pct_chg,vol,amount","description":"| 字段 | 类型 | 名称 | 示例值 | 描述 |\n| --- | --- | --- | --- | --- |\n| `tradedate` | `string` | 周期结束交易日 | `20260724` | 日期格式:YYYYMMDD。 |\n| `symbol` | `string` | 指数代码 | `000300` | 6 位指数代码。 |\n| `name` | `string\\|null` | 指数名称 | `沪深300` | 指数简称。 |\n| `code` | `string` | 完整指数代码 | `000300.SH` | 包含市场后缀的指数代码。 |\n| `index_type` | `string\\|null` | 指数类型 | `综合指数` | 数据源中的指数类型。 |\n| `open` | `number\\|null` | 开盘点位 | `3988.2` | 当前周期的开盘点位;单位:点。 |\n| `high` | `number\\|null` | 最高点位 | `4088.6` | 当前周期的最高点位;单位:点。 |\n| `low` | `number\\|null` | 最低点位 | `3965.8` | 当前周期的最低点位;单位:点。 |\n| `close` | `number\\|null` | 收盘点位 | `4042.18` | 当前周期的收盘点位;单位:点。 |\n| `pre_close` | `number\\|null` | 上周期收盘点位 | `3980.45` | 上一周期的收盘点位;单位:点。 |\n| `change` | `number\\|null` | 涨跌点位 | `61.73` | 当前周期收盘点位与上周期收盘点位之差;单位:点。 |\n| `pct_chg` | `number\\|null` | 涨跌幅(%) | `2.39` | 当前周期相对上一周期收盘价或点位的涨跌幅;返回百分数,1 表示 1%,不是 0.01。 |\n| `vol` | `number\\|null` | 成交量(手) | `482356465` | 当前周期累计成交量,单位:手;1 手 = 100 股。 |\n| `amount` | `number\\|null` | 成交额(元) | `1120062805345` | 当前周期累计成交金额,单位:元。 |"},"params":{"default":{"symbols":"000300","tradedate":"20260724"},"description":"| 参数 | 类型 | 是否必选 | 示例值 | 描述 |\n| --- | --- | --- | --- | --- |\n| `symbols` | `string\\|array` | 可选 | `000300,399001` | 指数代码,支持单个、多个英文逗号分隔或数组。 |\n| `tradedate` | `string` | 可选 | `20260724` | 周期结束交易日,格式:YYYYMMDD;不能与 startdate/enddate 同时传。不传任何日期参数时默认最新周期。 |\n| `startdate` | `string` | 可选 | `20260701` | 区间开始日期,格式:YYYYMMDD;只传 startdate 时查询该日至最新交易日,不能与 tradedate 同时传。 |\n| `enddate` | `string` | 可选 | `20260724` | 区间结束日期,格式:YYYYMMDD;只传 enddate 时按单日查询该日期,不能与 tradedate 同时传;startdate 晚于 enddate 时返回参数错误。 |","properties":{"enddate":{"description":"区间结束日期,格式:YYYYMMDD;只传 enddate 时按单日查询该日期,不能与 tradedate 同时传;startdate 晚于 enddate 时返回参数错误。","example":"20260724","pattern":"^\\d{8}$","type":"string"},"startdate":{"description":"区间开始日期,格式:YYYYMMDD;只传 startdate 时查询该日至最新交易日,不能与 tradedate 同时传。","example":"20260701","pattern":"^\\d{8}$","type":"string"},"symbols":{"description":"指数代码,支持单个、多个英文逗号分隔或数组。","example":"000300,399001","oneOf":[{"description":"单个或多个英文逗号分隔的指数代码","type":"string"},{"description":"指数代码数组","items":{"type":"string"},"type":"array"}]},"tradedate":{"description":"周期结束交易日,格式:YYYYMMDD;不能与 startdate/enddate 同时传。不传任何日期参数时默认最新周期。","example":"20260724","pattern":"^\\d{8}$","type":"string"}},"type":"object"}},"required":["apikey","apiname"],"type":"object"}}},"description":"| 参数 | 类型 | 是否必选 | 固定值 | 描述 |\n| --- | --- | --- | --- | --- |\n| `apiname` | `string` | 必选 | `index_weekly` | 接口名称 |\n| `apikey` | `string` | 必选 | [访问个人中心获取](/console) | 访问密钥 |","required":true}
响应
{"200":{"content":{"application/json":{"schema":{"properties":{"code":{"description":"业务状态码,200 表示成功","example":200,"type":"integer"},"data":{"description":"指数周线行情返回数据","nullable":true,"properties":{"fields":{"description":"返回字段名列表,顺序与 items 中每一列一一对应","example":["tradedate","symbol","name","open","high","low","close","pre_close","change","pct_chg","vol","amount"],"items":{"type":"string"},"type":"array"},"items":{"description":"二维数组数据,每一行代表一条记录,列顺序与 fields 一一对应","example":[["20260724","000300","沪深300",3988.2,4088.6,3965.8,4042.18,3980.45,61.73,1.55,886543210,1286543210987.65]],"items":{"items":{},"type":"array"},"type":"array"}},"required":["fields","items"],"type":"object"},"message":{"description":"响应消息","example":"success","type":"string"}},"required":["code","message","data"],"type":"object"}}},"description":"Successful Response"},"429":{"content":{"application/json":{"schema":{"properties":{"code":{"example":429,"type":"integer"},"data":{"example":null,"nullable":true},"message":{"example":"请求频率超限:daily_auc_detail 接口的调用上限为 3 次/秒,请降低该接口的调用频率,建议 1 秒后重试。","type":"string"}},"required":["code","message","data"],"type":"object"}}},"description":"账户总调用频率或单个重接口调用频率超过当前套餐限额。","headers":{"Retry-After":{"description":"建议等待后重试的秒数。","schema":{"minimum":1,"type":"integer"}}}}}