Skip to main content
POST
/
runway
/
pro
/
generate
generate(text)
curl --request POST \
  --url https://api.cometapi.com/runway/pro/generate \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "callback_url": "https://example.com/webhook",
  "ratio": "1280:720",
  "prompt": "a cat",
  "style": "cinematic",
  "model": "gen4",
  "options": {
    "seconds": 10,
    "motion_vector": {
      "x": 0,
      "y": 0.3999999999999999,
      "z": 0,
      "r": -6,
      "bg_x_pan": 0,
      "bg_y_pan": 0
    }
  }
}
'
{
  "code": 200,
  "message": "",
  "msg": "success",
  "data": {
    "task_id": "196642a0-05e1-441a-981e-eb0c1f5d983b"
  }
}
Use this endpoint to start a Runway compatibility-format GEN-4 text-to-video task.

Required fields

  • callback_url is required
  • prompt, ratio, style, and model define the generation request
  • options.seconds and options.motion_vector are required

Validated request path

  • Header: X-Runway-Version: 2024-11-06
  • Model: gen4_turbo
  • Response: code: 200, msg: success, and data.task_id

Duration and ratio

SettingSupported valuesDefault starting pointBoundary behavior
options.seconds5, 10 for standard Runway video generations5Some compatibility examples use 1 for smoke tests, but production clips should use the model-supported duration values.
ratio1280:720, 720:1280, 960:960; some workflows also accept 16:9, 9:16, 1:11280:720Use colon-separated WxH ratios when you need predictable Runway frames. Treat 1280:720 as a 1280x720 target, 720:1280 as 720x1280, and 960:960 as 960x960.

Task flow

1

Create the task

Submit the request and store the returned task_id.
2

Poll the compatibility-format feed route

Continue with Feed Get Task to follow the task state.
3

Persist the finished asset

Once a video URL is available, move it into your own storage pipeline.

Authorizations

Authorization
string
header
required

Bearer token authentication. Use your CometAPI key.

Headers

X-Runway-Version
string

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

Body

application/json
callback_url
string
default:https://example.com/webhook
required

Webhook URL that receives a POST request with the result when the task completes.

ratio
string
default:1280:720
required

Frame ratio for the generated video. Use colon-separated WxH ratio values such as 1280:720, 720:1280, or 960:960 when you need predictable Runway frames; some workflows also accept aspect-ratio labels such as 16:9, 9:16, and 1:1.

prompt
string
default:A cat sitting on a windowsill.
required

Text prompt describing the video content to generate.

style
string
default:cinematic
required

Artistic style for the generated video, e.g. cinematic.

model
string
default:gen4
required

Model version to use, e.g. gen4.

options
object
required

Advanced generation options including duration and camera motion.

Response

200 - application/json

OK

code
integer
required

HTTP status code returned by the task service.

data
object
required
message
string

Empty on success.

msg
string

Result message.