Loading...
Loading...
Complete reference for Runway's public API: models, endpoints, costs, limits, and types
npx skill4agent add runwayml/skills api-referencePREREQUISITE: Runfirst to ensure the project has server-side capability.+check-compatibility
https://api.dev.runwayml.comAuthorization: Bearer <RUNWAYML_API_SECRET>
X-Runway-Version: 2024-11-06| Model | Endpoint | Input | Cost (credits/sec) |
|---|---|---|---|
| | Text and/or Image | 12 |
| | Image required | 5 |
| | Video + Text/Image | 15 |
| | Image/Video | 5 |
| | Text/Image | 40 |
| | Text/Image | 20-40 |
| | Text/Image | 10-15 |
1280:720720:12801104:832| Model | Endpoint | Cost (credits) |
|---|---|---|
| | 5 (720p), 8 (1080p) |
| | 2 |
| | 5 |
| Model | Endpoint | Use Case | Cost |
|---|---|---|---|
| | Text to speech | 1 credit/50 chars |
| | Sound effects | 1-2 credits |
| | Isolate voice from audio | 1 credit/6 sec |
| | Dub audio to other languages | 1 credit/2 sec |
| | Voice conversion | 1 credit/3 sec |
| Model | Description | Session Max Duration |
|---|---|---|
| Real-time conversational avatars powered by GWM-1 | 5 minutes |
| Method | Endpoint | Description |
|---|---|---|
| | Create a new Avatar |
| | Retrieve an Avatar |
| | Update an Avatar (name, voice, personality, documentIds) |
| | Delete an Avatar |
| | Create a new real-time session |
| | Retrieve session status (poll until |
| | Consume session credentials for WebRTC (one-time use) |
| Parameter | Type | Description |
|---|---|---|
| string | Display name for the avatar |
| string | URL or |
| object | |
| string | System prompt / personality instructions |
| string[] | Optional. IDs of knowledge base documents to attach |
claravictoriavincentNOT_READYREADYRUNNINGCOMPLETEDFAILEDCANCELLED| Method | Endpoint | Description |
|---|---|---|
| | Create a document (plain text or Markdown) |
| | Retrieve a document |
| | Delete a document |
client.avatars.update(id, { documentIds: [...] })| Method | Endpoint | Description |
|---|---|---|
| | Get task status and output |
| | Cancel/delete a task |
| | Create ephemeral upload |
| | Organization info & credit balance |
| | Credit usage history (up to 90 days) |
POST /v1/<endpoint>{ "id": "task_xxx" }GET /v1/tasks/{id}statusstatus === "SUCCEEDED"output| Status | Meaning |
|---|---|
| Queued, waiting to start |
| Currently generating |
| Complete — output URLs available |
| Generation failed — check |
| Concurrency limit hit — auto-queued |
waitForTaskOutput()// Node.js — polls until complete (default 10 min timeout)
const task = await client.imageToVideo.create({
model: 'gen4.5',
promptImage: 'https://example.com/image.jpg',
promptText: 'A sunset timelapse',
ratio: '1280:720',
duration: 5
}).waitForTaskOutput();
console.log(task.output); // Array of signed URLs# Python
task = client.image_to_video.create(
model='gen4.5',
prompt_image='https://example.com/image.jpg',
prompt_text='A sunset timelapse',
ratio='1280:720',
duration=5
).wait_for_task_output()
print(task.output)async function pollTask(taskId) {
while (true) {
const response = await fetch(`https://api.dev.runwayml.com/v1/tasks/${taskId}`, {
headers: {
'Authorization': `Bearer ${process.env.RUNWAYML_API_SECRET}`,
'X-Runway-Version': '2024-11-06'
}
});
const task = await response.json();
if (task.status === 'SUCCEEDED') return task;
if (task.status === 'FAILED') throw new Error(task.failure);
await new Promise(r => setTimeout(r, 5000)); // poll every 5 seconds
}
}output| Type | Via URL | Via Data URI | Via Upload |
|---|---|---|---|
| Image | 16 MB | 5 MB | 200 MB |
| Video | 32 MB | 16 MB | 200 MB |
| Audio | 32 MB | 16 MB | 200 MB |
Content-TypeContent-Length| Tier | Concurrency | Daily Gens | Monthly Cap | Unlock |
|---|---|---|---|---|
| 1 (default) | 1-2 | 50-200 | $100 | — |
| 2 | 3 | 500-1,000 | $500 | 1 day + $50 |
| 3 | 5 | 1,000-2,000 | $2,000 | 7 days + $100 |
| 4 | 10 | 5,000-10,000 | $20,000 | 14 days + $1,000 |
| 5 | 20 | 25,000-30,000 | $100,000 | 7 days + $5,000 |
THROTTLED429 Too Many Requests| Code | Meaning | Action |
|---|---|---|
| 400 | Input validation failure | Fix input, do not retry |
| 401 | Invalid API key | Check key, do not retry |
| 429 | Rate limited | Retry with exponential backoff + jitter |
| 502/503/504 | Server overload | Retry with exponential backoff + jitter |
| Code | Meaning | Retry? |
|---|---|---|
| Input content moderation | No — not refundable |
| Output content moderation | Yes — try different prompt |
| Quality issue | Yes |
| Bad input format | Fix input |
| Server error | Yes |
data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAA...