Skip to main content
Glama

Generate Video

xbrush_video_generate

Generate AI videos from an image, text prompt, or reference images. Starts an async job, returning a request_id to poll for completion.

Instructions

Generate a video from a start image, a text prompt, and/or reference images (reference-to-video). Submits async — poll the returned request_id with xbrush_get_request (typical wait 2-10 min).

Args: model (string, required): Video model ID (e.g. kling-v3-pro, kling-o3, veo3.1, seedance-2.0, hailuo-02-pro, wan-2.7-video). Use xbrush_list_models(category='video') — entries include per-model duration constraints. image_url (string, optional): Start image (first frame) for image-to-video. Not needed for text-to-video or reference-to-video. image_urls (array, optional): Reference images for reference-to-video models (seedance-2.0/-fast). Each item is a URL string OR an object {url, role} where role is first_frame/last_frame/reference_image — so one call can combine a start frame, an end frame, and subject references. NUMBERING: in prompt/idea, @ImageN = the N-th item here by 1-based ARRAY POSITION, counting first_frame/last_frame too (NOT 'the N-th reference'). E.g. [last_frame, reference_image] → the reference is @Image2. image_url is not required when this is set. prompt (string, optional): ENGLISH motion/action description, sent to the model as-is. Reference an image_urls item as @ImageN (N = its 1-based position in image_urls). Use 'idea' instead for non-English text. Provide prompt or idea for text-to-video. idea (string, optional): NON-English description (e.g. Korean) — the server translates it before generation. Use this instead of prompt when not writing in English. Reference an image_urls item as @ImageN (N = its 1-based position in image_urls). end_image_url (string, optional): End image (last frame), for models that support an end frame. duration (int, optional): Seconds; valid range is model-specific (e.g. seedance-2.0 4–15, kling 5/10, veo3 4–8). resolution (string, optional): Resolution tier for models that support it (seedance-2.0: 480p/720p/1080p/1440p/2160p/4k/512p/768p). Server-validated per model. aspect_ratio (string, optional): Aspect ratio for models that support it (seedance-2.0: auto/adaptive/16:9/9:16/1:1/4:3/3:4/21:9). generate_audio (bool, optional): Generate audio with the video (seedance-2.0/-fast). consistency_mode (string, optional): Reference consistency for reference-to-video (seedance-2.0/-fast): overlay/advanced/auto. prompt_relevance (float, optional): Prompt adherence (0.0-1.0).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ideaNoSame purpose as prompt but for NON-English text (e.g. Korean): the server translates it before sending to the model. Use 'idea' for non-English, 'prompt' for English. Reference an image_urls entry as @ImageN, where N is its 1-based position in the image_urls array (first_frame/last_frame count toward the position too). Provide prompt OR idea.
modelYesVideo model to use (e.g. kling-v3-pro, kling-o3, veo3.1, seedance-2.0, hailuo-02-pro, wan-2.7-video). Use xbrush_list_models with category='video' to see options and per-model duration constraints.
promptNoMotion/action description in ENGLISH — sent to the model as-is. Use this when writing directly in English; for any non-English text use 'idea' instead (the server translates it). Reference an image_urls entry as @ImageN, where N is its 1-based position in the image_urls array (first_frame/last_frame count toward the position too). Provide prompt OR idea (required for text-to-video when no image is supplied).
durationNoVideo duration in seconds (integer). Valid range is model-specific — e.g. kling 5 or 10, veo3 4–8, seedance-2.0 4–15 (default 5), wan-2.7 2–15. Default depends on the model; out-of-range values are rejected by the server per model.
image_urlNoURL of the start image (first frame) for image-to-video. Optional — text-to-video (prompt only) and reference-to-video (image_urls) models don't need it. The selected model decides what is required.
image_urlsNoReference images for reference-to-video models (e.g. seedance-2.0 / seedance-2.0-fast). Each element is EITHER a plain URL string OR an object {url, role} where role is 'first_frame' | 'last_frame' | 'reference_image'. The {url, role} form lets a single call combine a start frame, an end frame, and subject/style references in one list (passed through to the model as video_params.image_urls). Standalone: image_url is not required when this is set. NUMBERING (important): in prompt/idea, @Image1, @Image2, … refer to entries of THIS array by 1-based position in array order, counting EVERY entry — first_frame and last_frame included, NOT only reference_image entries. Example: image_urls=[{url, role:'last_frame'}, {url, role:'reference_image'}] → the reference is @Image2, because last_frame occupies position 1. To make a reference @Image1, place it first in the array. Ignored by models without a reference-image input.
resolutionNoOutput resolution tier for video models that support it (seedance-2.0/-fast: "480p", "720p", "1080p", "1440p", "2160p", "4k", "512p", "768p"). Server-validated per model; ignored by models that size differently. Higher tiers cost more.
aspect_ratioNoAspect ratio for video models that support it (seedance-2.0/-fast: "auto", "adaptive", "16:9", "9:16", "1:1", "4:3", "3:4", "21:9"). Server-validated per model.
end_image_urlNoURL of the end image (last frame). Creates a transition from start to end. Supported by select models (e.g. kling); ignored by models without an end-frame input such as seedance-2.0.
generate_audioNoWhether to generate audio together with the video (seedance-2.0/-fast). Default is model-specific.
consistency_modeNoSubject/reference consistency mode for reference-to-video models (seedance-2.0/-fast): "overlay", "advanced", or "auto". Controls how reference images stay consistent across frames. Server-validated; omit for the model default.
prompt_relevanceNoHow closely to follow the prompt (0.0-1.0).
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already indicate a write operation, but the description adds substantial behavioral detail: async execution, typical 2-10 minute wait, server-validated per-model constraints, ignored parameters for unsupported models, and the translation behavior for non-English text. This goes well beyond the annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the core purpose and async behavior before the Args block. It is long but justified by 12 parameters and complex reference-image semantics; every sentence contributes, though there is some redundancy with the schema descriptions.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity and the absence of an output schema, the description covers all necessary invocation context: return of request_id, polling workflow, model selection, prompt/idea requirements, reference-image numbering, and model-specific parameter validation. It is sufficiently complete for an agent to select and call the tool correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Input schema coverage is 100%, and the description reinforces semantics with clarifying examples like the @ImageN numbering rule and the [last_frame, reference_image] -> @Image2 case. It also explains model-specific duration and resolution ranges. It does not quite reach 5 because much of the parameter text mirrors the schema's own descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb+resource: 'Generate a video from a start image, a text prompt, and/or reference images (reference-to-video).' It clearly defines the tool's scope and differentiates it from siblings like video_upscale, video_extend, and video_retake by emphasizing generation from inputs rather than post-processing.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides clear context for when to use this tool: async submission, polling with xbrush_get_request, model selection via xbrush_list_models, and the distinction between prompt (English) and idea (non-English). It stops short of explicitly naming alternative tools or excluding them, so it misses a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/lweight/xbrush-api-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server