Loading...
Loading...
Runway AI API for video generation via curl. Use this skill to generate videos from images, text, or other videos.
npx skill4agent add vm0-ai/vm0-skills runwaycurlOfficial docs:https://docs.dev.runwayml.com/
RUNWAY_API_KEYexport RUNWAY_API_KEY="your-api-key"Important: When usingin a command that pipes to another command, wrap the command containing$VARin$VAR. Due to a Claude Code bug, environment variables are silently cleared when pipes are used directly.bash -c '...'bashbash -c 'curl -s "https://api.example.com" -H "Authorization: Bearer $API_KEY"'
RUNWAY_API_KEYhttps://api.dev.runwayml.com/v1Authorization: Bearer ${RUNWAY_API_KEY}X-Runway-Version: 2024-11-06Content-Type: application/jsonbash -c 'curl -s -X GET "https://api.dev.runwayml.com/v1/organization" --header "Authorization: Bearer ${RUNWAY_API_KEY}" --header "X-Runway-Version: 2024-11-06"'/tmp/runway_request.json{
"model": "gen4_turbo",
"promptImage": "https://example.com/your-image.jpg",
"promptText": "A timelapse of clouds moving across the sky",
"ratio": "1280:720",
"duration": 5
}bash -c 'curl -s -X POST "https://api.dev.runwayml.com/v1/image_to_video" --header "Authorization: Bearer ${RUNWAY_API_KEY}" --header "X-Runway-Version: 2024-11-06" --header "Content-Type: application/json" -d @/tmp/runway_request.json'{
"id": "task-id-here"
}Note: Text-to-video only supports duration values of 4, 6, or 8 seconds (not arbitrary values like image-to-video).
/tmp/runway_request.json{
"model": "veo3.1",
"promptText": "A serene forest with sunlight filtering through the trees",
"ratio": "1280:720",
"duration": 6
}bash -c 'curl -s -X POST "https://api.dev.runwayml.com/v1/text_to_video" --header "Authorization: Bearer ${RUNWAY_API_KEY}" --header "X-Runway-Version: 2024-11-06" --header "Content-Type: application/json" -d @/tmp/runway_request.json'/tmp/runway_request.json{
"model": "gen4_aleph",
"videoUri": "https://example.com/source-video.mp4",
"promptText": "Add magical sparkles and fairy dust effects",
"ratio": "1280:720"
}bash -c 'curl -s -X POST "https://api.dev.runwayml.com/v1/video_to_video" --header "Authorization: Bearer ${RUNWAY_API_KEY}" --header "X-Runway-Version: 2024-11-06" --header "Content-Type: application/json" -d @/tmp/runway_request.json'/tmp/runway_request.json{
"model": "gen4_image_turbo",
"promptText": "A futuristic cityscape at sunset",
"ratio": "1920:1080",
"referenceImages": []
}bash -c 'curl -s -X POST "https://api.dev.runwayml.com/v1/text_to_image" --header "Authorization: Bearer ${RUNWAY_API_KEY}" --header "X-Runway-Version: 2024-11-06" --header "Content-Type: application/json" -d @/tmp/runway_request.json'<your-task-id>bash -c 'curl -s -X GET "https://api.dev.runwayml.com/v1/tasks/<your-task-id>" --header "Authorization: Bearer ${RUNWAY_API_KEY}" --header "X-Runway-Version: 2024-11-06"'{
"id": "task-id",
"status": "SUCCEEDED",
"output": ["https://cdn.runwayml.com/generated-video.mp4"]
}PENDINGRUNNINGSUCCEEDEDFAILED<your-task-id>bash -c 'curl -s -X DELETE "https://api.dev.runwayml.com/v1/tasks/<your-task-id>" --header "Authorization: Bearer ${RUNWAY_API_KEY}" --header "X-Runway-Version: 2024-11-06"'/tmp/runway_request.json{
"model": "upscale_v1",
"videoUri": "https://example.com/low-res-video.mp4"
}bash -c 'curl -s -X POST "https://api.dev.runwayml.com/v1/video_upscale" --header "Authorization: Bearer ${RUNWAY_API_KEY}" --header "X-Runway-Version: 2024-11-06" --header "Content-Type: application/json" -d @/tmp/runway_request.json'/tmp/runway_request.json{
"model": "eleven_text_to_sound_v2",
"promptText": "Thunder rumbling in the distance"
}bash -c 'curl -s -X POST "https://api.dev.runwayml.com/v1/sound_effect" --header "Authorization: Bearer ${RUNWAY_API_KEY}" --header "X-Runway-Version: 2024-11-06" --header "Content-Type: application/json" -d @/tmp/runway_request.json'| Endpoint | Models |
|---|---|
| Image to Video | |
| Text to Video | |
| Video to Video | |
| Text to Image | |
| Video Upscale | |
1280:720720:12801024:1024/tasks/{id}SUCCEEDEDgen4_turbogen4_aleph/organization