Skip to main content

Overview

Runware exposes a single synchronous endpoint (https://api.runware.ai/v1) that accepts an array of tasks. Bifrost wraps each request in this array envelope and maps the unified image and video schemas onto Runware’s imageInference and videoInference task types. Image tasks return synchronously; video tasks are submitted asynchronously and polled to completion.

Supported Operations

OperationSupportedTask Type
Image GenerationimageInference
Image Edit (inpainting / outpainting)imageInference
Video GenerationvideoInference (async)
Video RetrievegetResponse
Video Downloadvia Retrieve + URL download
Image Variation-
Image / Image Edit (stream)-
Video Delete / List / Remix-

1. Image Generation

Generate (POST /v1/images/generations)

ParameterTypeRequiredRunware fieldNotes
modelstringmodelRunware model (AIR identifier)
promptstringpositivePromptText description of the image
negative_promptstringnegativePromptWhat to avoid
sizestringwidth / heightWxH (e.g. 1024x1024; default 1024x1024)
num_inference_stepsintstepsDiffusion steps
seedintseedSeed for reproducibility
nintnumberResultsNumber of images
response_formatstringoutputTypeurlURL, b64_jsonbase64Data
output_formatstringoutputFormatpng/jpeg/webpPNG/JPG/WEBP
Extra Params: pass a seedImage (a Runware image UUID, public URL, or base64/data-URI) to run image-to-image. Any other provider-native fields flow through extra_params. Response: BifrostImageGenerationResponse with data[].url or data[].b64_json.

Example

curl -X POST http://localhost:8080/v1/images/generations \
  -H "Content-Type: application/json" \
  -d '{
    "model": "runware/runware:100@1",
    "prompt": "A serene mountain landscape at sunset",
    "size": "1024x1024",
    "n": 1
  }'

2. Image Edit

Edit (POST /v1/images/edits)

The first input image becomes the seedImage; supplying a mask enables inpainting. Outpainting and other provider-native fields flow through extra_params.
ParameterRunware fieldNotes
image[] (first)seedImageBase image being edited (bytes → data URI)
maskmaskImageInpainting mask (bytes → data URI)
promptpositivePromptEdit instruction
negative_prompt, size, num_inference_steps, seed, n, response_format, output_formatsame as Image Generation

Example

curl -X POST 'http://localhost:8080/v1/images/edits' \
  --form 'model="runware/runware:100@1"' \
  --form 'image[]=@"image.png"' \
  --form 'prompt="Replace the sky with a starry night"' \
  --form 'mask=@"mask.png"'
Response: same shape as Image Generation (data[].url or data[].b64_json).

3. Video Generation

Generate (POST /v1/videos)

Video tasks are submitted with deliveryMethod: async and return a queued job. Poll Retrieve until status: completed, then download.
ParameterTypeRequiredRunware fieldNotes
modelstringmodelRunware video model
promptstringpositivePromptText description of the video
input_referencestringframeImages[0]Reference image anchored to the first frame → image-to-video
negative_promptstringnegativePromptWhat to avoid
seedintseedSeed for reproducibility
sizestringwidth / heightWxH (default 1920x1080)
secondsstringdurationDuration in seconds
Extra Params: provider-native fields flow through extra_params. Response: BifrostVideoGenerationResponse with id, status, videos[]. Generation Modes (auto-detected): text-to-video (prompt only) · image-to-video (prompt + input_reference). Bifrost statuses (normalized): queuedin_progresscompleted / failed. Runware’s native statuses are processing, success, error.

Retrieve / Download

OperationEndpointNotes
Get statusGET /v1/videos/{id}Polls via a getResponse task; poll until status: completed
Download contentGET /v1/videos/{id}/contentDownloads raw video bytes (MP4) from the task’s output URL
Video Delete, List, and Remix are not supported by Runware.

Setup & Configuration

Configure Runware as a provider.
  1. Navigate to Models > Model Providers. Look for Runware under Configured Providers. If it is missing, click on Add New Provider and select Runware.
  2. Click Add Key or edit an existing key.
  3. Set a name for your key.
  4. Paste your API key directly or use an environment variable (for example, env.RUNWARE_API_KEY).
  5. Set Allowed Models to All Models (default) or the specific model allowlist you want this key to serve.
  6. Save the provider configuration.