At a glance
The Berry API runs Berry 2 and 1 other variant through Mage at POST https://api.mage.space/v1/berry/generate. A request at the default settings costs 189 Gems (about $0.189), with no subscription. Berry takes saved characters, references by @handle in the prompt.
Video
Output
2
Variants
189
Gems per clip, default
$0.189
About, in USD
Overview
What the Berry API does
Video that stays faithful to every reference you give it. A start frame, up to 9 references or Characters, or a source video to edit; 3 to 15 seconds at up to 1080p.
Mage's reference-driven video model, faithful to the images you give it; Berry 2 is the current version. A first frame or reference images, or a source video to edit.
It accepts first_image, image, additional_images, video as inputs.
Quick start
Call the Berry API
Set MAGE_API_KEY, submit to /berry/generate, and poll status_url until the request completes.
cURL
STATUS_URL=$(curl --request POST 'https://api.mage.space/v1/berry/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",
"aspect_ratio": "16:9",
"duration": "3",
"model_id": "berry-2"
}' | jq -r '.status_url')
# Repeat until status is "completed"; result.url is the file
curl "$STATUS_URL" --header "Authorization: Bearer $MAGE_API_KEY"Python
import os, time, requests
headers = {"Authorization": f"Bearer {os.environ['MAGE_API_KEY']}"}
request = requests.post(
"https://api.mage.space/v1/berry/generate",
headers=headers,
json={
"prompt": "A slow push-in on a lighthouse at dusk, waves breaking below",
"aspect_ratio": "16:9",
"duration": "3",
"model_id": "berry-2"
},
).json()
while request["status"] in ("queued", "in_progress"):
time.sleep(3)
request = requests.get(request["status_url"], headers=headers).json()
print(request["status"], request["result"] and request["result"]["url"])JavaScript
const headers = {
Authorization: `Bearer ${process.env.MAGE_API_KEY}`,
'Content-Type': 'application/json',
};
let request = await fetch('https://api.mage.space/v1/berry/generate', {
method: 'POST',
headers,
body: JSON.stringify({
"prompt": "A slow push-in on a lighthouse at dusk, waves breaking below",
"aspect_ratio": "16:9",
"duration": "3",
"model_id": "berry-2"
}),
}).then((response) => response.json());
while (['queued', 'in_progress'].includes(request.status)) {
await new Promise((resolve) => setTimeout(resolve, 3000));
request = await fetch(request.status_url, { headers }).then((r) => r.json());
}
console.log(request.status, request.result?.url);Models
Berry model_id values
Send model_id to pick a variant. A request without one runs the default.
| model_id | Name | Default |
|---|---|---|
| berry | Berry | |
| berry-2 | Berry 2 | Yes |
Options
Berry parameters
Allowed values across all variants; a variant may offer fewer. The docs list the options per variant.
| Field | Values |
|---|---|
| aspect_ratio | 16:9, 9:16, 1:1, 4:3, 3:4, 4:5, 5:4 |
| resolution | 720p, 1080p, 480p |
| duration | 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 |
Inputs
Media inputs Berry accepts
Send each as an https URL, a data URL, or an upload of up to 100 MB.
| Field | Role |
|---|---|
| first_image | The first frame image. |
| image | The reference image. |
| additional_images | Additional reference images. |
| video | The source video. |
Rules
What the Berry API enforces
- A first frame cannot be combined with reference images.
- A source video must be between 3 and 60 seconds.
More video models
Other video generation APIs on Mage
Video · from 360 Gems
Blueberry API
Pin the first and last frame
Video · from 618 Gems
Cherry API
Our flagship video family
Video · from 375 Gems
Grok Video API
Grok Imagine, in motion
Video · from 270 Gems
Kiwi API
Everyday video, zero setup
Video · from 245 Gems
Lemon API
Every video feature, at a friendlier price
Video · from 20 Gems
LTX Video API
Fast open-weights video for iteration
FAQ
Frequently asked questions
How much does the Berry API cost?
A Berry request at the default settings (Berry 2) costs 189 Gems, about $0.189. Other resolutions, durations, and variants change the price; the response reports the exact charge. A generation that fails is refunded; one Mage's content policy blocks is not.
What is the Berry API endpoint?
POST https://api.mage.space/v1/berry/generate with an Authorization: Bearer header carrying your Mage API key. The response includes a status_url to poll for the result.
Which Berry models can I call?
berry (Berry), berry-2 (Berry 2). The default is Berry 2.
Does Berry support reference images or characters?
Berry accepts first_image, image, additional_images, video. Berry takes saved characters, references by @handle in the prompt.
Can I use Berry from Claude or ChatGPT?
Yes. Connect the Mage MCP server to Claude, ChatGPT, Claude Code, Grok, or Cursor and ask for Berry by name. Your assistant reads its options with get_model and quotes the price before it generates.
How long are Berry results kept?
Results and inputs are kept for 30 days. Download anything you want to keep to your own storage.
Start building with Mage
One account, one Gems balance, every model. Pay only for what you generate.