Quota exceeded. please try again

In Google AI Studio Build, the Code Assistant chat fails with JetskiAgentService.InvokeAgent ... INVALID_ARGUMENT: API key expired, even though:

  • the same paid Gemini API key works successfully against generativelanguage.googleapis.com via curl,

  • GEMINI_API_KEY is set in Secrets,

  • GOOGLE_API_KEY was also added with the same value,

  • the project was remixed and the issue persists,

  • Chat settings explicitly show “You’re currently using your API key”.

This suggests the Build Code Assistant runtime is not using the same effective authentication context as the direct Gemini API.