mirror of
https://github.com/coder/coder.git
synced 2026-06-02 20:48:20 +00:00
a86b8ab6f8
### Changes **coder/coder:** - `coderd/aibridge/aibridge.go` — Added `HeaderCoderBYOKToken` constant, `IsBYOK()` helper, and updated `ExtractAuthToken` to check the BYOK header first. - `enterprise/aibridged/http.go` — BYOK-aware header stripping: in BYOK mode only the BYOK header is stripped (user's LLM credentials preserved); in centralized mode all auth headers are stripped. <hr/> **NOTE**: `X-Coder-Token` was removed! As of now `ExtractAuthToken` retrieves token either from `X-Coder-AI-Governance-BYOK-Token` or from `Authorization`/`X-Api-Key`. --------- Co-authored-by: Susana Ferreira <susana@coder.com> Co-authored-by: Danny Kopping <danny@coder.com>