Merge pull request #66 from tbphp/fix-anthropic-checkkey

fix: 修复Anthropic测试Key问题
This commit is contained in:
tbphp
2025-07-26 23:00:58 +08:00
committed by GitHub

View File

@@ -96,6 +96,7 @@ func (ch *AnthropicChannel) ValidateKey(ctx context.Context, key string) (bool,
}
req.Header.Set("x-api-key", key)
req.Header.Set("anthropic-version", "2023-06-01")
req.Header.Set("Content-Type", "application/json")
resp, err := ch.HTTPClient.Do(req)
if err != nil {