Skip to content

用户 Python 指标目录 ​

GET /api/v1.0/quote/python-indicators/catalog

分页列出当前登录用户全部可见的 Python 指标目录,不含脚本和参数。身份从登录态读取,不支持 uid 参数。获取到 guid 或 short_name 后,再调用查询用户 Python 指标获取脚本与参数。

请求参数 ​

参数类型位置必填说明
start_guidstring查询否分页游标;首页省略或传空串,后续原样回传上一页响应的 next_start_guid

请求示例 ​

bash
curl -s "https://webapi.futunn.com/api/v1.0/quote/python-indicators/catalog" \
  -H "Authorization: Bearer <AccessToken>"

响应字段 ​

以下为 data 内字段。

字段类型说明
itemsobject[]本页目录项,按 guid 升序,不含脚本和参数;本页为空时仍需看 next_start_guid 判断是否结束
items[].guidstring指标唯一 ID
items[].short_namestring指标缩写,解析失败时为空串
items[].remarksinteger指标说明多语言文案 ID,用户自编指标通常为 0
items[].short_name_okboolean缩写是否解析成功;为 false 时只能按 guid 召回
next_start_guidstring下一页分页游标,仅在还有下一页时返回;省略表示目录结束

响应示例 ​

json
{
  "code": 0,
  "message": "success",
  "data": {
    "items": [
      {
        "guid": "a1",
        "short_name": "MA",
        "remarks": 0,
        "short_name_ok": true
      },
      {
        "guid": "b2",
        "short_name": "",
        "remarks": 0,
        "short_name_ok": false
      }
    ],
    "next_start_guid": "c3"
  }
}

错误码 ​

失败响应(code != 0)会在顶层附加 trace_id(code=0 时省略)。

code说明
-3请求参数不合法
-5未登录、用户归属地不在支持范围(支持 CN/HKG/US/SG/AU/JP)或内部查询失败
-9当前访问策略拒绝
-11请求过于频繁,按 Retry-After 秒数退避
-13限频服务暂不可用

说明 ​

  • 仅以响应中是否出现 next_start_guid 判断翻页结束:若本页 items 为空但仍返回 next_start_guid,需继续以该游标请求下一页。
  • 游标按服务端 guid >= start_guid 定位下一页起点,请原样回传 next_start_guid,不要自行用本页最后一条 guid 替代。
  • short_name_ok 为 false 的条目无法通过缩写匹配,调用查询用户 Python 指标时请按 guid 查询。
  • 响应包含 Cache-Control: private, no-store 头。