AI Video Reframe API : Change a Video's Aspect Ratio Without Cropping
Send a clip, pick a new shape and the AI paints the areas the old frame never showed, so a landscape video becomes a full vertical one. Try it right here, then call the same model from your product with one key and one balance.
- One video, 4–60 seconds
- 6 aspect ratios, source resolution
- Priced from the source video
- Same model through the API
Features
Key AI Video Reframe API Features
Six target ratios
Reframe to 16:9, 9:16, 4:3, 3:4, 1:1 or 21:9: vertical for stories and shorts, square for feeds, widescreen for players and cinematic cuts.
New areas painted, not cropped
Instead of cutting the picture down to the new shape, the model paints the extra space around it, so your original stays in the shot rather than being cut away.
Guide it with reference images
For clips of up to 15 seconds, add up to 2 reference images in image_urls to steer what gets painted into the new areas, such as a set, a backdrop or a product display.
Source resolution kept
The result is an mp4 at the source's resolution, 480p, 720p or 1080p. A video whose short side is above 1080 pixels is scaled down to 1080 first.
Clips from 4 to 60 seconds
Source videos can run from 4 to 60 seconds. A clip outside that range, or one that can't be read, fails within seconds with nothing charged.
Priced by the source video
The price is per second of the source video, set by its resolution, plus a fixed amount per task. It's worked out from your clip within seconds and reserved before the work starts.
Overview
What Is the AI Video Reframe API?
- Model ID
reframe-video- Input
- One video
- Resolution
- Same as the source video
- Aspect ratio
- 6 options
- Video length
- 4–60 s
- Reference images
- Up to 2 (videos up to 15 s)
- Price
- from $0.1404 per second + $0.1404 per task
Reframing changes a video's aspect ratio. The usual way is to crop, which throws away the edges and often part of the action. AI reframing works the other way round: it keeps your original picture and paints what should appear in the new space, so a 16:9 clip becomes a real 9:16 video instead of a narrow slice of the old one.
The AI Video Reframe API does this over HTTP. On NanoAPI it's the model reframe-video of the product reframe_video: send video_url and aspect_ratio, optionally with up to 2 reference images in image_urls, and get back one mp4 at the source's resolution. Reference images help when the new areas need specific content, and work on clips of up to 15 seconds.
Pricing follows the source video: a price per second set by its resolution (480p, 720p or 1080p) plus a fixed amount per task. Within a few seconds of creation NanoAPI reads the clip, works out the amount and reserves it, and the charge after success is never higher. A task that fails is refunded in full.
Reframing takes a while: a 10-second clip takes about 7 minutes, so let a webhook tell you when it's done. Try it in the studio at the top of this page, then call the AI Video Reframe API at https://api.nanoapi.ai/v1 from your own app, with the same API key and prepaid balance as every NanoAPI model.
Pricing
AI Video Reframe API Pricing
A fixed amount per task plus a price per second of the source video, set by its resolution. The amount is reserved within seconds of creating the task, and a failed task is refunded in full.
| Source video | Per second | + per task | 10 s video |
|---|---|---|---|
| 480p | $0.1404 | $0.1404 | $1.5444 |
| 720p | $0.2106 | $0.1404 | $2.2464 |
| 1080p | $0.5616 | $0.1404 | $5.7564 |
cost = per task + price per second × source video seconds (rounded to whole seconds)
The playground shows an estimate; the exact amount is frozen a few seconds after the task is created, once the source video has been read
How it works
How to Use the AI Video Reframe API
- 1
Step 1: Get your API key
Sign in to NanoAPI with Google and create a key on the API Keys page of the console. It authenticates every request, so keep it on your server.
- 2
Step 2: Top up your balance
Add funds on the Top up page of the console. The balance is prepaid in USD, never expires and is shared by every NanoAPI model, image and video alike.
- 3
Step 3: Create a task
Send POST /v1/tasks with model reframe-video, video_url (a public http(s) link to a clip of 4 to 60 seconds) and aspect_ratio, which is required. Add image_urls with up to 2 reference images if the clip is 15 seconds or shorter.
- 4
Step 4: Get the video
Receive the finished task once at your webhook_url, or poll GET /v1/tasks/{task_id} every 15 seconds or more. Plan for minutes rather than seconds: a 10-second clip takes about 7. The video is at outputs[].url.
Why NanoAPI
Why Use the AI Video Reframe API on NanoAPI
One key, every model
Generate a clip with Kling 4.0 or Seedance 2.5, reframe it for every platform and upscale it, all with the same API key and balance through POST /v1/tasks.
Nothing charged for bad input
A clip that can't be read, falls outside 4 to 60 seconds or carries reference images past 15 seconds fails within seconds with nothing charged; a later failure is refunded in full.
Webhooks or polling
Pass a webhook_url and receive the finished task once, signed to the Standard Webhooks spec (verifying is optional), or poll one task or a batch of task ids.
Safe retries and spend limits
Send an Idempotency-Key and a resent request returns the task it already created instead of charging twice. Cap each key's hourly, daily or total spending in the console.
A console for every request
See each request with its status, input, cost and result, your daily usage by product and every movement of your balance, and manage keys and the webhook secret.
Try online, then integrate
The studio on this page runs the same model at the same prices, so you can reframe your own clips before writing code. The docs also come as one llms.txt file for AI coding assistants.
Use cases
What You Can Build With the AI Video Reframe API
Landscape to vertical
Turn 16:9 footage into 9:16 for short-video apps and stories without losing the people at the edges of the frame.
Square and 3:4 for feeds
Reframe the same clip to 1:1 or 3:4 so it fills more of the screen in social feeds and on product pages.
Cinematic widescreen
Open a clip up to 21:9 for trailers, website hero videos and widescreen displays.
One ad, every placement
Deliver a product video in the shape of every placement, with a reference image of the product or set to steer what fills the new space. Your server calls the AI Video Reframe API once per ratio.
FAQ
AI Video Reframe API FAQ
Can’t find what you need? Write to us.
01What is the AI Video Reframe API?
An HTTP API that changes a video's aspect ratio by painting the new areas instead of cropping. On NanoAPI you send POST /v1/tasks with model reframe-video, a video_url and an aspect_ratio, optionally with reference images, and get one mp4 back by webhook or by polling.
02How much does video reframing cost?
A fixed amount per task plus a price per second of the source video, rounded to whole seconds and set by the source's resolution: 480p, 720p or 1080p, with anything larger counted as 1080p. The amount is reserved within seconds of creation and the final charge is never higher. Live prices are in the table above, on the pricing page and in GET /v1/products.
03Which aspect ratios are supported?
16:9, 9:16, 4:3, 3:4, 1:1 and 21:9. aspect_ratio is required on every task, so choose the shape you need for the platform you're publishing to.
04What do reference images do?
They guide what's painted into the new areas of the frame, for example a backdrop, a room or a product display. You can add up to 2 in image_urls, but only when the source video is 15 seconds or shorter; with a longer clip the task fails with invalid_request and nothing is charged.
05How long can the video be, and what resolution is the output?
The source must be 4 to 60 seconds long. The output is an mp4 that follows the source's resolution, 480p, 720p or 1080p; a video whose short side is above 1080 pixels is scaled down to 1080 first.
06How long does reframing take?
Usually 5 to 10 minutes; a 10-second clip takes about 7. Pass a webhook_url so your app is told when the video is ready instead of polling the whole time.
07What if my video can't be used?
NanoAPI reads the source within a few seconds of creation. If it can't be downloaded or read, the task fails with invalid_media; if it's shorter than 4 or longer than 60 seconds, with video_too_short or video_too_long. In each case nothing is charged.
08Can I try it online before integrating?
Yes. Sign in with Google and use the studio at the top of this page: it runs the same model at the same prices as the AI Video Reframe API and draws on the same balance, so you can check results and costs before you write any code.
Start Using the AI Video Reframe API
Reframe a clip in the studio above, then bring the same AI video reframing into your product with a single API call.