typefile
{
"aspect_ratio": "16:9",
"extend_bottom": 0,
"extend_left": 0,
"extend_right": 0,
"extend_top": 0,
"frames_per_second": 24,
"guidance": 30,
"image": "https://replicate.delivery/pbxt/NXLu5r2BxokWTuL27pIbU2LCB3SBvDMpMQPCA8hBP82jUXSA/13.jpg",
"num_frames": 121,
"outpaint_prompt": "Continue the image naturally",
"preset": "make_square",
"resolution": "720p",
"steps": 50,
"video_prompt": "Everyone starts dancing, dance-off, dance battle"
}npm install replicate
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_9ip**********************************
This is your API token. Keep it to yourself.
import Replicate from "replicate";
import fs from "node:fs";
const replicate = new Replicate({
auth: process.env.REPLICATE_API_TOKEN,
});
Run zsxkib/outpainter-to-video using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const input = {
aspect_ratio: "16:9",
extend_bottom: 0,
extend_left: 0,
extend_right: 0,
extend_top: 0,
frames_per_second: 24,
guidance: 30,
image: "https://replicate.delivery/pbxt/NXLu5r2BxokWTuL27pIbU2LCB3SBvDMpMQPCA8hBP82jUXSA/13.jpg",
num_frames: 121,
outpaint_prompt: "Continue the image naturally",
preset: "make_square",
resolution: "720p",
steps: 50,
video_prompt: "Everyone starts dancing, dance-off, dance battle"
};
const output = await replicate.run("zsxkib/outpainter-to-video", { input });
// To access the file URL:
console.log(output.url()); //=> "http://example.com"
// To write the file to disk:
fs.writeFile("my-image.png", output);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_9ip**********************************
This is your API token. Keep it to yourself.
import replicate
Run zsxkib/outpainter-to-video using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"zsxkib/outpainter-to-video",
input={
"aspect_ratio": "16:9",
"extend_bottom": 0,
"extend_left": 0,
"extend_right": 0,
"extend_top": 0,
"frames_per_second": 24,
"guidance": 30,
"image": "https://replicate.delivery/pbxt/NXLu5r2BxokWTuL27pIbU2LCB3SBvDMpMQPCA8hBP82jUXSA/13.jpg",
"num_frames": 121,
"outpaint_prompt": "Continue the image naturally",
"preset": "make_square",
"resolution": "720p",
"steps": 50,
"video_prompt": "Everyone starts dancing, dance-off, dance battle"
}
)
# To access the file URL:
print(output.url())
#=> "http://example.com"
# To write the file to disk:
with open("my-image.png", "wb") as file:
file.write(output.read())
To learn more, take a look at the guide on getting started with Python.
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_9ip**********************************
This is your API token. Keep it to yourself.
Run zsxkib/outpainter-to-video using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
curl -s -X POST \
-H "Authorization: Bearer $REPLICATE_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Prefer: wait" \
-d $'{
"input": {
"aspect_ratio": "16:9",
"extend_bottom": 0,
"extend_left": 0,
"extend_right": 0,
"extend_top": 0,
"frames_per_second": 24,
"guidance": 30,
"image": "https://replicate.delivery/pbxt/NXLu5r2BxokWTuL27pIbU2LCB3SBvDMpMQPCA8hBP82jUXSA/13.jpg",
"num_frames": 121,
"outpaint_prompt": "Continue the image naturally",
"preset": "make_square",
"resolution": "720p",
"steps": 50,
"video_prompt": "Everyone starts dancing, dance-off, dance battle"
}
}' \
https://api.replicate.com/v1/models/zsxkib/outpainter-to-video/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
{
"id": "fdjjrcg0xhrma0crnddvnt901g",
"model": "zsxkib/outpainter-to-video",
"version": "hidden",
"input": {
"aspect_ratio": "16:9",
"extend_bottom": 0,
"extend_left": 0,
"extend_right": 0,
"extend_top": 0,
"frames_per_second": 24,
"guidance": 30,
"image": "https://replicate.delivery/pbxt/NXLu5r2BxokWTuL27pIbU2LCB3SBvDMpMQPCA8hBP82jUXSA/13.jpg",
"num_frames": 121,
"outpaint_prompt": "Continue the image naturally",
"preset": "make_square",
"resolution": "720p",
"steps": 50,
"video_prompt": "Everyone starts dancing, dance-off, dance battle"
},
"logs": "",
"output": "https://replicate.delivery/xezq/mbCMTFtYBvanDNPpoxePLxqdkubrCevTIpoqaf329gN4BIWqA/output.mp4",
"data_removed": false,
"error": null,
"source": "web",
"status": "succeeded",
"created_at": "2025-08-15T01:32:04.716Z",
"started_at": "2025-08-15T01:32:05.232582Z",
"completed_at": "2025-08-15T01:32:44.492761Z",
"urls": {
"cancel": "https://api.replicate.com/v1/predictions/fdjjrcg0xhrma0crnddvnt901g/cancel",
"children": "https://api.replicate.com/v1/predictions/fdjjrcg0xhrma0crnddvnt901g/children",
"get": "https://api.replicate.com/v1/predictions/fdjjrcg0xhrma0crnddvnt901g",
"root": "https://api.replicate.com/v1/predictions/fdjjrcg0xhrma0crnddvnt901g",
"stream": "https://stream.replicate.com/v1/files/bcwr-4jsvbgpkf3ofscnr6frc6jpduwajuxo7di43ezsnfth5f6xoqhdq",
"web": "https://replicate.com/p/fdjjrcg0xhrma0crnddvnt901g"
},
"metrics": {
"predict_time": 39.260179393,
"total_time": 39.776761
}
}