Self Checks / 自检
CC Switch Version / 版本号
v3.16.1
Operating System / 操作系统
macOS
Related App / 涉及应用
Codex
Steps to Reproduce / 重现步骤
Description
The cc-switch-model-catalog.json generated by CC Switch does not conform to the Codex CLI model catalog schema, causing Codex to fail on startup. The file is also overwritten every time a model is switched or a Provider is edited, invalidating any manual fixes.
Error Messages
The following errors appear sequentially:
unknown variant public, expected one of list, hide, none
missing field supported_reasoning_levels
missing field shell_type
Analysis
The generated JSON has two issues:
Invalid visibility value — Codex only accepts list / hide / none, not public
Missing required fields — supported_reasoning_levels, shell_type, input_modalities, supports_reasoning_summaries, etc.
Expected Behavior / 期望行为
The generated catalog should include all fields required by Codex. Reference schema from ~/.codex/model.json:
json
{
"models": [{
"slug": "model-name",
"display_name": "Model Name",
"context_window": 200000,
"max_context_window": 200000,
"input_modalities": ["text"],
"shell_type": "default",
"supported_reasoning_levels": [],
"supports_reasoning_summaries": false,
"supports_parallel_tool_calls": false,
"support_verbosity": true,
"supported_in_api": true,
"default_verbosity": "low",
"visibility": "list",
"priority": 1000
}]
}/
Actual Behavior / 实际行为
No response
Additional Context / 补充信息
No response
Self Checks / 自检
I have read the FAQ section in README.
我已阅读 README 中的常见问题。
I have searched for existing issues, including closed ones.
我已搜索过已有的 Issue,包括已关闭的。
CC Switch Version / 版本号
v3.16.1
Operating System / 操作系统
macOS
Related App / 涉及应用
Codex
Steps to Reproduce / 重现步骤
Description
The cc-switch-model-catalog.json generated by CC Switch does not conform to the Codex CLI model catalog schema, causing Codex to fail on startup. The file is also overwritten every time a model is switched or a Provider is edited, invalidating any manual fixes.
Error Messages
The following errors appear sequentially:
unknown variant
public, expected one oflist,hide,nonemissing field
supported_reasoning_levelsmissing field
shell_typeAnalysis
The generated JSON has two issues:
Invalid visibility value — Codex only accepts list / hide / none, not public
Missing required fields — supported_reasoning_levels, shell_type, input_modalities, supports_reasoning_summaries, etc.
Expected Behavior / 期望行为
The generated catalog should include all fields required by Codex. Reference schema from ~/.codex/model.json:
json
{
"models": [{
"slug": "model-name",
"display_name": "Model Name",
"context_window": 200000,
"max_context_window": 200000,
"input_modalities": ["text"],
"shell_type": "default",
"supported_reasoning_levels": [],
"supports_reasoning_summaries": false,
"supports_parallel_tool_calls": false,
"support_verbosity": true,
"supported_in_api": true,
"default_verbosity": "low",
"visibility": "list",
"priority": 1000
}]
}/
Actual Behavior / 实际行为
No response
Additional Context / 补充信息
No response