Official format
Create a Runway image
Use POST /runwayml/v1/text_to_image to start a Runway task that generates images from a text prompt, with X-Runway-Version support.
POST
cURL
Use this endpoint to create a Runway image-generation task.
Usage notes
- Send the required
X-Runway-Versionheader, for example2024-11-06 - Use
model: gen4_image - This route requires at least one
referenceImagesitem — a text-only request returnsreference_images_empty
Task flow
Submit the generation request
Send
promptText, ratio, model, and at least one referenceImages object.Poll the task
Use Get a Runway task. If an immediate poll returns
task_not_exist, wait a few seconds and retry.Authorizations
Bearer token authentication. Use your CometAPI key.
Headers
Runway version header, for example 2024-11-06.
Body
application/json
A non-empty string up to 1000 characters.
Aspect ratio of the output image, e.g. 1280:720.
Random seed for reproducible results.
The model variant to use.
An array of up to three images to be used as references. At least one item is required. referenceImages is required.
Response
200 - application/json
Task accepted.