Skip to main content
POST
/
v1beta
/
models
/
{model}
:predictLongRunning
Gemini predictLongRunning
curl --request POST \
  --url http://sandbox.mintlify.com/v1beta/models/{model}:predictLongRunning \
  --header 'Content-Type: application/json' \
  --header 'x-goog-api-key: <api-key>' \
  --data '
{
  "instances": [
    {
      "prompt": "一只小猫在花园中奔跑"
    }
  ],
  "parameters": {
    "durationSeconds": 5,
    "aspectRatio": "16:9"
  }
}
'
{
  "name": "operations/abc123",
  "done": false,
  "metadata": {
    "progressPercent": 0
  }
}
Use this endpoint to submit Veo-style long-running video-generation requests.
  • The common auth pattern is x-goog-api-key: {API_KEY}, though query-string API keys are also supported
  • This endpoint returns a long-running operation handle rather than the final video content
  • Persist the returned operation name or ID for later polling
  • You must poll /v1beta/operations/{operation_id} to track completion

Authorizations

x-goog-api-key
string
header
required

Path Parameters

model
string
required

Gemini model name.

Example:

"veo-3.0-generate-preview"

Body

application/json
instances
object[]
required
parameters
object

Response

Successful long-running operation creation response

name
string
metadata
object
done
boolean
response
object
error
object