AutomationFlowsWeb Scraping › Generate Videos From Text Prompts Using Gpt-5 and Google Veo-3

Generate Videos From Text Prompts Using Gpt-5 and Google Veo-3

ByAI/ML API | D1m7asis @d1m7asis on n8n.io

This workflow contains community nodes that are only compatible with the self-hosted version of n8n.

Chat trigger trigger★★★★☆ complexityAI-powered20 nodesChat TriggerHTTP RequestN8N Nodes AimlapiStop And Error
Web Scraping Trigger: Chat trigger Nodes: 20 Complexity: ★★★★☆ AI nodes: yes Added:

This workflow corresponds to n8n.io template #7328 — we link there as the canonical source.

This workflow follows the Chat Trigger → HTTP Request recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "88472c30-7089-4a1b-8cd0-86773af42a69",
      "name": "When chat message received",
      "type": "@n8n/n8n-nodes-langchain.chatTrigger",
      "position": [
        -2272,
        3136
      ],
      "parameters": {
        "options": {}
      },
      "typeVersion": 1.3
    },
    {
      "id": "f6ebf45d-eefa-4a2c-a91e-7e722905b937",
      "name": "Sticky Note7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1584,
        3056
      ],
      "parameters": {
        "width": 246,
        "height": 248,
        "content": "Set API Key created in Step 2"
      },
      "typeVersion": 1
    },
    {
      "id": "457e9064-6c7a-4b8d-8b83-2bda9cca1e10",
      "name": "Sticky Note9",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -256,
        2976
      ],
      "parameters": {
        "color": 5,
        "width": 182,
        "height": 448,
        "content": "## Get and download your video"
      },
      "typeVersion": 1
    },
    {
      "id": "e92714de-492c-449e-b85e-cb7546035de2",
      "name": "Sticky Note10",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2320,
        2976
      ],
      "parameters": {
        "color": 5,
        "width": 710,
        "height": 448,
        "content": "### Start and Prompt Enhancing"
      },
      "typeVersion": 1
    },
    {
      "id": "fe757385-c6bc-48bf-b594-61c33595c4f8",
      "name": "Get Video File",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -208,
        3120
      ],
      "parameters": {
        "url": "={{ $json.video.url }}",
        "options": {}
      },
      "typeVersion": 4.2
    },
    {
      "id": "89e22673-971c-48e2-b2ba-9cf714a5672f",
      "name": "Get status1",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1024,
        3056
      ],
      "parameters": {
        "url": "=https://api.aimlapi.com/v2/generate/video/google/generation",
        "options": {},
        "sendQuery": true,
        "authentication": "predefinedCredentialType",
        "queryParameters": {
          "parameters": [
            {
              "name": "generation_id",
              "value": "={{ $json.id }}"
            }
          ]
        },
        "nodeCredentialType": "aimlApi"
      },
      "credentials": {
        "aimlApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "91aedd47-2f11-45b0-a862-5c462522c00d",
      "name": "Create Video with AI/ML API1",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1504,
        3136
      ],
      "parameters": {
        "url": "https://api.aimlapi.com/v2/generate/video/google/generation",
        "method": "POST",
        "options": {},
        "sendBody": true,
        "sendHeaders": true,
        "authentication": "predefinedCredentialType",
        "bodyParameters": {
          "parameters": [
            {
              "name": "prompt",
              "value": "={{ $json.content || $('When chat message received').item.json.chatInput }}"
            },
            {
              "name": "model",
              "value": "google/veo-3.0-i2v-fast"
            },
            {
              "name": "image_url",
              "value": "={{ $('Set image URL').item.json.image_url }}"
            }
          ]
        },
        "headerParameters": {
          "parameters": [
            {
              "name": "Content-Type",
              "value": "application/json"
            }
          ]
        },
        "nodeCredentialType": "aimlApi"
      },
      "credentials": {
        "aimlApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "f5c04744-26fa-4fa0-9044-293b6e657f42",
      "name": "Sticky Note18",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1600,
        2976
      ],
      "parameters": {
        "color": 5,
        "width": 1328,
        "height": 448,
        "content": "# Generate Video via VEO-3"
      },
      "typeVersion": 1
    },
    {
      "id": "050a6dbc-c0df-40de-96d2-e3bb6ea4e25a",
      "name": "Wait 30 sec.1",
      "type": "n8n-nodes-base.wait",
      "position": [
        -1248,
        3136
      ],
      "parameters": {
        "amount": 30
      },
      "typeVersion": 1.1
    },
    {
      "id": "2d8638ee-7888-4071-8ccf-bd356a7e2390",
      "name": "Cinematic Prompt (GPT\u20115)",
      "type": "n8n-nodes-aimlapi.aimlApi",
      "position": [
        -1808,
        3136
      ],
      "parameters": {
        "model": "openai/gpt-5-mini-2025-08-07",
        "prompt": "=You are a creative video prompt engineer.\n\nTurn the idea below into a short, visually rich description for Veo\u20113 image\u2011to\u2011video.\nKeep it flexible and cinematic.\n\nGuidelines (use loosely):\n- mention camera movement / lens hints\n- time of day, mood, color palette\n- pacing / motion style\n- framing and composition\n\nKeep it to 2\u20134 sentences (under 120 words). If the input is just one word, expand it sensibly.\n\nIdea:\n{{ $('When chat message received').item.json.chatInput }}\n\nRespond with only the prompt text.",
        "options": {
          "maxTokens": 5000
        },
        "requestOptions": {}
      },
      "credentials": {
        "aimlApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "a483c79a-4ccb-472e-9730-94fa1e95475f",
      "name": "Sticky Note21",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1888,
        3024
      ],
      "parameters": {
        "width": 246,
        "height": 328,
        "content": "Use GPT\u20115 turbo to expand the description into a Veo\u20113\u2011friendly prompt (camera, movement, mood, composition)."
      },
      "typeVersion": 1
    },
    {
      "id": "03143475-6fb7-45ea-a76b-5ad1c5ad20de",
      "name": "Set image URL",
      "type": "n8n-nodes-base.set",
      "position": [
        -2064,
        3136
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "336c8e79-0530-4c17-ac6c-129d946d421b",
              "name": "image_url",
              "type": "string",
              "value": "https://s2-111386.kwimgs.com/bs2/mmu-aiplatform-temp/kling/20240620/1.jpeg"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "3e40b553-d9e2-4046-95b1-13b4185ce45f",
      "name": "Completed?",
      "type": "n8n-nodes-base.if",
      "position": [
        -816,
        3136
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "or",
          "conditions": [
            {
              "id": "383d112e-2cc6-4dd4-8985-f09ce0bd1781",
              "operator": {
                "name": "filter.operator.equals",
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.status }}",
              "rightValue": "completed"
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "827a937e-ba7b-417d-9dd4-8a180d61417e",
      "name": "Error?",
      "type": "n8n-nodes-base.if",
      "position": [
        -608,
        3200
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "7d9027b3-9662-4030-aafd-0c4a33d49eac",
              "operator": {
                "name": "filter.operator.equals",
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.status }}",
              "rightValue": "error"
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "321f4fa4-3239-486c-b3b4-55f34ef7034d",
      "name": "Stop and Error",
      "type": "n8n-nodes-base.stopAndError",
      "position": [
        -400,
        3216
      ],
      "parameters": {
        "errorMessage": "={{ $json.error.message }}"
      },
      "typeVersion": 1
    },
    {
      "id": "22f8f3a9-ea96-438b-b276-f8b9e9f52370",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1712,
        1744
      ],
      "parameters": {
        "width": 436,
        "height": 424,
        "content": "## STEP 1: CHAT INPUT \u2192 MINIMAL PROMPT\n\nThis workflow starts from the **Chat Trigger**. You can send even **one word** (e.g., \u201csunset\u201d, \u201ccyberpunk\u201d, \u201cocean\u201d).\n\n**Expected fields** (flexible):\n- **chatInput** \u2013 your idea/keyword/short brief (required)\n- **image_url** \u2013 a source image for image\u2011to\u2011video (required for i2v)\n- **duration** \u2013 seconds (optional, default 5)\n- **aspect_ratio** \u2013 e.g. `16:9` (optional)\n\nThe chat message is expanded by **GPT\u20115** into a Veo\u20113\u2011friendly prompt."
      },
      "typeVersion": 1
    },
    {
      "id": "19a2c274-f8dd-4c91-bc9a-8042558d7162",
      "name": "Sticky Note19",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1248,
        2448
      ],
      "parameters": {
        "width": 484,
        "height": 452,
        "content": "## STEP 4: MAIN FLOW (END\u2011TO\u2011END)\n\n**How it runs**\n- Trigger via **Chat** (or attach a **Schedule Trigger** if you want batch runs).\n\n**Pipeline**\n1) Read chat input (idea/keyword)\n2) **GPT\u20115** expands it into a concise cinematic prompt\n3) **Create Veo\u20113 (image\u2011to\u2011video)** with image_url + prompt\n4) **Poll status** until `completed`\n5) On success \u2192 fetch **video_url** and (optionally) generate a short **title** with GPT\u20115\n6) Return results to chat / continue with your own save or publish steps\n\nTweak polling interval based on your SLA and quota."
      },
      "typeVersion": 1
    },
    {
      "id": "a816072b-bfc0-4253-9222-b23ce903f10f",
      "name": "Sticky Note20",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1248,
        2048
      ],
      "parameters": {
        "width": 484,
        "height": 364,
        "content": "## STEP 2: AI/ML API CREDENTIALS\n\n1) Get your key: https://aimlapi.com/app/keys\n2) In n8n, create **AI/ML account** credentials (Bearer YOUR_TOKEN_HERE)\n3) Use that credential in:\n   - **GPT\u20115** node (text expansion)\n   - **Create Video** (Veo\u20113 generation)\n   - **Get Status** (polling)\n\n**Headers** (handled by credentials):\n- Authorization: `Bearer YOUR_TOKEN_HERE`\n- Content\u2011Type: `application/json`\n\nKeep keys in Credentials/ENV \u2014 never hard\u2011code in nodes."
      },
      "typeVersion": 1
    },
    {
      "id": "893fd045-f95f-4d59-a455-08bc88991271",
      "name": "Sticky Note22",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1712,
        2192
      ],
      "parameters": {
        "width": 436,
        "height": 520,
        "content": "## STEP 3 (OPTIONAL): SAVE & PUBLISH\n\nAfter you obtain `video_url`, you can extend the flow with:\n\n- **Save to Google Drive**: HTTP \u2192 upload file from `video_url`\n- **Generate SEO Title**: GPT\u20115 short title (\u226460 chars)\n- **Publish to YouTube**: your preferred uploader or API wrapper\n- **Log to a Sheet/DB**: store `prompt`, `generation_id`, `video_url`, `title`\n\nThese are optional and not required for the core Veo\u20113 image\u2011to\u2011video path."
      },
      "typeVersion": 1
    },
    {
      "id": "782053ae-2203-49d7-8e82-800d4fb4aef7",
      "name": "Sticky Note23",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1248,
        1648
      ],
      "parameters": {
        "color": 3,
        "width": 484,
        "height": 376,
        "content": "**Veo\u20113 Image\u2011to\u2011Video with GPT\u20115 (Chat\u2011First)**\n\n**What this workflow does**\n- Accepts a minimal chat idea (even one word)\n- Uses **GPT\u20115** to craft a Veo\u20113\u2011ready prompt\n- Creates a **Google Veo\u20113** image\u2011to\u2011video generation\n- Polls until completion and fetches the **final video URL**\n\n**Why it\u2019s robust**\n- Soft prompt: expands short inputs sensibly\n- Fallbacks: if GPT output is empty, uses chat input\n- Safe polling: completed / failed split, adjustable wait\n\n**Where to extend**\n- Save to Drive, generate thumbnails, add subtitles, upload to YouTube, log analytics"
      },
      "typeVersion": 1
    }
  ],
  "connections": {
    "Error?": {
      "main": [
        [
          {
            "node": "Stop and Error",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait 30 sec.1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Completed?": {
      "main": [
        [
          {
            "node": "Get Video File",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Error?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get status1": {
      "main": [
        [
          {
            "node": "Completed?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set image URL": {
      "main": [
        [
          {
            "node": "Cinematic Prompt (GPT\u20115)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait 30 sec.1": {
      "main": [
        [
          {
            "node": "Get status1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Video File": {
      "main": [
        []
      ]
    },
    "Cinematic Prompt (GPT\u20115)": {
      "main": [
        [
          {
            "node": "Create Video with AI/ML API1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When chat message received": {
      "main": [
        [
          {
            "node": "Set image URL",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create Video with AI/ML API1": {
      "main": [
        [
          {
            "node": "Wait 30 sec.1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}

Credentials you'll need

Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.

Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

This workflow contains community nodes that are only compatible with the self-hosted version of n8n.

Source: https://n8n.io/workflows/7328/ — original creator credit. Request a take-down →

More Web Scraping workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

Web Scraping

pfe-hunter-sophistique. Uses lmChatGroq, chatTrigger, chainLlm, httpRequest. Chat trigger; 24 nodes.

Groq Chat, Chat Trigger, Chain Llm +1
Web Scraping

Use cases are many: Compare costs across different models, plan your AI budget, optimize prompts for cost efficiency, or track expenses for client billing! OpenRouter charges a platform fee on top of

Chat Trigger, Execute Workflow Trigger, Form +4
Web Scraping

Generate Videos from Chat with Google Vertex AI (Veo3) - Beginner Friendly

HTTP Request, Chat Trigger
Web Scraping

This workflow integrates a chatbot frontend with a backend powered by Langflow, a visual low-code AI development tool. The flow is triggered whenever a chat message is received via the n8n chatbot wid

Chat Trigger, HTTP Request
Web Scraping

This n8n workflow enables you to chat with the uncensored Dolphin Mixtral 8x22B large language model through the Novita AI inference. It provides a streamlined process for sending user messages to the

Chat Trigger, HTTP Request