Skip to content

Video Generation

Generate videos with any video model available on ImageRouter.

Videos are in Beta, this API can change later.

Terminal window
curl 'https://api.imagerouter.io/v1/openai/videos/generations' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'Content-Type: application/json' \
--data-raw '{"prompt": "YOUR_PROMPT", "model": "ir/test-video"}'

Parameters

  • prompt* Text prompt for generating the video.
  • model* Video model to use.
  • size - Accepted values are different for each model.
    • auto [default] - Uses the default recommended size for each model.
    • WIDTHxHEIGHT (eg 1024x576)
  • response_format
    • url [default] - Returns the video URL hosted on ImageRouter’s servers. The video is accessible in your logs. and is publicly accessible with the URL if you share it.
    • b64_json - Returns the video as base64-encoded JSON data. The video is saved in your logs and is publicly accessible with the URL if you share it.
    • b64_ephemeral - Same as b64_json but the video is not saved in our system. The provider may still have it.
  • image[] One or more input images.