Skip to main content

Generate videos from images with Wan 2.2 I2V A14B AI model

Workflow preview

Generate videos from images with Wan 2.2 I2V A14B AI model preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

Overview

Generate Videos from Images with Wan 2.2 I2V A14B AI Model

🌍 Overview

This workflow connects n8n with Replicate’s Wan-Video model to generate video content from an image + prompt. It handles:

  • πŸ”‘ API authentication
  • πŸ“€ Sending a generation request
  • ⏳ Polling until completion
  • πŸ“₯ Returning a downloadable video link

🟒 Section 1: Start & Authentication

πŸ”— Nodes: 1️⃣ On clicking 'execute' (Manual Trigger) ▢️ Starts the workflow manually when you click Execute Workflow.

2️⃣ Set API Key πŸ”‘ Stores your Replicate API Key securely inside n8n.

  • Value: YOUR_REPLICATE_API_KEY

πŸ’‘ Beginner Benefit: βœ… No need to hardcode API keys in every request βœ… Easy to swap keys for different accounts


πŸ”΅ Section 2: Send Video Generation Request

πŸ”— Nodes: 3️⃣ Create Prediction (HTTP Request) πŸ“€ Sends a request to Replicate API β†’ /v1/predictions

  • Model: wan-video/wan-2.2-i2v-a14b

  • Input Parameters:

    • πŸ“ prompt β†’ your text description
    • πŸ–ΌοΈ image β†’ input video/image URL
    • 🎲 seed β†’ reproducibility
    • 🎞️ num_frames β†’ 81 frames
    • ⏩ sample_shift β†’ 5
    • βš™οΈ sample_steps β†’ 30
    • 🎬 frames_per_second β†’ 16

4️⃣ Extract Prediction ID (Code) πŸ†” Pulls out the prediction ID + status from Replicate’s response. This ID is needed for polling until the video finishes generating.

πŸ’‘ Beginner Benefit: βœ… Automates the API call to generate video βœ… Extracts ID β†’ avoids manual copy-paste


🟣 Section 3: Polling & Status Check

πŸ”— Nodes: 5️⃣ Wait (2 sec) ⏳ Adds a short delay before checking progress.

  • Prevents API spam

6️⃣ Check Prediction Status (HTTP Request) πŸ”„ Calls Replicate API β†’ /v1/predictions/{id}

  • Checks whether the video is still processing or finished

7️⃣ Check If Complete (IF Node) ❓ Compares status β†’ succeeded or not

  • βœ… If complete β†’ goes to Process Result
  • ❌ If not β†’ loops back to Wait and tries again

πŸ’‘ Beginner Benefit: βœ… Automatic re-checking β†’ you don’t need to refresh manually βœ… Works until result is ready


🟑 Section 4: Process Final Result

πŸ”— Nodes: 8️⃣ Process Result (Code) πŸ“₯ Once complete, extracts:

  • βœ… Status
  • 🎞️ Output video URL
  • πŸ“Š Generation metrics
  • ⏱️ Timestamps (created_at, completed_at)
  • 🧩 Model used

Final output = direct video URL you can download/share πŸŽ₯


πŸ“Š Final Overview

Section What Happens Why It’s Useful
🟒 Auth Manual Trigger + API Key Secure, easy start
πŸ”΅ Send Create Prediction + Extract ID Kicks off video generation
🟣 Poll Wait + Check Status + IF Auto-checks progress until done
🟑 Result Process Result Gives final video link + metadata

πŸš€ Why This Workflow Rocks

  • πŸŽ₯ Video from Image + Prompt β†’ AI-powered video generation in minutes
  • πŸ”„ Fully automated β†’ from request to final video, no manual checks
  • πŸ”‘ Secure β†’ API keys handled safely
  • βš™οΈ Customizable β†’ tweak frames, FPS, prompt, seed

✨ With this workflow, you’ve got a personal AI video generator inside n8n β€” all you need to do is provide a prompt + input image/video, and you’ll get a fresh AI video link back.