查询模型定价

端点
GET/v1/models/pricing

返回定价表里全部模型的 模驿API 价格与官方标价。本接口不需要鉴权。

定价表与可调用模型列表并不一一对应:模型是否可调用以列出模型为准,价格以本接口为准。

请求

无需鉴权,无请求体。

参数

无。

响应

json
{
  "models": [
    {
      "id": "claude-sonnet-5",
      "owned_by": "anthropic",
      "cost": {"input": 0.6, "output": 3.0, "cached_input": 0.06, "cache_creation": 0.75, "cache_read": 0.06},
      "list_cost": {"currency": "USD", "input": 2.0, "output": 10.0, "cached_input": 0.2, "cache_creation": 2.5, "cache_read": 0.2}
    }
  ]
}
字段 说明
models[].id 模型 ID
models[].owned_by 模型厂商
models[].cost 模驿API 价格,按每百万 token 计:input 输入、output 输出;支持缓存的模型另有 cached_inputcache_creationcache_read
models[].list_cost 官方标价,字段同 costcurrency 为币种

示例中的数值以接口实时返回为准。

示例

bash
curl https://api.moyiapi.cn/v1/models/pricing

错误

本接口不需要鉴权,正常情况下不返回 401。

准备好了?三步即可开始登录控制台 · 购买额度 · 创建 API Key
DiscordGet community help instantly
查询模型定价 · 帮助文档