unexpected status 404 Not Found: CC Switch local proxy failed while handling Cod...
错误信息
unexpected status 404 Not Found: CC Switch local proxy failed while handling Codex endpoint /responses. Provider: DMXAPI; model: deepseek-v4-flash; upstream_status: HTTP 404; cause: Invalid URL (POST /v1/chat/completions/responses), url: http://127.0.0.1:15721/v1/responses
AI 解决方案
🔍 报错分析
1. 🌐 错误翻译
原文:unexpected status 404 Not Found: CC Switch local proxy failed while handling Codex endpoint /responses. Provider: DMXAPI; model: deepseek-v4-flash; upstream_status: HTTP 404; cause: Invalid URL (POST /v1/chat/completions/responses), url: http://127.0.0.1:15721/v1/responses
译文:意外状态404未找到:CC Switch本地代理在处理Codex端点/responses时失败。提供商:DMXAPI;模型:deepseek-v4-flash;上游状态:HTTP 404;原因:无效URL(POST /v1/chat/completions/responses),URL:http://127.0.0.1:15721/v1/responses
2. 🎯 原因分析
http://127.0.0.1:15721/v1/responses,但该路径不存在,返回404错误。/v1/chat/completions,但当前配置错误地指向了/v1/responses。3. 💡 解决方案
检查并修正API请求的端点URL配置,将错误的
/v1/responses更正为正确的Chat Completions端点:{
"api_url": "http://127.0.0.1:15721/v1/chat/completions"
}
或根据实际SDK/代码框架,修正发送请求时的URL地址:
// 修复前:
const response = await fetch('http://127.0.0.1:15721/v1/responses', { ... });
// 修复后:
const response = await fetch('http://127.0.0.1:15721/v1/chat/completions', { ... });