Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ Official OpenCode Go HTTPS endpoints under `https://opencode.ai/zen/go` receive

登录完成后,`CodexOAuthManager` 从当前 profile 的 `codex-auth.json` 获取凭据,复用
`AuthStorage` 的刷新机制和宿主 `fetch`,请求
`https://chatgpt.com/backend-api/codex/models?client_version=0.153.0`。
`https://chatgpt.com/backend-api/codex/models?client_version=0.162.0`。
`connectivity/codex-model-discovery.ts` 负责这个独立的 Codex 协议。兼容版本来自已验证的
Codex 客户端协议,与 MiniMax Code 产品版本独立;模型 ID 和思考等级由响应提供。OAuth 解析复用可配置思考协议,将远端等级原样映射到请求;
`ultra` 等新增等级不依赖 Pi 的静态等级枚举。
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -795,7 +795,7 @@ describe("Codex OAuth profile credentials", () => {
fetch: fetchImpl,
});
expect(fetchImpl).toHaveBeenCalledWith(
expect.stringContaining("/codex/models?"),
"https://chatgpt.com/backend-api/codex/models?client_version=0.162.0",
expect.objectContaining({
headers: expect.objectContaining({
Authorization: "Bearer fresh",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import type { LocalCustomProviderConfig, LocalModelConfig } from '../contracts.j

const CODEX_BASE_URL = 'https://chatgpt.com/backend-api';
// Codex model discovery negotiates against the Codex client version, independent of our app version.
const CODEX_CATALOG_CLIENT_VERSION = '0.153.0';
const CODEX_CATALOG_CLIENT_VERSION = '0.162.0';

export interface CodexModelCredentials {
access: string;
Expand Down
Loading