使用 CometAPI Runway POST /runwayml/v1/video_to_video 啟動影片轉影片生成任務、設定 X-Runway-Version,並轉換來源片段。
curl --request POST \
--url https://api.cometapi.com/runwayml/v1/video_to_video \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Runway-Version: <x-runway-version>' \
--data '
{
"videoUri": "https://media.w3.org/2010/05/sintel/trailer.mp4",
"promptText": "Make the motion feel cinematic.",
"model": "gen4_aleph",
"references": [
{
"type": "image",
"uri": "https://res.cloudinary.com/demo/image/upload/dog.jpg"
}
],
"ratio": "1280:720"
}
'{
"id": "12a01a5e-ab55-4aa7-b002-7b873546cf76"
}使用此端點可透過 Runway 的影片轉影片工作流程轉換現有的來源片段。它會啟動非同步任務,而不是立即回傳最終輸出。Documentation Index
Fetch the complete documentation index at: https://apidoc.cometapi.com/llms.txt
Use this file to discover all available pages before exploring further.
X-Runway-Version 標頭,以使用你想要的功能集輪詢任務詳細資料
Bearer token authentication. Use your CometAPI key.
Runway API version header, for example 2024-11-06.
HTTPS URL of the source video, or a base64 data URI containing the video.
Text prompt describing the desired output. Maximum 1000 characters.
Random seed for reproducible results. Range: 0–4294967295.
Model variant to use.
Optional reference images to guide generation. Each item must include type (e.g. image) and uri (HTTPS URL).
Show child attributes
Aspect ratio of the output video, e.g. 1280:720.
Show child attributes
success
The ID of the task that was created. Use this to retrieve the task later.
curl --request POST \
--url https://api.cometapi.com/runwayml/v1/video_to_video \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Runway-Version: <x-runway-version>' \
--data '
{
"videoUri": "https://media.w3.org/2010/05/sintel/trailer.mp4",
"promptText": "Make the motion feel cinematic.",
"model": "gen4_aleph",
"references": [
{
"type": "image",
"uri": "https://res.cloudinary.com/demo/image/upload/dog.jpg"
}
],
"ratio": "1280:720"
}
'{
"id": "12a01a5e-ab55-4aa7-b002-7b873546cf76"
}