Pruna AI P Video 2 Image To Video API Documentation

Pruna AI P Video 2 Image To Video API Documentation

Playground

Try it on WaveSpeedAI!

Pruna P-Video-2 Image-to-Video generates videos from input images with explicit controls for duration, resolution, draft mode, and audio output, making it suitable for image animation, creative videos, social content, ads, and production workflows. Ready-to-use REST inference API, best performance, no coldstarts, affordable pricing.

Features

Pruna P-Video-2 Image-to-Video generates videos from an input image and a motion prompt. Upload a reference image, describe the motion or scene direction, choose a duration from 1 to 20 seconds, and generate either a full-quality video or a lower-cost draft preview.


Why Choose This?

  • Image-to-video generation
    Turn a still image into a video using a motion prompt.

  • Image-based aspect ratio
    The output aspect ratio follows the input image automatically.

  • Flexible duration control
    Choose an explicit duration from 1 to 20 seconds.

  • Draft and Full modes
    Use Draft mode for faster, lower-cost previews, or Full mode for higher-quality output.

  • 720p and 1080p output
    Generate at 720p for lower cost or 1080p for higher-resolution results.

  • Prompt upsampling
    Use prompt_upsampling to expand and refine the generation prompt.


Parameters

ParameterRequiredDescription
promptYesNon-empty generation prompt describing the desired motion, scene, camera movement, and visual direction.
imageYesInput image used as the visual source. Upload JPEG, PNG, or WebP, or provide a public image URL. The output aspect ratio follows this image.
durationYesRequested video duration in seconds. Range: 1–20. No default is supplied.
resolutionNoOutput resolution: 720p or 1080p. Default: 720p.
draftNoEnable lower-quality Draft mode for faster, lower-cost previews. Default: false.
save_audioNoSave audio in the generated result when supported. Default: true.
prompt_upsamplingNoExpand and optimize the generation prompt. Default: true.
seedNoOptional non-negative integer seed for reproducible results. Omit for random generation.

How to Use

  1. Upload an input image — Provide the image that should guide the video appearance and aspect ratio.
  2. Write a motion prompt — Describe the action, movement, camera direction, mood, and scene changes.
  3. Set duration — Choose an explicit duration from 1 to 20 seconds.
  4. Choose resolution — Use 720p for lower-cost generation or 1080p for higher-resolution output.
  5. Choose Draft or Full mode — Enable draft for preview generation or leave it disabled for full output.
  6. Configure prompt upsampling optional — Keep prompt_upsampling enabled when you want the prompt refined automatically.
  7. Set seed optional — Use a fixed seed for reproducible results, or omit it for random generation.
  8. Submit — Generate the final image-to-video output.

Pricing

Pricing is based on the explicitly requested duration, selected resolution, and draft mode.

ResolutionFull / secondDraft / second
720p$0.025$0.015
1080p$0.05$0.03

Example Costs

Duration720p Full720p Draft1080p Full1080p Draft
5s$0.125$0.075$0.25$0.15
10s$0.25$0.15$0.50$0.30
20s$0.50$0.30$1.00$0.60

Billing uses the requested duration, not the measured duration of the generated output. save_audio, prompt_upsampling, and seed do not add separate charges.


Best Use Cases

  • Image animation — Turn a still image into a short motion clip.
  • Prompt-based motion testing — Test different action, camera, and scene directions from the same image.
  • Draft previews — Use Draft mode to compare motion ideas before running full-quality output.
  • Social video content — Generate short clips from portraits, products, illustrations, or concept images.
  • Creative prototyping — Explore visual motion from a static source image.
  • Marketing and product visuals — Animate product or campaign images for short-form video use.

Pro Tips

  • Use a clear, high-quality image for stronger subject and composition consistency.
  • Write prompts that describe visible motion, not just visual style.
  • Include camera direction, subject action, lighting, and mood when the shot needs stronger control.
  • Use Draft mode for quick iteration before generating the final version.
  • Use 720p for lower-cost tests and 1080p for higher-resolution output.
  • Set a fixed seed when comparing prompt or parameter changes.
  • This product does not support automatic duration, audio conditioning, or last-frame guidance.
  • Frame rate follows the upstream default.

Authentication

For authentication details, please refer to the Authentication Guide.

API Endpoints

Submit Task & Query Result

set -euo pipefail

export WAVESPEED_API_KEY="your-api-key"

REQUEST_BODY=$(cat <<'JSON'
{
  "prompt": "A cinematic ocean wave at sunrise, highly detailed",
  "image": "https://interactive-examples.mdn.mozilla.net/media/cc0-images/painted-hand-298-332.jpg",
  "duration": 5,
  "resolution": "720p",
  "draft": false,
  "save_audio": true,
  "prompt_upsampling": true
}
JSON
)

# 1. Submit the prediction.
SUBMIT_RESPONSE=$(curl --silent --show-error --fail-with-body \
  -X POST "https://api.wavespeed.ai/api/v3/pruna-ai/p-video-2/image-to-video" \
  -H "Authorization: Bearer ${WAVESPEED_API_KEY}" \
  -H "Content-Type: application/json" \
  -d "${REQUEST_BODY}")

TASK=$(printf '%s' "${SUBMIT_RESPONSE}" | jq 'if type == "object" and has("data") then .data else . end')
PREDICTION_ID=$(printf '%s' "${TASK}" | jq -r '.id // empty')
if [ -z "${PREDICTION_ID}" ]; then
  printf 'Submission response did not contain a prediction id
' >&2
  exit 1
fi
RESULT_URL="https://api.wavespeed.ai/api/v3/predictions/${PREDICTION_ID}/result"

# 2. Poll until the prediction finishes.
while true; do
  RESPONSE=$(curl --silent --show-error --fail-with-body \
    "${RESULT_URL}" \
    -H "Authorization: Bearer ${WAVESPEED_API_KEY}")
  RESULT=$(printf '%s' "${RESPONSE}" | jq 'if type == "object" and has("data") then .data else . end')
  STATUS=$(printf '%s' "${RESULT}" | jq -r '.status // empty')

  case "${STATUS}" in
    completed) printf '%s\n' "${RESULT}" | jq '.outputs'; break ;;
    failed|cancelled|timeout|deleted) printf '%s\n' "${RESULT}" | jq . >&2; exit 1 ;;
    *) sleep 2 ;;
  esac
done

Parameters

Task Submission Parameters

Request Parameters

ParameterTypeRequiredDefaultRangeDescription
promptstringYes-The positive prompt for generation.
imagestringYes-Upload an input image or provide its public URL (JPEG, PNG, or WebP). The image determines the output aspect ratio.
durationintegerYes51 ~ 20Requested video duration in seconds. Defaults to 5 seconds; automatic duration is not available.
resolutionstringNo720p720p, 1080pOutput video resolution.
draftbooleanNofalse-Generate a faster, lower-quality preview at half the full-mode per-second rate.
save_audiobooleanNotrue-Save the video with audio.
prompt_upsamplingbooleanNotrue-Enhance the prompt before video generation.
seedintegerNo-0 ~ 2147483647Random seed for reproducibility. Omit for a random seed.

Response Parameters

ParameterTypeDescription
codeintegerHTTP status code (e.g., 200 for success)
messagestringStatus message (e.g., “success”)
data.idstringUnique identifier for the prediction, Task Id
data.modelstringModel ID used for the prediction
data.outputsarrayOutput values, usually URL strings; some models return text strings or structured result objects (empty when status is not completed)
data.urlsobjectObject containing related API endpoints
data.statusstringTask status. completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses.
data.created_atstringISO timestamp of when the request was created (e.g., “2023-04-01T12:34:56.789Z”)
data.errorstringError message (empty if no error occurred)
data.timingsobjectObject containing timing details
data.timings.inferenceintegerInference time in milliseconds

Result Request Parameters

ParameterTypeRequiredDefaultDescription
idstringYes-Task ID

Result Response Parameters

ParameterTypeDescription
codeintegerHTTP status code (e.g., 200 for success)
messagestringStatus message (e.g., “success”)
dataobjectThe prediction data object containing all details
data.idstringUnique identifier for the prediction
data.modelstringModel ID used for the prediction
data.outputsarray<string | object>Array of generated outputs (empty when status is not completed). Items are usually URL strings, but may be text strings or structured result objects, depending on the model.
data.urlsobjectObject containing related API endpoints
data.statusstringStatus: completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses
data.created_atstringISO timestamp of when the request was created
data.errorstringError message (empty if no error occurred)
data.timingsobjectObject containing timing details
data.timings.inferenceintegerInference time in milliseconds
© 2026 WaveSpeedAI. All rights reserved.