Google’s Gemini CLI strips stray Authorization headers to fix API-key 401s
loulanyue · ghdev · 2026-07-27
What changed
Google’s gemini-cli fixes a bug where, in GEMINIAPIKEY mode, a leftover Authorization header could override the intended x-goog-api-key auth path and trigger 401 UNAUTHENTICATED ACCESSTOKENTYPEUNSUPPORTED errors on generativelanguage.googleapis.com.
Details
- The patch removes both Authorization and authorization from request headers when using AuthType.USEGEMINI with the default API-key mechanism.
- The change is covered by a unit test in contentGenerator.test.ts.
- The PR reports all tests passing (56 passed).
More from coding & agent
- Dev claims 20k more commits coming: Opus 5.5 and GPT-6 Sol supercharge his output — doodlestein · 2026-09-23
- A JEV-powered Wireshark classifier accidentally uncovered real backdoors on a home network — multiply_matrix · 2026-09-23
- 299 real intents tested: classifier routing trails GLM-4-Flash by 3 points but is 6.5x faster — Sufficient_Flower860 · 2026-09-23
- OpenExecutive: open-source virtual executive team of 8 specialist AI agents hits 5.1k GitHub stars — tom_doerr · 2026-09-23
- Framer launches Skills: teach your design agent reusable workflows, design systems and CMS rules — soleio · 2026-09-23
- Cursor, OpenAI and Anthropic shipped coordinator-agent fleets in one week, but the review bottleneck stays — omidfarhang · 2026-09-23