generate_video_with_reference
Generate a video using up to 7 reference images (r2v — e.g. a consistent character/subject across the video). reference_images_base64: raw base64-encoded image bytes (no data: URI prefix), up to 7 with Omni Flash keys (abra_r2v_*, the default), up to 3 with Veo r2v keys (veo_3_1_r2v_*). Mutually exclusive with start-image (i2v) generation.
THIS IS THE RECOMMENDED WAY to get content that actually looks like a real person
from a real photo — confirmed live 2026-07-11: r2v conditions generation on the
reference photo's actual pixels and reliably preserves the real face, unlike the
character system's `generate_character_image`/`generate_character_turnaround`
(those condition on a TEXT description + a loosely-attached reference and were
confirmed to drift to an unrelated-looking person). For a still IMAGE rather than
video, use this and read `first_frame_path` (or `last_frame_path`) off the result once done (via
check_job) — same-day testing found no reliable image-only equivalent: a plain
generate_image call with image_inputs pointed at an external photo was confirmed
to silently ignore the reference entirely.
project_id: put the clip into a project made with create_project instead of the
account's default one.
entity_id: optional — the entityId of a character you created and voiced with
set_character_voice. Only meaningful together with video_model_key="veo_3_1_r2v_lite"
(the one r2v model that generates speech natively); for abra_r2v_* models passing
entity_id has no effect (and was known to 500 historically). When set with the right
model, Flow attaches the character's audioReferences and lip-syncs the generated
speech in the assigned TTS voice. The job runs on the character's own Google account
(that's where the entity and its audioReferences live) — so an account different
from your other calls is normal here, no action needed.
voice / voice_style / voice_text: optional one-shot narration without creating a
character. Pass a voice name from list_voices() (e.g. "Algieba") and either a
voice_text or embed the spoken line in the prompt between quotes. Mutually
exclusive with entity_id — a character already carries its own voice. Only works
with speech-capable r2v models (veo_3_1_r2v_lite).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| seed | No | ||
| voice | No | ||
| aspect | No | VIDEO_ASPECT_RATIO_LANDSCAPE | |
| prompt | Yes | ||
| entity_id | No | ||
| project_id | No | ||
| voice_text | No | ||
| voice_style | No | ||
| include_preview | No | ||
| video_model_key | No | abra_r2v_4s | |
| reference_images_base64 | Yes |