Mage API · Video model
Magejutsu API
Recast any video, keeping its motion
POST https://api.mage.space/v1/magejutsu/generateAt a glance
The Magejutsu API runs Magejutsu and 2 other variants through Mage at POST https://api.mage.space/v1/magejutsu/generate. A request at the default settings costs 1,856 Gems (about $1.856), with no subscription. Magejutsu takes saved characters, references by @handle in the prompt.
- VideoOutput
- 3Variants
- 1,856Gems per clip, default
- $1.856About, in USD
Overview
What the Magejutsu API does
Recasts a video you already have: send the clip and photos of who or what replaces it, and the motion, camera, timing and sound stay as filmed. Sources run 4 to 30 seconds.
Recasts an existing video: a director writes the edit prompt from the source, and a video-edit pass rebuilds who and what performs it. Send the source video and the replacement references; the output keeps the source length, ratio, motion and sound.
It accepts image, additional_images, videos as inputs.
Quick start
Call the Magejutsu API
Set MAGE_API_KEY, submit to /magejutsu/generate, and poll status_url until the request completes.
cURL
STATUS_URL=$(curl --request POST 'https://api.mage.space/v1/magejutsu/generate' \
--header "Authorization: Bearer $MAGE_API_KEY" \
--header 'Content-Type: application/json' \
--data '{
"prompt": "A slow push-in on a lighthouse at dusk, waves breaking below",
"videos": [
"https://example.com/input.jpg"
],
"image": "https://example.com/input.jpg",
"model_id": "magejutsu"
}' | jq -r '.status_url')
# Repeat until status is "completed"; result.url is the file
curl "$STATUS_URL" --header "Authorization: Bearer $MAGE_API_KEY"TypeScript
// npm install @mage-space/sdk
import Mage from '@mage-space/sdk';
const mage = new Mage(); // reads MAGE_API_KEY
const request = await mage.run('magejutsu', {
prompt: 'A slow push-in on a lighthouse at dusk, waves breaking below',
videos: [
'https://example.com/input.jpg',
],
image: 'https://example.com/input.jpg',
model_id: 'magejutsu',
});
console.log(request.result.url);Python
# pip install mage-space
from mage_space import Mage
mage = Mage() # reads MAGE_API_KEY
request = mage.run("magejutsu", {
"prompt": "A slow push-in on a lighthouse at dusk, waves breaking below",
"videos": [
"https://example.com/input.jpg",
],
"image": "https://example.com/input.jpg",
"model_id": "magejutsu",
})
print(request["result"]["url"])Models
Magejutsu model_id values
Send model_id to pick a variant. A request without one runs the default.
| model_id | Name | Default |
|---|---|---|
| magejutsu | Magejutsu | Yes |
| magejutsu-lite | Magejutsu Lite | |
| magejutsu-feather | Magejutsu Feather |
Options
Magejutsu parameters
Allowed values across all variants; a variant may offer fewer. The docs list the options per variant.
| Field | Values |
|---|---|
| resolution | 480p, 720p, 1080p |
| mode | motion_transfer, object_swap |
Inputs
Media inputs Magejutsu accepts
Send each as an https URL, a data URL, or an upload of up to 100 MB.
| Field | Role |
|---|---|
| image | The reference image. |
| additional_images | Additional reference images. |
| videos | The source videos. |
Rules
What the Magejutsu API enforces
- The source video runs 4 to 30 seconds on magejutsu and 4 to 15 on magejutsu-lite, the faster and cheaper variant, and on magejutsu-feather, the cheapest and fastest, which runs motion_transfer only and renders at 480p and 720p. The output follows the source's length and aspect ratio.
- Every request runs the same director in the backend. Choose motion_transfer to rebuild the performers and keep the motion, or object_swap to change selected elements and keep the rest of the shot as filmed. The mode also decides how the source is prepared: a motion transfer guides the edit with each replaced performer's movement and face, and an object swap edits the source as filmed. A clip the guidance cannot read, such as one with no person in it, renders from the source as filmed. There are no manual approval steps or draft renders.
- Send up to 30 reference images across image and additional_images. The director reads every one, and the edit receives the ones its prompt uses: up to 27 on magejutsu, 9 on magejutsu-lite and 8 on magejutsu-feather.
- The prompt is optional: without one, the director maps the references to the source by prominence and fit.
- Original audio is restored by default; set keep_original_audio to false to retain generated audio.
- The images are the replacement; mention each in the prompt by position ("image 1 is the person on the left").
- The source video is the only one accepted on a request; a longer clip is refused rather than trimmed.
More video models
Other video generation APIs on Mage
Melon API
Anime in motion, with optional audio
MiniMax-H3 API
Fast open video with stereo sound
Plum API
Sound on every clip, up to 2K
Raspberry API
Characters brought to life from a first frame
Wan Video v2.2 API
Open-weights video with a Lightning variant
Berry API
Video that stays true to your references
FAQ
Frequently asked questions
How much does the Magejutsu API cost?
What is the Magejutsu API endpoint?
Which Magejutsu models can I call?
Does Magejutsu support reference images or characters?
Can I use Magejutsu from Claude or ChatGPT?
How long are Magejutsu results kept?
Start building with Mage
One account, one Gems balance, every model. Pay only for what you generate.