Diag: add debug logs for API key and URL

This commit is contained in:
stevef 2026-04-13 09:42:05 +02:00
parent c0d90f2ca8
commit eaee2fb7d7

View file

@ -227,6 +227,8 @@ func (p *Provider) Chat(
req.Header.Set("User-Agent", p.userAgent) req.Header.Set("User-Agent", p.userAgent)
} }
if p.apiKey != "" { if p.apiKey != "" {
log.Printf("DEBUG: apiKey length: %d", len(p.apiKey))
log.Printf("DEBUG: sending request to: %s", req.URL.String())
if p.useAzureHeaders { if p.useAzureHeaders {
req.Header.Set("api-key", p.apiKey) req.Header.Set("api-key", p.apiKey)
} else { } else {