Gemini-omni-flash-preview: video + image input returns 400 invalid_request

I have an issue with referring image and video to generate videos using gemini-omni-flash-preview.

This have been working for weeks but suddenly it stopped working today.

Environment:

  • Model: gemini-omni-flash-preview
  • API: Gemini API with API key
  • SDK: google-genAI, Python 3.12
  • Task: edit an uploaded MP4 and return a video

What works

  • Editing video with just text prompts works

What fails

  • Editing video with text and images does not work

Error

  • BadRequestError: Error code: 400
  • “message”: “Request contains an invalid argument.”, “code”: “invalid_request”

Could someone check whether the video editing feature is still been supported?

Hello @keiichi ,

When combining reference images with video input for gemini-omni-flash-preview, please ensure your request explicitly specifies video_config={“task”: “reference_to_video”} inside GenerationConfig.
If you are already passing this task parameter, could you please share a minimal Python code snippet so we can investigate further?

it seems to be solved. thank you.