Skip to content

anthropic Missing API key #4323

@daidaiJ

Description

@daidaiJ

What happened?

我在使用anthropic 模型供应商时发现

版本0.15.11
我自己做了一个http 透明代理debug 了一下请求头
{"timestamp":"2026-05-19T18:19:53.3848857+08:00","type":"request","method":"POST","path":"/v1/messages","headers":{"Accept":"application/json","Accept-Encoding":"gzip,deflate","Anthropic-Version":"2023-06-01","Authorization":"Bearer sk-xxx-my-api-key","Connection":"keep-alive","Content-Length":"52624","Content-Type":"application/json","User-Agent":"claude-cli/0.15.11 (external, cli)","X-App":"cli","X-Stainless-Arch":"x64","X-Stainless-Lang":"js","X-Stainless-Os":"Windows","X-Stainless-Package-Version":"0.36.3","X-Stainless-Retry-Count":"0","X-Stainless-Runtime":"node","X-Stainless-Runtime-Version":"v22.16.0"}}
发现请求头和cherry studio的不一致,它那边用的X-Api-Key

What did you expect to happen?

是否可以在请求里面同时携带这两者,让opencode go 的anthropic 端点可以鉴权通过

Client information

Client Information

Run qwen to enter the interactive CLI, then run the /about command.

$ qwen /about
# paste output here

│ Qwen Code 0.15.11 (782403d)
│ 运行环境 Node.js v22.16.0 / npm 11.7.0

Login information

No response

Anything else we need to know?

No response

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions