{
  "schema": "mopu/v1",
  "generated_at": "2026-10-21T11:27:43.888Z",
  "vendor": {
    "id": "opencode",
    "name": "OpenCode Zen",
    "aliases": [
      "opencode",
      "opencode-zen",
      "zen",
      "oc"
    ],
    "homepage": "https://opencode.ai",
    "console": "https://opencode.ai/auth",
    "docs": [
      "https://opencode.ai/docs",
      "https://opencode.ai/docs/go/"
    ],
    "updated": "2026-10-20",
    "verified": {
      "at": "2026-10-20",
      "method": "官方文档 + 本机配置核对",
      "scope": "厂商入口、套餐说明"
    },
    "notes": "同时提供免费档（*-free，仅限 OpenCode 客户端）、Go 套餐（/zen/go/v1）\n与按量付费（/zen/v1、/inference/...）。三者鉴权与可用模型不同，不要混用 base_url。\n"
  },
  "keys": [
    {
      "id": "opencode-zen",
      "label": "OpenCode Zen API Key",
      "pattern": "^oc_sk_[A-Za-z0-9_-]{40,}$",
      "example": "oc_sk_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
      "env": "OPENCODE_API_KEY",
      "where": "https://opencode.ai/auth",
      "notes": "本机采集到两把 key，均为 oc_sk_ 前缀、总长 51 字符。\n免费档模型仍会校验客户端身份，有 key 也可能返回 403 FreeTierError。\n",
      "verified": {
        "at": "2026-10-20",
        "method": "本机采集",
        "scope": "key 前缀与长度"
      },
      "vendor": "opencode",
      "ref": "opencode/opencode-zen"
    }
  ],
  "models": [
    {
      "id": "deepseek-v4.1-flash-free",
      "vendor": "opencode",
      "name": "DeepSeek V4.1 Flash Free",
      "aliases": [
        "deepseek-v4.1-flash-free",
        "deepseek-flash-free"
      ],
      "status": "active",
      "kind": "chat",
      "plan": "free",
      "capabilities": [
        "text",
        "tools",
        "streaming"
      ],
      "limits": {
        "context": null,
        "output": null
      },
      "protocol": "openai-chat",
      "endpoint": {
        "base_url": "https://opencode.ai/inference/openai/v1",
        "path": "/chat/completions"
      },
      "auth": {
        "type": "bearer",
        "env": "OPENCODE_API_KEY"
      },
      "pricing": {
        "free": true,
        "currency": "USD",
        "input": 0,
        "output": 0,
        "note": "免费档"
      },
      "constraints": [
        "免费档仅允许 OpenCode 客户端调用；外部客户端一律 403。"
      ],
      "errors": [
        {
          "code": 403,
          "match": "FreeTierError",
          "docs": "https://opencode.ai/docs/go/"
        }
      ],
      "docs": [
        {
          "title": "OpenCode Docs",
          "url": "https://opencode.ai/docs"
        }
      ],
      "ui": [
        "opencode/add-key"
      ],
      "verified": {
        "at": "2026-10-20",
        "method": "curl 直连 /inference/openai/v1 实测",
        "scope": "endpoint、403 行为"
      },
      "notes": "Codex catalog 标称 context 1048576，未与官方文档核对。",
      "ref": "opencode/deepseek-v4.1-flash-free"
    },
    {
      "id": "glm-5.3-flash-free",
      "vendor": "opencode",
      "name": "GLM-5.3 Flash Free",
      "aliases": [
        "glm-5.3-flash-free",
        "glm-5.3-flash"
      ],
      "status": "active",
      "kind": "chat",
      "plan": "free",
      "capabilities": [
        "text",
        "tools",
        "streaming"
      ],
      "limits": {
        "context": null,
        "output": null
      },
      "protocol": "openai-chat",
      "endpoint": {
        "base_url": "https://opencode.ai/inference/openai/v1",
        "path": "/chat/completions"
      },
      "auth": {
        "type": "bearer",
        "env": "OPENCODE_API_KEY"
      },
      "pricing": {
        "free": true,
        "currency": "USD",
        "input": 0,
        "output": 0,
        "note": "免费档"
      },
      "constraints": [
        "免费档仅允许 OpenCode 客户端调用；外部客户端一律 403。"
      ],
      "errors": [
        {
          "code": 403,
          "match": "FreeTierError",
          "docs": "https://opencode.ai/docs/go/"
        }
      ],
      "docs": [
        {
          "title": "OpenCode Docs",
          "url": "https://opencode.ai/docs"
        },
        {
          "title": "OpenCode Go",
          "url": "https://opencode.ai/docs/go/"
        }
      ],
      "ui": [
        "opencode/add-key"
      ],
      "verified": {
        "at": "2026-10-20",
        "method": "curl 直连 /inference/openai/v1 实测",
        "scope": "endpoint、403 行为"
      },
      "notes": "Codex catalog 标称 context 1048576，未与官方核对。\n在 /zen/go/v1 上调用该模型会返回 \"Model is unavailable\"。\n",
      "ref": "opencode/glm-5.3-flash-free"
    },
    {
      "id": "gpt-6-luna",
      "vendor": "opencode",
      "name": "GPT-6 Luna",
      "aliases": [
        "gpt-6-luna"
      ],
      "status": "active",
      "kind": "chat",
      "plan": "go",
      "capabilities": [
        "text",
        "vision",
        "tools",
        "streaming"
      ],
      "limits": {
        "context": null,
        "output": null
      },
      "protocol": "openai-chat",
      "endpoint": {
        "base_url": "https://opencode.ai/zen/go/v1",
        "path": "/chat/completions"
      },
      "auth": {
        "type": "bearer",
        "env": "OPENCODE_API_KEY"
      },
      "pricing": {
        "free": false,
        "currency": "USD",
        "note": "Go 套餐 / 按量付费"
      },
      "constraints": [
        "endpoint 必须与套餐匹配：Go 套餐走 /zen/go/v1。",
        "请求需带 x-opencode-session 头，否则返回 400 MissingSessionID。"
      ],
      "errors": [
        {
          "code": 400,
          "match": "MissingSessionID",
          "docs": "https://opencode.ai/docs/go/"
        },
        {
          "code": 429,
          "match": "GoUsageLimitError",
          "docs": "https://opencode.ai/docs/go/"
        },
        {
          "code": 402,
          "match": "Insufficient account funds",
          "docs": "https://opencode.ai/docs/"
        }
      ],
      "docs": [
        {
          "title": "OpenCode Go",
          "url": "https://opencode.ai/docs/go/"
        }
      ],
      "ui": [
        "opencode/add-key"
      ],
      "verified": {
        "at": "2026-10-20",
        "method": "curl 实测",
        "scope": "endpoint、400/402/429 行为"
      },
      "notes": "context 未核对。",
      "ref": "opencode/gpt-6-luna"
    }
  ],
  "ui_steps": [
    {
      "id": "add-key",
      "vendor": "opencode",
      "title": "在 OpenCode 控制台创建 API Key",
      "applies_to": [
        "web"
      ],
      "url": "https://opencode.ai/auth",
      "steps": [
        "打开 https://opencode.ai/auth 并登录。",
        "进入 API Keys（或 Zen）页面。",
        "创建新的 key，复制 oc_sk_ 开头的字符串（只显示一次）。",
        "写入客户端密钥配置，例如 ~/.codex/.env 的 OPENCODE_API_KEY。",
        "注意：免费档模型仍要求由 OpenCode 客户端发起请求，外部客户端会 403。"
      ],
      "notes": "标准控制台流程，尚未逐步截图核对。",
      "updated": "2026-10-20",
      "verified": false,
      "ref": "opencode/add-key"
    }
  ]
}
