Gemini Omni

Webhooks

Receive job completion events without polling. Ideal for serverless architectures.

How it works

Pass a callbackUrl in your generation request. When the job completes (success or failure), we POST to your URL with the job result. No polling required.

Webhook payload

// POST to your callbackUrl
{
  "jobId": "job_abc123",
  "status": "done",           // "done" | "failed"
  "resultUrls": [
    "https://cdn.googlegeminiomni.com/omni/user_id/job_abc123/output.mp4"
  ],
  "creditsUsed": 150,
  "completedAt": "2026-06-05T10:01:23Z",
  "error": null               // string if status === "failed"
}

Security

Webhook payloads include an X-Gemini-Signature header an HMAC-SHA256 of the raw request body using your account's webhook secret. Verify this signature before processing the payload.

// Node.js verification example
import crypto from 'crypto';

const sig = req.headers['x-gemini-signature'];
const expected = crypto
  .createHmac('sha256', process.env.WEBHOOK_SECRET)
  .update(rawBody)
  .digest('hex');

if (!crypto.timingSafeEqual(Buffer.from(sig), Buffer.from(expected))) {
  return res.status(401).send('Invalid signature');
}

Retry policy

We retry failed webhook deliveries up to 3 times with exponential backoff (30s, 5min, 30min). A delivery is considered failed if your endpoint returns a non-2xx status code or times out after 10 seconds.