Maak een Runway image-to-video-taak
Gebruik CometAPI om Runway image_to_video aan te roepen en een URL van een stilstaand beeld om te zetten in raw video output, met ondersteuning voor X-Runway-Version voor compatibiliteit.
Voordat je het aanroept
- Stuur de vereiste
X-Runway-Version-header mee, bijvoorbeeld2024-11-06 - Gebruik
model: gen3a_turbo - Geef een stabiele HTTPS-
promptImageop - Begin met
duration: 5en een ondersteunde ratio-waarde voor het geselecteerde Runway-model/de geselecteerde versie
Duration en ratio
ratio, niet size. Lees resolutie-achtige ratio-waarden als hun WxH-equivalent: 1280:720 richt zich op 1280x720, 720:1280 richt zich op 720x1280, en 1280:768 kan nog steeds renderen als 1280x720, afhankelijk van het geselecteerde model/de geselecteerde versie.
Taakstroom
Dien het image-to-video-verzoek in
Sla de geretourneerde id op
id om later te pollen.Poll taakstatus
task_not_exist retourneert, wacht dan een paar seconden en probeer het opnieuw.Autorisaties
Bearer token authentication. Use your CometAPI key.
Headers
Runway version header, for example 2024-11-06.
Body
Source image URL.
Runway image-to-video model ID. Choose an available model from the Models page.
Random seed for reproducible results. Range: 0–999999999.
Text prompt describing the desired motion or scene. Maximum 512 characters.
Whether to add a watermark to the output video.
Video duration in seconds. Runway support is model/version dependent; use 5 or 10 for the broadest compatibility. CometAPI forwards this value to Runway.
Requested output ratio. Accepted values are Runway model/version dependent. With X-Runway-Version 2024-11-06, use a resolution-style value accepted by the selected model, such as 1280:768, 768:1280, 1280:720, or 720:1280. Read these as WxH targets, but completed media may normalize, so inspect the returned file before relying on exact pixels.
Respons
Task accepted.