{"type":"root","children":[{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"这篇解决什么问题"}]},{"type":"text","value":"：接 Tare 时按任务查接口路径、请求字段和回包字段，一份查全。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"第一次接入不用从头读完。先按下面的任务表找到你要的接口，再跳到对应小节。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h3","properties":{},"children":[{"type":"text","value":"按任务找接口"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"你要做什么"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"看哪些接口"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"使用什么 key"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"调模型对话"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"POST /v1/chat/completions"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"Inference key（推理 key）或 Child key（子钥）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"做向量化"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"POST /v1/embeddings"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"Inference key（推理 key）或 Child key（子钥）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"生成图片"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"POST /v1/images"}]},{"type":"text","value":" 或 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/images/generations"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"Inference key（推理 key）或 Child key（子钥）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"提交视频任务"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"POST /v1/videos/generations"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"Inference key（推理 key）或 Child key（子钥）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"判断文本（是非 / 单选 / 打分）"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"POST /v1/decisions"}]},{"type":"text","value":"（也认 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/systemone"}]},{"type":"text","value":"），见"},{"type":"element","tagName":"a","properties":{"href":"decisions"},"children":[{"type":"text","value":"决策接口"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"Inference key（推理 key）或 Child key（子钥）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"查可用模型"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"GET /v1/models"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"可不带 key；带 key 时返回该 key 可用目录"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"查单次调用成本"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"GET /v1/generation?id=gen-..."}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"发起调用的 key"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"签发子钥"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/*"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"Provisioning key（母钥）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"机器对账"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/integration/*"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"Reconciliation key（对账 key）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h3","properties":{},"children":[{"type":"text","value":"两种响应格式"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"模型端点、key 管理、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/models"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/generation"}]},{"type":"text","value":" 等接口接近 OpenAI / OpenRouter 的格式；\n"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/integration/*"}]},{"type":"text","value":" 和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/mocks/*"}]},{"type":"text","value":" 则用 ApiResponse 信封（把结果包进一层统一的外层结构）。\n写客户端时不要假设所有接口都是同一种错误体。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h3","properties":{},"children":[{"type":"text","value":"图片接口特别注意"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/images"}]},{"type":"text","value":" 回包里可能同时有 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"b64_json"}]},{"type":"text","value":" 和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"url"}]},{"type":"text","value":"。"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"b64_json"}]},{"type":"text","value":" 长期有效；"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"url"}]},{"type":"text","value":" 是托管地址，\n24 小时失效。需要长期保存图片时，请保存 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"b64_json"}]},{"type":"text","value":" 或转存到自己的对象存储。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h3","properties":{},"children":[{"type":"text","value":"详细说明"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"Base URL："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"https://tare.jamerly.ai"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"text","value":"模型流量"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"方法"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"路径"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"用途"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"POST"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/chat/completions"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"模型调用。OpenAI 格式，支持流式"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"POST"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/embeddings"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"文本转向量。OpenAI 格式，无流式"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"POST"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/images"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"图片生成。无流式"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"POST"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/images/generations"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"同一接口的兼容路径"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"POST"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/videos/generations"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"提交一个视频生成任务。异步，见下方说明"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"GET"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/videos/generations/{id}"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"查询视频任务的状态与结果"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"POST"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/decisions"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"决策：一段文本 + 若干问题，回每个答案的概率。无流式，见"},{"type":"element","tagName":"a","properties":{"href":"decisions"},"children":[{"type":"text","value":"决策接口"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"POST"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/systemone"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"同一接口的兼容路径（TypeSafe Jev / Microsoft Foundry 的叫法）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"GET"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/models"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"本账号可用的模型与价格"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"GET"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/generation?id=gen-…"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"事后查询单次调用的成本"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h5","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"POST /v1/embeddings"}]},{"type":"text","value":"：文本转向量"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"OpenAI 格式。请求体原样转发给上游，跟 chat 一样有两个例外："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"models"}]},{"type":"text","value":" 和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"provider"}]},{"type":"text","value":"。\n回包是上游原文加一格 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage.cost"}]},{"type":"text","value":"："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"pre","properties":{},"children":[{"type":"element","tagName":"code","properties":{"className":["language-json"]},"children":[{"type":"text","value":"{\"model\":\"text-embedding-3-small\",\"input\":\"hello\"}\n"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"与 chat 的不同点："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"模型名不做映射。"}]},{"type":"text","value":" chat 填写的是平台侧模型名（"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"GET /v1/models"}]},{"type":"text","value":" 的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"id"}]},{"type":"text","value":"），\n这里写的是"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"上游自己的名字"}]},{"type":"text","value":"。embeddings 不走模型路由表，没有那层映射，回包里的模型名\n同样不改写。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"渠道要显式配过才做 embeddings。"}]},{"type":"text","value":" 在 Channels 页给这条渠道填上 embeddings\n地址，才表示它提供这个接口；留空即不提供。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"平台不按各家 API 的差异推断"}]},{"type":"text","value":"：「chat 接口是\nOpenAI 格式」和「有 embeddings 接口」是两件事。大量中转、聚合网关与自建推理服务\n只提供 chat，推断出的地址在它们那里并不存在。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"ul","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"候选顺序：自己的渠道优先，平台渠道备选。"}]},{"type":"text","value":" 你自己配过 embeddings 地址的渠道\n按渠道 id 升序全部作为候选；一条都没配时，才轮到平台渠道里专门提供 embeddings 的那条。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"自有渠道之间会故障转移。"}]},{"type":"text","value":" 配了几条就依次试几条，第一条打不通自动换下一条，\n转移痕迹在"},{"type":"element","tagName":"a","properties":{"href":"content-retention"},"children":[{"type":"text","value":"调用详情"}]},{"type":"text","value":"里逐条可见。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"候选全部处于熔断状态（平台自动暂时停用）时是 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"503"}]},{"type":"text","value":"，不是没定价那个 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"404"}]}]},{"type":"text","value":"。两者含义不同、\n解法也不同（等一等重试，还是去配一个价）。上报方式和 chat、images 一致：\n一条 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"UPSTREAM_ALL_DOWN"}]},{"type":"text","value":" 类型的事故，在模型的健康时间线上能看到。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"models"}]},{"type":"text","value":" 和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"provider"}]},{"type":"text","value":" 这里也能用，但 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"models"}]},{"type":"text","value":" 的含义跟 chat 不完全一样。"}]},{"type":"text","value":"\nembeddings 没有路由表可以映射，"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"models"}]},{"type":"text","value":" 里的名字是另一个"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"上游原始模型名"}]},{"type":"text","value":"，\n不是平台侧名字。外层按这条链换模型名，每换一个都会把你全部渠道重新试一轮，\n等这一个模型名在所有渠道上都失败了才换下一个。"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"provider"}]},{"type":"text","value":" 的行为跟 chat 完全一样：\n只会调整或过滤"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"你自己"}]},{"type":"text","value":"渠道的顺序，不会把平台渠道拉进来。完整字段说明见"},{"type":"element","tagName":"a","properties":{"href":"routing"},"children":[{"type":"text","value":"路由"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"不会从自有渠道转到平台渠道。"}]},{"type":"text","value":" 二者计费不同：自己的渠道只记账不扣钱，平台渠道\n按售价扣余额。静默回退等于"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"在未经同意的情况下开始扣费"}]},{"type":"text","value":"，而表现只是「调用成功了」。\n自有渠道全部不可用时直接报错，不替换成平台的。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"平台渠道上未定价的模型一律拒绝，而不是免费提供。"}]},{"type":"text","value":" 平台渠道的 token 由平台向上游\n购买，价目表缺这一行时定价会算成 0。与其静默地免费服务，不如明确失败。\n这种情况返回 404 并说明原因；改用自己的渠道，或联系我们为该模型定价。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"无流式。"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"gen-"}]},{"type":"text","value":" 编号照常走响应头，"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/generation"}]},{"type":"text","value":" 可回查。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"embedding 模型不会出现在 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"GET /v1/models"}]},{"type":"text","value":" 里。"}]},{"type":"text","value":" 那份目录来自上游的模型目录，\n而上游的目录里就没有 embedding 模型（实测：421 个模型，0 个）。模型名请按上游文档填写，\n不能从平台目录中选取。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"向量化的调用和 chat 走"},{"type":"element","tagName":"a","properties":{"href":"content-retention"},"children":[{"type":"text","value":"同一个留存开关"}]},{"type":"text","value":"。"}]},{"type":"text","value":" 开关打开时，请求正文与\n上游回包一并留存，在调用详情里可以展开查看；关闭时一个字节都不落库。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"此前这条端点无论开关如何都不留存，理由是「输入常常是整篇文档」。代价是它在调用详情\n里什么都看不到。一次成功的向量化调用和一次没跑完的记录长得一模一样。留不留存\n现在由你决定，而不是由端点类型决定。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h5","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"POST /v1/images"}]},{"type":"text","value":"：图片生成"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"pre","properties":{},"children":[{"type":"element","tagName":"code","properties":{"className":["language-json"]},"children":[{"type":"text","value":"{\"model\":\"google/gemini-3-pro-image\",\"prompt\":\"a red fox in the snow\"}\n"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"请求"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"字段"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"model"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"必填。"}]},{"type":"text","value":" 你在 Routing 页配过的模型，或平台默认模型。跟 chat 一样，靠 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"models"}]},{"type":"text","value":" 做备用链、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"provider"}]},{"type":"text","value":" 做按次路由偏好，见"},{"type":"element","tagName":"a","properties":{"href":"routing"},"children":[{"type":"text","value":"路由"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"prompt"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"必填。"}]},{"type":"text","value":" 图片描述"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"其余字段"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"原样转发给上游"}]},{"type":"text","value":"："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"size"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"aspect_ratio"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"n"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"input_references"}]},{"type":"text","value":"、以及各家自己的参数。具体支持哪些取决于模型；传入上游不支持的字段时，返回的是"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"上游的"}]},{"type":"text","value":"报错，而非平台的报错。"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"models"}]},{"type":"text","value":" 和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"provider"}]},{"type":"text","value":" 是例外，跟 chat 一样，这两个会被消费掉，不会转发给上游"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"POST /v1/images/generations"}]},{"type":"text","value":" 是同一个接口，请求和回包完全一样。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"回包"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"pre","properties":{},"children":[{"type":"element","tagName":"code","properties":{"className":["language-json"]},"children":[{"type":"text","value":"{\n  \"id\": \"gen-c9d21c16eec04f968fc9bbcd08e140f9\",\n  \"created\": 1787820572,\n  \"model\": \"google/gemini-3-pro-image\",\n  \"data\": [\n    {\n      \"b64_json\": \"iVBORw0KGgo…\",\n      \"media_type\": \"image/png\",\n      \"url\": \"https://s.jamerly.ai/img/36/b21a5d9fa79b4135993282e1baf34999.png\",\n      \"expires_at\": 1787906972\n    }\n  ],\n  \"usage\": {\"prompt_tokens\": 7, \"completion_tokens\": 4175, \"total_tokens\": 4182, \"cost\": 0.000900}\n}\n"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"字段"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"id"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"这次调用的编号，和响应头 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"X-Generation-Id"}]},{"type":"text","value":" 是同一个值，可用它查 "},{"type":"element","tagName":"a","properties":{"href":"endpoints"},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/generation"}]}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"model"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"请求中使用的模型名"}]},{"type":"text","value":"，而非上游的模型名"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"data[].b64_json"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"图片字节，base64。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"该字段长期有效"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"data[].media_type"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"image/png"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"image/jpeg"}]},{"type":"text","value":" …"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"data[].url"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"同一份字节的托管地址。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"调用后 24 小时失效"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"data[].expires_at"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"Unix 秒，该 URL 的失效时刻，以此为准"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"text"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"模型在图片之外返回的文本。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"为空时不返回该字段。"}]},{"type":"text","value":" 标准 images 回包没有承载文本的字段，因此这是平台新增的字段，标准字段不作改动"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"finish_reason"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"上游的结束原因。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"data"}]},{"type":"text","value":" 为空时首先读该字段"}]},{"type":"text","value":"："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"content_filter"}]},{"type":"text","value":" 表示上游已生成图片，但被其自身内容策略拦截"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"token 数，以及 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"cost"}]},{"type":"text","value":" = "},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"本次调用的成本"}]},{"type":"text","value":"。图片按 token 计费，因此 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"completion_tokens"}]},{"type":"text","value":" 会很大"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"data"}]},{"type":"text","value":" 可能是空数组，而这不是错误。"}]},{"type":"text","value":" 上游正常返回、只是没给图，比如模型这次\n只返回了文字，或图片被上游的内容策略拦截。平台"},{"type":"text","value":"<b>"},{"type":"text","value":"不会将其判定为失败"},{"type":"text","value":"</b>"},{"type":"text","value":"：\nHTTP 状态码仍为 200，具体原因见 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"finish_reason"}]},{"type":"text","value":" 与 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"text"}]},{"type":"text","value":" 字段。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"不要将 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"url"}]},{"type":"text","value":" 持久化到数据库。"}]},{"type":"text","value":" 该链接次日即失效，且失效前与永久链接无法区分。\n需要留存时请保存 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"b64_json"}]},{"type":"text","value":"，或将字节转存至自有存储。\n该 URL 的用途是向其他系统传递图片时避免传输数 MB 的字节。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"img","properties":{"src":"diagram:endpoints-image-expiry","alt":"图片接口 · URL 24 小时失效","data-block":"true"},"children":[]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"行为"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"ul","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"按模型路由"}]},{"type":"text","value":"，和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/chat/completions"}]},{"type":"text","value":" 一样：你在 Routing 页把\n"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"google/gemini-3-pro-image"}]},{"type":"text","value":" 指到哪条渠道，这次调用就走哪条。出图模型之间价差一个\n数量级以上，模型选择对成本影响显著。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"故障转移和 chat 一样"}]},{"type":"text","value":"：模型配置了不止一条路由时，失败会转移到下一条候选，\n不会直接把这次调用判失败。第二条候选的计费方式可能不同（一条是你自己的\n渠道、一条是平台渠道），所以余额检查会看"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"整条链上的每一条候选"}]},{"type":"text","value":"，不只看第一条。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"计费、限额、调用留痕与 chat 完全一致"}]},{"type":"text","value":"：同样先过余额 / 预算 / 子 Key 额度三道检查，\n同样落入"},{"type":"element","tagName":"a","properties":{"href":"content-retention"},"children":[{"type":"text","value":"调用详情"}]},{"type":"text","value":"（含提示词），计费定义一致。所有接口用的是同一套记账方式。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"不支持流式。"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h5","properties":{},"children":[{"type":"text","value":"在 chat 调用里出图："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"modalities"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"该方式同样支持：在 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/chat/completions"}]},{"type":"text","value":" 上传入 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"modalities"}]},{"type":"text","value":"，图片位于回包的\n"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"message.images"}]},{"type":"text","value":" 中。同一次调用需同时返回文字与图片时使用该方式；仅需图片时使用\n"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/images"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"pre","properties":{},"children":[{"type":"element","tagName":"code","properties":{"className":["language-json"]},"children":[{"type":"text","value":"{\"model\":\"…\",\"messages\":[{\"role\":\"user\",\"content\":\"a red fox\"}],\n \"modalities\":[\"image\",\"text\"]}\n"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"请求体"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"原样转发给上游"}]},{"type":"text","value":"，回包是"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"上游原文"}]},{"type":"text","value":"（只改写 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"model"}]},{"type":"text","value":" 和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"id"}]},{"type":"text","value":"）。三点需要注意："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"路由只看输入模态，不看请求的输出模态。"}]},{"type":"text","value":" 一个模型名下挂多条候选、只有部分能出图\n时，故障转移可能落到出不了图的那条上，表现为「同样的请求有时出图有时只出文字」。\n"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"在配置上规避"}]},{"type":"text","value":"：给出图的模型单独一个模型名，或只给它配一条渠道。按输出模态挑候选\n已在排期。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"ul","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"计价按 token 与上游自报成本"}]},{"type":"text","value":"。"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"GET /v1/models"}]},{"type":"text","value":" 的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"pricing.image"}]},{"type":"text","value":" "},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"恒为 0，不代表\n免费"}]},{"type":"text","value":"（没有「每张图」这一档）。单次图片成本读回包的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage.cost"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"text","value":"图片以 base64 还是 URL 返回"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"由上游决定"}]},{"type":"text","value":"，平台不做改写。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h5","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"POST /v1/videos/generations"}]},{"type":"text","value":"：视频生成"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"视频任务动辄跑几分钟，不是几秒，所以格式是\"提交后轮询\"，不是请求-响应："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"pre","properties":{},"children":[{"type":"element","tagName":"code","properties":{"className":["language-json"]},"children":[{"type":"text","value":"{\"model\":\"…\",\"prompt\":\"a red fox running through snow\",\n \"duration_seconds\":5,\"aspect_ratio\":\"16:9\"}\n"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"请求"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"字段"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"model"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"必填。"}]},{"type":"text","value":" 支持 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"models"}]},{"type":"text","value":" 备用模型链和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"provider"}]},{"type":"text","value":" 按次渠道偏好，见"},{"type":"element","tagName":"a","properties":{"href":"routing"},"children":[{"type":"text","value":"路由"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"prompt"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"必填"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"duration_seconds"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"aspect_ratio"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"可选；某个模型接受哪些值取决于这个模型本身"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"reference_image_url"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"reference_video_url"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"可选的参考输入，用于支持图生视频/视频生视频的模型"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"callback_url"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"会被接受并存起来。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"目前没有投递"}]},{"type":"text","value":"，完成后不会调用它，请改用轮询"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"其余字段"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"原样转发给上游，规则和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/images"}]},{"type":"text","value":" 一致"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"余额 / 预算 / 子 Key 额度三道闸在提交时就检查，和 chat 一样。超限的任务根本建不出来。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"这里没有 chat、embeddings、images 那种跨渠道故障转移。"}]},{"type":"text","value":" 提交只会打"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"一条"}]},{"type":"text","value":"候选，\n也就是 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"provider"}]},{"type":"text","value":" 过滤之后优先级最高的那一条。如果这条渠道自己的提交调用失败，任务直接\n失败，不会换成你配的下一条渠道。"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"models"}]},{"type":"text","value":" 只能接住\"这个模型压根没配路由\"这种情况，\n模型确实配了路由、但这一条渠道拒绝了提交请求时，"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"models"}]},{"type":"text","value":" 帮不上忙。如果你给一个\n视频模型配了备用渠道、指望它像 chat 那样自动转移，除非主渠道完全没配路由，否则\n那条备用渠道不会被用到。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"如果排在最前面的候选恰好已经熔断，配了不止一条的话提交至少会跳去选一条没熔断\n的。这是\"挑候选\"这一步会看熔断状态，不是上面说的那种失败重试。如果所有候选\n都熔断了，提交会直接被拒绝，不会硬打一条已知在停靠的渠道，而且和 chat、images\n一样，这里也会记一条 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"UPSTREAM_ALL_DOWN"}]},{"type":"text","value":" 类型的事故。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"响应"}]},{"type":"text","value":"（提交接口和每次轮询返回的都是这个格式）"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"pre","properties":{},"children":[{"type":"element","tagName":"code","properties":{"className":["language-json"]},"children":[{"type":"text","value":"{\"id\":\"gen-…\",\"status\":\"pending\",\"model\":\"…\",\"created\":1700000000}\n"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"status"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"含义"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"pending"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"已接受，上游还没开始"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"running"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"上游正在生成"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"succeeded"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"result.video_url"}]},{"type":"text","value":"（上游返回多个时还有 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"result.video_urls"}]},{"type":"text","value":"）、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage.video_tokens"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"completed"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"failed"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"error.message"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"expired"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"等上游等到放弃。按 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"failed"}]},{"type":"text","value":" 处理即可"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"下图用于理解各状态；轮询时以响应的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"status"}]},{"type":"text","value":" 为准，不依赖固定的状态迁移顺序。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"img","properties":{"src":"diagram:endpoints-video-status","alt":"视频生成 · status 的五个取值","data-block":"true"},"children":[]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"轮询 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"GET /v1/videos/generations/{id}"}]},{"type":"text","value":" 从不会打到你的上游供应商。"}]},{"type":"text","value":" 它读的是平台自己的\n任务表；真正打上游的轮询节奏由 Tare 统一控制。想多勤快地查都可以，\n不会给供应商增加额外调用，也不会让任务跑得更快。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"chat、embeddings、images 有两样东西，这个接口现在没有："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage_label"}]},{"type":"text","value":" 接收但不读取\n（悄悄地，它只是变成一个上游不认识、会被忽略的字段），提示词和结果"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"永远不会"}]},{"type":"text","value":"写进\n"},{"type":"element","tagName":"a","properties":{"href":"content-retention"},"children":[{"type":"text","value":"Call Traces"}]},{"type":"text","value":"，跟账号的留存开关无关。这两样目前都没有开关能打开：\n视频生成调用暂时没有归因标签，也没有可查的历史记录，不像另外三个接口那样。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"text","value":"请求头"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"未识别的请求头一律忽略：不会因此拒绝请求，也不会转发给上游。"}]},{"type":"text","value":" 平台会重建发往上游的\n请求头（凭据、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"Content-Type"}]},{"type":"text","value":"、各家 API 差异要求的若干头），"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"客户端携带的请求头不会出现在\n上游一侧"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"归因头 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"HTTP-Referer"}]},{"type":"text","value":" / "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"X-Title"}]},{"type":"text","value":" 属于这一类：携带无副作用（不影响路由、计费、\n限流），但不会到达上游。归因请使用以下两种方式："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"需求"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"方式"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"标记调用所属业务"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"请求体里的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage_label"}]},{"type":"text","value":"，原样落进用量记录。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"只有 chat、embeddings、images 支持"}]},{"type":"text","value":"，视频生成目前不读这个字段，传了也没用（而且不会报错，因为不认识的字段会原样转发给上游）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"标记调用所属终端用户"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"为该用户单独创建子钥，见 "},{"type":"element","tagName":"a","properties":{"href":"provisioning"},"children":[{"type":"text","value":"母钥"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"未开启 CORS。"}]},{"type":"text","value":" 从浏览器直连时这两个自定义头会在预检阶段被浏览器拦下，请求根本没有\n发出。服务端调用不受影响，也建议始终从服务端调用：推理 key 放进浏览器等于公开它。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"gen-"}]},{"type":"text","value":" 编号"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"每次调用返回一个 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"gen-xxxxx"}]},{"type":"text","value":"，"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"由平台生成"}]},{"type":"text","value":"，而非上游生成。用于查询成本，也可作为\n你侧记账的幂等键。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"前缀是硬要求：不少客户端用 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"id.startsWith(\"gen-\")"}]},{"type":"text","value":" 判断调用是否有编号，\n换前缀会让该判断失败，对账链路空转。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"text","value":"Key 管理（母钥）"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"供平台型客户给终端用户签发子钥，凭母钥调用，"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"不依赖登录态"}]},{"type":"text","value":"。见 "},{"type":"element","tagName":"a","properties":{"href":"provisioning"},"children":[{"type":"text","value":"母钥"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"方法"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"路径"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"用途"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"POST"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"创建子钥（带 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"external_id"}]},{"type":"text","value":" 时幂等）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"GET"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"列出名下子钥，游标分页，含已停用"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"GET"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/{hash}"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"查询子钥的额度与用量"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"PATCH"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/{hash}"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"改额度 / 停用 / 改名"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"GET"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/external/{externalId}"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"同上，按"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"外部编号"}]},{"type":"text","value":"定位"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"PATCH"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/external/{externalId}"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"同上，按"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"外部编号"}]},{"type":"text","value":"定位"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"POST"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/{hash}/reset"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"立刻清零额度（按外部编号："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/external/{externalId}/reset"}]},{"type":"text","value":"）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"GET"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/usage/daily"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"账号下全部子钥按天的用量"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"GET"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/{hash}/usage/daily"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"一把子钥按天的用量"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"GET"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys/external/{externalId}/usage/daily"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"同上，按"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"外部编号"}]},{"type":"text","value":"定位"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"text","value":"控制台与对账"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"控制台（渠道、路由、账单、告警）是另一套界面，用登录态。机器对机器的对账有专门的、按\nkey 鉴权的接口，见 "},{"type":"element","tagName":"a","properties":{"href":"integration-api"},"children":[{"type":"text","value":"对账 API"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"三类 key 权限互不重叠：推理 key 只能调模型，对账 key 只能读报表，母钥只能管 key。\n用错类型返回的是明确的拒绝，不是含糊的 401。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"GET /v1/models"}]},{"type":"text","value":"：字段与说法"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"带上你的推理 key，目录里就包含你自己配的模型"}]},{"type":"text","value":"：你在自己渠道上配的那些 ∪ 平台的那些，\n同名时以你自己那条为准，和真正调用时的路由说法完全一致。\n"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"不带 key"}]},{"type":"text","value":" 拿到的是平台目录（这条路一直保留，客户端可以不带任何请求头拉目录）。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"推理 key 和母钥都可以。"}]},{"type":"text","value":" 母钥没有绑 Router，它拿到的是"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"账号默认那套路由"}]},{"type":"text","value":"的目录；\n要查看某一把绑定了其他 Router 的子钥可用哪些模型，请使用该子钥调用。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"携带了 key 但无效或已过期时返回 "},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"401"}]},{"type":"text","value":"（不会静默返回一份缺少自有模型的目录）；\n对账 key 返回 "},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"403"}]},{"type":"text","value":"：对账 key 无权访问模型相关接口。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"你自己渠道上的模型，"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"pricing.prompt"}]},{"type":"text","value":" / "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"completion"}]},{"type":"text","value":" 是 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"0"}]}]},{"type":"text","value":"：那些 token\n由你直接支付给上游，不经平台价目表。真实成本读回包的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage.cost"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"pre","properties":{},"children":[{"type":"element","tagName":"code","properties":{"className":["language-json"]},"children":[{"type":"text","value":"{\"data\":[{\"id\":\"GLM 5.1\",\"name\":\"GLM 5.1\",\"description\":\"…\",\"context_length\":128000,\n  \"architecture\":{\"modality\":\"text->text\",\"input_modalities\":[\"text\"],\"output_modalities\":[\"text\"]},\n  \"reasoning\":{\"mandatory\":false,\"default_enabled\":true,\n    \"supported_efforts\":[\"low\",\"medium\",\"high\"],\"default_effort\":\"medium\"},\n  \"pricing\":{\"prompt\":\"0.0000006\",\"completion\":\"0.0000022\",\n    \"input_cache_read\":\"0.00000006\",\"input_cache_write\":\"0.00000075\",\n    \"request\":\"0\",\"image\":\"0\"}}]}\n"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"字段"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"说法"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"id"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"平台侧模型名"}]},{"type":"text","value":"，用它发起调用"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"pricing.prompt"}]},{"type":"text","value":" / "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"completion"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"每 token"}]},{"type":"text","value":"（不是每百万），字符串"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"pricing.input_cache_read"}]},{"type":"text","value":" / "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"input_cache_write"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"缓存两档，同样每 token"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"pricing.request"}]},{"type":"text","value":" / "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"image"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"恒为 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"0"}]}]},{"type":"text","value":"，见下方警告"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"币种"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"美元"}]},{"type":"text","value":"，暂不提供其他币种换算"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"description"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"上游目录的模型说明；不可用时"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"该字段不出现"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"context_length"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"来自上游目录；不可用时"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"该字段不出现"}]},{"type":"text","value":"（不要当成 0）"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"max_completion_tokens"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"这个模型自己的输出长度上限；不可用不出现的规矩和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"context_length"}]},{"type":"text","value":" 一样"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"architecture"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"先看 Routing 页给这个模型设的能力，再看上游目录，再看 Tare 的模型资料；都没有时"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"该字段不出现"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"reasoning"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"思考能力，来自上游目录；不可用时"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"该字段不出现，不给默认值"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"description"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"context_length"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"max_completion_tokens"}]},{"type":"text","value":" 这三个字段，上游目录没给不代表\n就此没有：Tare 自己维护了一份常用模型的基准数据，上游没给会先查这份基准再决定要不要\n留空。自建的、不常见的模型仍然什么都不会编。这份基准只帮上游目录恰好没说的那些模型。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"pricing.image"}]},{"type":"text","value":" "},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"恒为 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"0"}]},{"type":"text","value":"，但图片不是免费的"}]},{"type":"text","value":"。价目表只有 token 四档（输入 / 输出 /\n缓存读 / 缓存写），没有「每张图」这一档；带图的调用按上游报的 token 与成本计价。\n"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"不要用这个字段估算图片成本"}]},{"type":"text","value":"，读回包的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage.cost"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h5","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"reasoning"}]},{"type":"text","value":"：思考能力"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"pre","properties":{},"children":[{"type":"element","tagName":"code","properties":{"className":["language-json"]},"children":[{"type":"text","value":"{\"mandatory\":false,\"default_enabled\":true,\n \"supported_efforts\":[\"low\",\"medium\",\"high\"],\"default_effort\":\"medium\"}\n"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"用于决定是否展示「思考强度」选择器、展示哪几档："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"ul","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"supported_efforts"}]},{"type":"text","value":" 的取值由上游决定"}]},{"type":"text","value":"，不限于这三档（部分上游还提供 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"minimal"}]},{"type":"text","value":" /\n"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"xhigh"}]},{"type":"text","value":" / "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"none"}]},{"type":"text","value":"）。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"按字段渲染，不要在客户端写死"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"mandatory: true"}]},{"type":"text","value":" 表示无法关闭"}]},{"type":"text","value":"，此时不要渲染开关。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"reasoning"}]},{"type":"text","value":" 缺席表示未知，不表示「不支持思考」。"}]},{"type":"text","value":" 自建和本地模型没有目录条目，\n该字段就会缺失；把缺席当成不支持会让这些模型的选择器消失。这里不做备选：编造默认值\n等于代替上游做出未经确认的承诺，用户选了上游不认的强度会收到 400，看起来像模型故障。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"回包里怎么拿到思考内容"}]},{"type":"text","value":"：模型如果真的产生了思考过程，会出现在 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"message.reasoning_content"}]},{"type":"text","value":"\n里（流式是 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"delta.reasoning_content"}]},{"type":"text","value":"），是独立于 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"content"}]},{"type":"text","value":" 的字段。不同上游给的格式不一样，\n比如 Anthropic 的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"thinking"}]},{"type":"text","value":" 内容块，完整或流式都有，统一翻译成这一个字段，客户端只需要读\n一处，不用管到底是哪家模型在答。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"目前没有单独的工具调用能力标记"}]},{"type":"text","value":"，无法从这份目录判断模型是否支持工具调用。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage.cost"}]},{"type":"text","value":"：这次调用的成本"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"单位美元："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"ul","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"text","value":"平台模型：等于平台售价；"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"BYOK：上游进价 + 治理费"}]},{"type":"text","value":"。BYOK 的 token 你直接付给供应商，这里给 0 会让成本报表\n显示本月免费用掉了几百万 token。治理费保底 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"0.0001"}]},{"type":"text","value":"，更高费率按试用或合同约定。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"text","value":"上游在回包里自报成本的渠道"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"以自报值为准"}]},{"type":"text","value":"，不录进价也能拿到。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"无法计算时该字段不出现"}]},{"type":"text","value":"，而不是 0：一个假的 0 会被当真。\n「这个模型还没定价」也算无法计算，因此"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"出现的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"0"}]},{"type":"text","value":" 是真的 0"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"流式的末帧同样带 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"cost"}]}]},{"type":"text","value":"（末帧才有 usage）。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"平台模型的回包里没有 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage.cost_details"}]}]},{"type":"text","value":"：该字段是上游向平台收取的费用。\nBYOK 下保留，该数值来自你自己的上游账单，正是成本归因所需。\n"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"GET /v1/generation"}]},{"type":"text","value":" 的 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"upstream_inference_cost"}]},{"type":"text","value":" 同理，仅 BYOK 调用具备该字段。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"自建、本地模型，以及模型列表只给 id 的中转站，通常没有 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"architecture"}]},{"type":"text","value":"，按 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"input_modalities"}]},{"type":"text","value":" 过滤模型的应用会把它们筛掉。\n在控制台 "},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"Routing"}]},{"type":"text","value":" 页打开这个模型，点 "},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"Capabilities"}]},{"type":"text","value":" 设上能力：弹窗里先按上游给的填好，存下之后 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/models"}]},{"type":"text","value":" 就按你设的报。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"GET /v1/generation?id="}]},{"type":"text","value":"：数据何时可查"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"数据来自用量记录，而"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"用量记录在响应之后才写入"}]},{"type":"text","value":"，因此拿到编号立刻查询会 404。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"404 有两种含义且"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"目前同码"}]},{"type":"text","value":"：尚未写入（应重试）和不属于你的调用（应放弃）。用时间\n区分："},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"收到编号后 60 秒内的 404 一律视为尚未写入"}]},{"type":"text","value":"，超过则视为后者。不区分是刻意的，\n区分等于提供一个「这个编号是否存在」的探测接口。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"ul","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"非流式"}]},{"type":"text","value":"：响应返回后通常 1 秒内可查。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"流式"}]},{"type":"text","value":"：末帧之后写入，以"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"流结束"}]},{"type":"text","value":"为准。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"404 是正常路径"}]},{"type":"text","value":"，按「稍后再试」处理，退避几秒重试。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"中途断开的流式调用"}]},{"type":"text","value":"，成本需事后向上游回查补记，最长可能到分钟级。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h5","properties":{},"children":[{"type":"text","value":"耗时字段"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"字段"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"含义"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"generation_time"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"真正作答那一家花的时间（毫秒）。没有转移过时等于 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"latency"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"latency"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"总耗时："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"generation_time"}]},{"type":"text","value":" 加上转移之前每一条失败尝试各自的耗时"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"routing_overhead_ms"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"latency"}]},{"type":"text","value":" 减去 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"generation_time"}]},{"type":"text","value":"。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"只在真的转移过渠道时才出现"}]},{"type":"text","value":"，没转移就不给这一格，不是 0"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"time_to_first_token_ms"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"首字节到达耗时。"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"只有流式调用才有"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"字段名和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"latency"}]},{"type":"text","value":"/"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"generation_time"}]},{"type":"text","value":" 的拆分方式照抄 OpenRouter 自己的 generation\nstats。"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"routing_overhead_ms"}]},{"type":"text","value":" 是它没有的。OpenRouter 不把自己的重试暴露给调用方，\nTare 能给是因为每一次尝试本来就单独记账，参见"},{"type":"element","tagName":"a","properties":{"href":"routing"},"children":[{"type":"text","value":"路由"}]},{"type":"text","value":"里「一次调用怎么会\n尝试不止一家」的说明。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"这四个字段在功能上线前写入的用量记录上不会出现。缺了就是缺了，不会补一个猜的值。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"text","value":"流式：强制打开 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"stream_options.include_usage"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"没有 usage 就没法计费，因此这一项会"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"覆盖请求里的设置"}]},{"type":"text","value":"（平台把 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"stream_options"}]},{"type":"text","value":" 整块换掉）。\n由此产生的格式差异："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"上游各家 API 的差异"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"末帧格式"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"OpenAI 兼容"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"上游末帧"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"原样转发"}]},{"type":"text","value":"："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"choices"}]},{"type":"text","value":" 为"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"空数组"}]},{"type":"text","value":"，带 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"Anthropic"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"由平台翻译："},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"choices"}]},{"type":"text","value":" 有一项、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"delta"}]},{"type":"text","value":" 为空、带 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"finish_reason"}]},{"type":"text","value":" 和 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"warning"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"两种各家 API 的末帧格式不一致。"}]},{"type":"text","value":" 前端按帧渲染时，判据写成「"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"choices"}]},{"type":"text","value":" 为空"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"或"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"delta"}]},{"type":"text","value":" 无内容 → 跳过渲染，只取 "},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"usage"}]},{"type":"text","value":"」即可覆盖两种格式。Anthropic 那条不会补成空\n"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"choices"}]},{"type":"text","value":" 帧，那样会多出一帧。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"img","properties":{"src":"diagram:endpoints-streaming-final-frame","alt":"流式末帧 · 两种格式","data-block":"true"},"children":[]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"text","value":"OpenAPI / JSON Schema"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"对外接口（"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/chat/completions"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/models"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/generation"}]},{"type":"text","value":"、\n"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/integration/*"}]},{"type":"text","value":"）有一份"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"手工维护的 OpenAPI 3.1 描述文件"}]},{"type":"text","value":"，与本文档同步更新："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"/openapi/tare.html"},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"在线查看"}]}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"单页面，"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"离线可用"}]},{"type":"text","value":"，无外部依赖"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"/openapi/tare.yaml"},"children":[{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"下载 openapi.yaml"}]}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"用于生成客户端、导入 Postman / Insomnia"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"不提供服务自动生成的那一份：它会一并暴露控制台、健康检查等并不面向调用方的接口，\n那些不是稳定契约，网关上也未开放。手写这份的覆盖范围就是"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"本文档中出现的接口"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"blockquote","properties":{"data-alert":"note"},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"描述文件只说明"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"字段结构"}]},{"type":"text","value":"，不重复这里的判断依据（为什么额度用尽是 403、为什么流式末帧\n两种各家 API 的格式不一致等）。接入时两份一起读。"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h4","properties":{},"children":[{"type":"text","value":"控制台与管理类接口"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"以上都是模型调用，也就是应用会打的那批。控制台本身，以及想拿自己登录的会话直接脚本化操作的\n人，背后是一片大得多的接口面。这些都不需要 API key，需要的是登录会话。下面按区域各列一行，\n不逐条列路径，具体做什么见对应文档："}]},{"type":"text","value":"\n"},{"type":"element","tagName":"table","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"thead","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"区域"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"根路径"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"th","properties":{},"children":[{"type":"text","value":"讲在哪"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tbody","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"API Key（账号所有者的完整视图：母钥、推理 key、子钥都在里面）"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/api-keys"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"auth"},"children":[{"type":"text","value":"API Key"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"母钥管自己开的那批子钥"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/keys"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"provisioning"},"children":[{"type":"text","value":"母钥"}]},{"type":"text","value":"，这一组"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"可以"}]},{"type":"text","value":"用母钥调"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"渠道"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/providers"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"channels"},"children":[{"type":"text","value":"渠道"}]},{"type":"text","value":"、"},{"type":"element","tagName":"a","properties":{"href":"cost-prices"},"children":[{"type":"text","value":"进价"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"本地节点"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/node"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"local-nodes"},"children":[{"type":"text","value":"本地节点"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"默认路由"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/routing"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"routing"},"children":[{"type":"text","value":"路由"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"命名 Router"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/routers"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"routing"},"children":[{"type":"text","value":"路由"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"告警规则与渠道"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/alerts"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"alerts"},"children":[{"type":"text","value":"告警"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"演习场景"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/mocks"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"mock"},"children":[{"type":"text","value":"演习（Mock）"}]},{"type":"text","value":"，这一组也"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"可以用推理 key 调"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"内容留存与查看授权"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/content-settings"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"content-retention"},"children":[{"type":"text","value":"Call Traces"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"审计日志"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/audit"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"audit-trail"},"children":[{"type":"text","value":"审计日志"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"DLP 策略与跳过设置"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/dlp"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"security"},"children":[{"type":"text","value":"数据保护"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"用管理钥配置渠道、路由和 DLP"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/manage"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"management-key"},"children":[{"type":"text","value":"管理钥"}]},{"type":"text","value":"，这一组"},{"type":"element","tagName":"strong","properties":{},"children":[{"type":"text","value":"只能"}]},{"type":"text","value":"用管理钥调"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"模型与渠道健康"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/health"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"routing"},"children":[{"type":"text","value":"路由"}]},{"type":"text","value":"、"},{"type":"element","tagName":"a","properties":{"href":"channels"},"children":[{"type":"text","value":"渠道"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"账单中心、账单、发票"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/billing"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"statements"},"children":[{"type":"text","value":"账单与发票"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"tr","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"text","value":"用量分析与图表"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/v1/analytics"}]},{"type":"text","value":"、"},{"type":"element","tagName":"code","properties":{},"children":[{"type":"text","value":"/usage"}]}]},{"type":"text","value":"\n"},{"type":"element","tagName":"td","properties":{},"children":[{"type":"element","tagName":"a","properties":{"href":"attribution"},"children":[{"type":"text","value":"成本归因"}]}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"h3","properties":{},"children":[{"type":"text","value":"下一步"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"ul","properties":{},"children":[{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"text","value":"只想跑通第一条请求：读 "},{"type":"element","tagName":"a","properties":{"href":"quickstart"},"children":[{"type":"text","value":"快速上手"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"text","value":"要接自己的供应商：读 "},{"type":"element","tagName":"a","properties":{"href":"channels"},"children":[{"type":"text","value":"渠道"}]},{"type":"text","value":"、"},{"type":"element","tagName":"a","properties":{"href":"cost-prices"},"children":[{"type":"text","value":"进价"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"text","value":"要配模型路由：读 "},{"type":"element","tagName":"a","properties":{"href":"routing"},"children":[{"type":"text","value":"路由"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"text","value":"要看错误码含义：读 "},{"type":"element","tagName":"a","properties":{"href":"errors"},"children":[{"type":"text","value":"错误码"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"},{"type":"element","tagName":"li","properties":{},"children":[{"type":"text","value":"要机器对账：读 "},{"type":"element","tagName":"a","properties":{"href":"integration-api"},"children":[{"type":"text","value":"对账 API"}]},{"type":"text","value":"。"}]},{"type":"text","value":"\n"}]}]}