mirror of
https://github.com/bitbaum/ai-kit.git
synced 2026-12-04 08:33:01 +01:00
Found converting botsmann: its OpenRouter call sends HTTP-Referer and X-Title, which OpenRouter reads for app attribution in its public rankings. complete() had no way to send them, so adopting the engine would have dropped botsmann off that list with no error anywhere — exactly the kind of small, invisible regression that makes a shared package feel worse than the hand-rolled client it replaced. `authorization` is merged AFTER extraHeaders and cannot be overridden. A typo in a caller's header map must not become someone else's credential on the wire, or an auth failure blamed on the vendor. Both properties verified by mutation: dropping the spread turns the attribution test red, and moving it after `authorization` turns the override test red. Claude-Session: https://claude.ai/code/session_01NHDLTKGirKU7He8q2YR2y4 Co-authored-by: Claude Opus 5 <noreply@anthropic.com>