You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[awf] api-proxy: GOOGLE_API_KEY invalid — all Smoke Gemini runs failing since 2026-04-29 #2296
All Smoke Gemini workflow runs have been failing since 2026-04-29 00:21 UTC with HTTP 400 INVALID_ARGUMENT / API_KEY_INVALID from generativelanguage.googleapis.com. The agent makes zero LLM calls, zero tool calls, and produces no output before terminating. This is a P0 blocker for all Gemini-based agentic workflows.
Run 25084493525 — branch copilot/align-docs-with-canonical-apm — 2026-04-29 00:21
Run 25085302973
Failure message:
HTTP 400 INVALID_ARGUMENT
reason: API_KEY_INVALID
service: generativelanguage.googleapis.com
message: "API key not valid. Please pass a valid API key."
Root Cause
The GOOGLE_API_KEY repository secret has expired or been rotated/revoked. This is an operational credential issue, not a code bug. However, AWF's Gemini proxy path may also be contributing: when --enable-api-proxy is active, the sidecar injects the key — if the sidecar has a bug in Gemini key injection (see also #25944 tracking issue), a valid-looking key could still be forwarded incorrectly.
Two possible root causes to rule out in order:
Secret expired — GOOGLE_API_KEY in the github/gh-aw Actions secrets is invalid/revoked
Proxy injection bug — the api-proxy sidecar doesn't correctly inject GOOGLE_API_KEY as a ?key= query parameter for Gemini requests
Proposed Solution
Immediate operational fix: Rotate the GOOGLE_API_KEY secret in the github/gh-aw repository Actions settings.
Verify proxy injection: After rotation, if failures persist, audit containers/api-proxy/ Gemini route handler to confirm the key is injected as ?key=<value> query parameter (not as Authorization: Bearer).
Add secret expiry alerting: Add a scheduled workflow that validates API keys with a cheap probe call and creates an issue if any key returns API_KEY_INVALID.
Add AWF startup validation: In the api-proxy sidecar startup, probe each configured API key and log a warning (not failure) if a key appears invalid, so the issue is caught before the agent runs.
Both issues describe the same API_KEY_INVALID error from generativelanguage.googleapis.com in the Smoke Gemini workflows, reference the api-proxy sidecar's GOOGLE_API_KEY injection, and were filed on the same date.
If #2288 already covers your concern, please consider closing this issue as a duplicate. Otherwise, feel free to clarify how your issue differs!
This is an automated message from the issue duplication detector.
Closing — this is an operational credential issue, not a code bug. The GOOGLE_API_KEY repository secret in github/gh-aw has expired or been revoked.
Resolution: Navigate to Settings → Secrets → Actions in the github/gh-aw repository and rotate/replace GOOGLE_API_KEY with a valid Gemini API key.
Code-side mitigation already in place: PR #2200 (merged Apr 24) added startup API key validation to the api-proxy sidecar, which catches invalid keys at container startup rather than at first LLM call. However, validation requires the upstream API to be reachable, so an expired key will still produce this error at the point of use.
Activity
github-actions commentedon Apr 29, 2026
👋 Hello! I noticed this issue might be a duplicate of an existing issue:
Both issues describe the same
API_KEY_INVALIDerror fromgenerativelanguage.googleapis.comin the Smoke Gemini workflows, reference theapi-proxysidecar'sGOOGLE_API_KEYinjection, and were filed on the same date.If #2288 already covers your concern, please consider closing this issue as a duplicate. Otherwise, feel free to clarify how your issue differs!
This is an automated message from the issue duplication detector.
lpcox commentedon Apr 29, 2026
Closing — this is an operational credential issue, not a code bug. The
GOOGLE_API_KEYrepository secret ingithub/gh-awhas expired or been revoked.Resolution: Navigate to Settings → Secrets → Actions in the
github/gh-awrepository and rotate/replaceGOOGLE_API_KEYwith a valid Gemini API key.Code-side mitigation already in place: PR #2200 (merged Apr 24) added startup API key validation to the api-proxy sidecar, which catches invalid keys at container startup rather than at first LLM call. However, validation requires the upstream API to be reachable, so an expired key will still produce this error at the point of use.