[Bug] 使用claude模型时,调用后端缺失Authorization header
📦 Deployment Method
Vercel
📌 Version
2.15.3
💻 Operating System
Windows
📌 System Version
win11 23H2 22631.4169
🌐 Browser
Edge
📌 Browser Version
129.0.2792.79
🐛 Bug Description
使用OpenAI模型时,请求头中包含Authorization header,接口正常返回。 使用Claude系列模型时,请求头中无此header,导致401报错
{
"error": true,
"msg": "empty access code"
}
后端日志:
/api/anthropic/v1/messages
[Auth] hashed access code: xxx
Oct 08 15:29:14.98
POST
---
/api/anthropic/v1/messages
[Auth] got access code:
---
/api/anthropic/v1/messages
[POST] /api/anthropic/v1/messages?nxtPprovider=anthropic&nxtPpath=v1%2Fmessages st
📷 Recurrence Steps
选择Claude系列模型,发送消息,返回401报错
🚦 Expected Behavior
正常返回调用结果
📝 Additional Information
No response
Bot detected the issue body's language is not English, translate it automatically.
Title: [Bug] When using the claude model, the Authorization header is missing when calling the backend
please test in v2.15.4
please test in v2.15.4
still the same
Is there any update on this issue?
I found out the solution. After updating, we have to reset the Custom Endpoint for Anthropic, including endpoint, API key and API version and use environment variable.
any news