Hello everyone,
I’m hoping to get some help with a very strange issue on a new project. My application is completely blocked by a Vertex AI quota error, even though the console shows I have an approved, non-zero quota. I did contact google and requested an increase and it was approved
Application Architecture:
-
Backend: A Node.js Express server running on Cloud Run in
europe-west2. -
AI SDKs: Using the official (PII Removed by Staff) and (PII Removed by Staff) libraries.
-
Functionality:
-
The service successfully generates text and JSON using the
gemini-1.5-flashmodel. This works perfectly. -
The service then attempts to generate an image using an Imagen model. This step always fails.
-
The Problem:
Every API call to any available Imagen model (imagen-3.0-generate-002, imagen-3.0-fast-generate-001, etc.) fails with a 429 RESOURCE_EXHAUSTED (Quota Exceeded) error on the very first request.
However, the Quotas page in the Google Cloud Console clearly shows an approved, non-zero quota for these models. For example, base_model:imagen-3.0-generate has an approved limit of 5 requests/minute, and base_model:imagen-3.0-fast-generate has a limit of 20 requests/minute.
Summary of Our Troubleshooting (What We’ve Proven):
We have spent a long time debugging this and have successfully eliminated all common causes:
-
It is not a code issue: The error happens even with a minimal, standalone test script that makes a single API call.
-
It is not a model availability issue: We have confirmed via the interactive Vertex AI Studio UI that models like
imagen-3.0-generate-002,imagen-3.0-fast-generate-001are available and work for my account in theeurope-west2region. The API error is429, not404. -
It is not a permissions (IAM) issue: The service account running the code (
firebase-deploy-service-accoun **at** mats4u-genai-app.iam.gserviceaccount.com) has theEditorrole on the project, which includes all necessary permissions likeaiplatform.user. -
It is not a billing issue: Text generation with Gemini models is working and being billed correctly.
-
It is not an API enablement issue: The
aiplatform.googleapis.comAPI is enabled. -
It is not a concurrency issue: The error occurs even when the application is architected to make only a single image request.
Has anyone else experienced a situation where the Quotas page in the console shows an approved limit, but the Vertex AI API behaves as if the quota is zero? This seems to be a project-specific quota enforcement or synchronization bug.
