MeduxMedux

Generate > Create Image to Video

Create Image to Video

Generate a video from a source image and text prompt.

POST/api/app/v1/generate/video/image_to_video

Examples

curl -X POST https://api.medux.io/api/app/v1/generate/video/image_to_video \
  -H 'Authorization: Bearer $MEDUX_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{"aspect_ratio":"ASPECT_RATIO","clarity":"CLARITY","duration_seconds":1,"file_id":"FILE_ID","model_id":"MODEL_ID","prompt":"PROMPT","title":"Demo title"}'

Media Samples

Approved examples for understanding request inputs, response shape, and official example output.

Official image-to-video generation

This example uses wan-2-6-image-to-video.

This model requires starter or higher.

Sample request

Generate a short video from a source image and motion prompt.

file_id{file_id}promptAdd a gentle dolly-in camera move while preserving the subject.duration_seconds5clarity720Paspect_ratio16:9model_idwan-2-6-image-to-video

Sample response

Official example output for preview only. It is not a user Media Result.

output_urlOfficial example video output

Example output

Auth Requirements

Authentication is required via Authorization header.

Preconditions

Upload the source image and create a file reference before calling this endpoint.

Requires an uploaded image file_id and a non-empty prompt.

Also accepts optional duration_seconds, clarity, aspect_ratio, and model_id.

Request

Body

application/json
Authorizationstringrequired

Bearer token or API key.

Location: HEADER

aspect_ratiostringoptional

Requested output aspect ratio, for example 16:9 or 9:16.

Location: BODY

claritystringoptional

Requested output clarity, for example 720P or 1080P.

Location: BODY

duration_secondsint32optional

Requested output duration in seconds.

Location: BODY

file_idstringoptional

No description provided.

Location: BODY

model_idstringoptional

Stable public Medux model identifier.

Location: BODY

promptstringoptional

No description provided.

Location: BODY

titlestringoptional

No description provided.

Location: BODY

Response

Response

application/json
codeint32optional

response code enums:
.. 0: ok
.. 12: invalid input
.. 1410: invalid model
.. 1409: paid plan required
.. 1401: insufficient credits
.... 1401 ~ 1499 是 media
.. 1402: asset category mismatch
.. 1404: provider error
.. 1405: provider timeout
.. 13: unauthenticated
.. 16: rate limit
.. 99: server error

Available options: 0 12 1410 1409 1401 1402 1404 1405 13 16 99

Location: RESPONSE

data.assetobjectoptional

No description provided.

Location: RESPONSE

data.paid_plan_requiredobjectoptional

No description provided.

Location: RESPONSE

data.taskobjectoptional

No description provided.

Location: RESPONSE

messagestringoptional

No description provided.

Available options: ok invalid input invalid model paid plan required insufficient credits asset category mismatch provider error provider timeout unauthenticated rate limit server error

Location: RESPONSE

MCP Tool

This endpoint is also available through the Medux-hosted remote MCP service.

Video / Image to Video

Generate a video from a source image and text prompt. Default model wan-2-6-image-to-video requires Starter or higher and bills per generated video second.

Invocation Example

Generate a 5 second 720P 16:9 video from uploaded image {file_id} and this motion prompt using model_id wan-2-6-image-to-video. This model requires Starter or higher.

medux_video_generate_image_to_videoResult: video
file_id{file_id}prompt{prompt}model_idwan-2-6-image-to-videoduration_seconds5

paid_plan_required if the account is below Starter.