Hi Gemini API Team,
Thank you for the recent release of Webhooks for Batch jobs and video generation! This is a massive step forward.
I am writing to request adding Webhook support (or an asynchronous LRO alternative) for the standard models.generateContent method, specifically when analyzing large files like video via the File API.
Our Use Case: I am developing the Kivu Super App for the East African market. We use Gemini 1.5 Flash via standard generateContent for automated content moderation, including a short-video module.
The Problem: Currently, the workflow requires uploading the video to the File API, waiting for the file to process (STATE.ACTIVE), and then calling generateContent. Because we run this logic on serverless environments (Supabase Edge Functions), making our functions “wait” synchronously for the video processing and the AI generation response leads to:
-
Function timeouts.
-
Unnecessary billing overhead for idle compute time.
-
Bad UX for users waiting for the upload to complete.
The Request: It would be incredibly helpful if we could pass a webhookConfig (Dynamic webhook) directly into the generateContent request, just like we now can for Batch jobs. This would allow us to fire the request to Gemini and instantly close our serverless function, letting your webhook ping our database receiver once the moderation verdict (APPROVED/REJECTED) is ready.
Are there any plans to expand dynamic webhooks to generateContent in the near future?
Thank you, Stanislau Managing Director, Kivu E-commerce