跳轉到主要內容
POST
/
runwayml
/
v1
/
video_to_video
Generate a video from a video
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://filesystem.site/cdn/20250818/c4gCDVPhiBc6TomRTJ7zNg0KwO1PSJ.mp4",
  "promptText": "string",
  "seed": 4294967295,
  "model": "gen4_aleph",
  "references": [
    {
      "type": "image",
      "uri": "https://cdn.britannica.com/70/234870-050-D4D024BB/Orange-colored-cat-yawns-displaying-teeth.jpg"
    }
  ],
  "ratio": "1280:720",
  "contentModeration": {
    "publicFigureThreshold": "auto"
  }
}
'
{}
使用此端點可透過 Runway 的影片轉影片工作流程轉換現有的來源片段。它會啟動非同步任務,而不是立即回傳最終輸出。

呼叫前準備

  • 準備符合供應商輸入需求的來源影片
  • 為你想使用的功能集加入必要的 X-Runway-Version header
  • 先從一段描述變更內容的簡短 Prompt 開始,而不是完整分鏡腳本

任務流程

1

提交來源片段與 Prompt

透過此端點啟動任務,並保存回傳的 task id。
2

輪詢任務詳情

使用 Runway 取得任務詳情,直到任務進入終止狀態。
3

儲存轉換結果

透過你既有的媒體處理流程下載或持久化已完成的資產。

CometAPI 包裝層說明

CometAPI 保留了 Runway 的非同步任務模型與版本化請求行為,但將驗證與 base URL 處理方式與平台其餘部分統一起來。

授權

Authorization
string
header
必填

Bearer token authentication. Use your CometAPI key.

標頭

X-Runway-Version
string
必填

Runway API version header, for example 2024-11-06.

主體

application/json
videoUri
string
預設值:https://filesystem.site/cdn/20250818/c4gCDVPhiBc6TomRTJ7zNg0KwO1PSJ.mp4
必填

HTTPS URL of the source video, or a base64 data URI containing the video.

promptText
string
預設值:A cat yawning in slow motion.
必填

Text prompt describing the desired output. Maximum 1000 characters.

seed
integer
預設值:1
必填

Random seed for reproducible results. Range: 0–4294967295.

model
string
預設值:gen4_aleph
必填

Model variant to use.

references
object[]
必填

Optional reference images to guide generation. Each item must include type (e.g. image) and uri (HTTPS URL).

ratio
string
預設值:1280:720
必填

Aspect ratio of the output video, e.g. 1280:720.

contentModeration
object
必填

回應

200 - application/json

success

The response is of type object.