메인 콘텐츠로 건너뛰기
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": "http://baidu.com",
  "ratio": "16:9",
  "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": 123,
  "msg": "<string>",
  "data": {
    "task_id": "<string>"
  },
  "exec_time": 123
}
이 엔드포인트를 사용해 Runway 호환 포맷 GEN-4 텍스트-비디오 작업을 시작하세요.

필수 필드

  • callback_url은 필수입니다
  • prompt, ratio, style, model이 생성 요청을 정의합니다
  • options.secondsoptions.motion_vector는 필수입니다

검증된 요청 경로

  • 헤더: X-Runway-Version: 2024-11-06
  • 모델: gen4_turbo
  • 응답: code: 200, msg: 成功, 그리고 data.task_id

작업 흐름

1

작업 생성

요청을 제출하고 반환된 task_id를 저장합니다.
2

호환 포맷 피드 경로 폴링

작업 상태를 추적하려면 피드 작업 가져오기를 계속 진행하세요.
3

완료된 에셋 저장

비디오 URL을 사용할 수 있게 되면, 이를 자체 스토리지 파이프라인으로 이동하세요.

인증

Authorization
string
header
필수

Bearer token authentication. Use your CometAPI key.

헤더

X-Runway-Version
string

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

본문

application/json
callback_url
string
기본값:https://example.com/webhook
필수

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

ratio
string
기본값:16:9
필수

Aspect ratio of the generated video, e.g. 16:9, 9:16, 1:1.

prompt
string
기본값:A cat sitting on a windowsill.
필수

Text prompt describing the video content to generate.

style
string
기본값:cinematic
필수

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

model
string
기본값:gen4
필수

Model version to use, e.g. gen4.

options
object
필수

Advanced generation options including duration and camera motion.

응답

200 - application/json

OK

code
integer
필수

HTTP status code or business status code

msg
string
필수

Text description of the status code

data
object
필수

Business data body containing detailed task information

exec_time
number
필수

Execution time of the API interface itself (in seconds), does not represent the total video generation time