This workflow corresponds to n8n.io template #8205 — we link there as the canonical source.
This workflow follows the Agent → Google Drive 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 →
{
"id": "ySznauhiBaq3fJaY",
"meta": {
"templateCredsSetupCompleted": true
},
"name": "Gemini_NanoBanana_Template",
"tags": [
{
"id": "vQcdMpzndwlrDhbx",
"name": "n8n_official_template",
"createdAt": "2025-07-02T13:54:20.087Z",
"updatedAt": "2025-07-02T13:54:20.087Z"
}
],
"nodes": [
{
"id": "481d7713-dea3-42e5-b37e-8c0d248aea45",
"name": "When clicking \u2018Execute workflow\u2019",
"type": "n8n-nodes-base.manualTrigger",
"position": [
-416,
-768
],
"parameters": {},
"typeVersion": 1
},
{
"id": "7635ea3e-e3cb-4692-8ce9-47cd715ce143",
"name": "Sticky Note",
"type": "n8n-nodes-base.stickyNote",
"disabled": true,
"position": [
-752,
-784
],
"parameters": {
"width": 2064,
"height": 192,
"content": "### \ud83d\udfe8 Zone 1: Create Image\n\n1. **When clicking 'Execute workflow**\n2. **Get ImageURL and Prompt(Google Sheets)**\n3. **Create Image by Fal.ai (nano banana)**\n4. **Analys image for preparing video**"
},
"typeVersion": 1
},
{
"id": "1ed6cdf6-6efb-4194-8837-569df0756677",
"name": "Sticky Note1",
"type": "n8n-nodes-base.stickyNote",
"disabled": true,
"position": [
-752,
-576
],
"parameters": {
"color": 2,
"width": 2064,
"height": 240,
"content": "### \ud83d\udfeb Zone 2:Generate Video\n\n1. **Prepare Prompt for Video**\n2. **Call Fal.ai API (Seedance/Wan2.2)**\n3. **Loop Over Items**\n4. **Wait for the video / Get the video status / Video status**\n5. **Upload Video to Google Drive**\n5. **Upload Video URL**"
},
"typeVersion": 1
},
{
"id": "ff3727e9-21b6-4e75-8711-fa76c749809d",
"name": "Sticky Note4",
"type": "n8n-nodes-base.stickyNote",
"disabled": true,
"position": [
-752,
-320
],
"parameters": {
"color": 4,
"width": 672,
"height": 656,
"content": "## Product Image\n\n"
},
"typeVersion": 1
},
{
"id": "fab0a010-d8be-42ca-98bd-a7fd0a7e5f3d",
"name": "Sticky Note5",
"type": "n8n-nodes-base.stickyNote",
"disabled": true,
"position": [
0,
-320
],
"parameters": {
"color": 4,
"width": 656,
"height": 656,
"content": "## Product Image - nano Banana\n\n"
},
"typeVersion": 1
},
{
"id": "5dbbeeda-0a98-4672-b89a-112193eb948d",
"name": "Sticky Note6",
"type": "n8n-nodes-base.stickyNote",
"disabled": true,
"position": [
768,
-320
],
"parameters": {
"color": 4,
"width": 528,
"height": 656,
"content": "## Product Video - Veo3\n\n\n## Product Video - Wan2.2\n"
},
"typeVersion": 1
},
{
"id": "540b8055-4c2d-478e-bbe7-996d6dd1d0b3",
"name": "Sticky Note7",
"type": "n8n-nodes-base.stickyNote",
"disabled": true,
"position": [
-752,
-992
],
"parameters": {
"width": 2064,
"height": 192,
"content": "### \ud83d\udfe8 Zone 1: Create Image by nano Bananna\n\n1. **When clicking 'Execute workflow**\n2. **Get ImageURL and Prompt(Google Sheets)**\n3. **Create Image by OpernRouter (gemini-2.5-flash-image-preview:free)**\n4. **Upload to Google drive /output**\n5. **Update URL**\n"
},
"typeVersion": 1
},
{
"id": "0d1012fe-1f69-4693-82f8-c7f2af86d76a",
"name": "Get Data1",
"type": "n8n-nodes-base.googleSheets",
"position": [
-240,
-960
],
"parameters": {
"options": {
"returnFirstMatch": true
},
"filtersUI": {
"values": [
{
"lookupColumn": "img_url"
}
]
},
"sheetName": {
"__rl": true,
"mode": "list",
"value": 997043272,
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY/edit#gid=997043272",
"cachedResultName": "Gemini"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY/edit?usp=drivesdk",
"cachedResultName": "n8n_nanoBanan_FalAI"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"name": "<your credential>"
}
},
"typeVersion": 4.6
},
{
"id": "55f2026c-5ec4-46f2-ac99-6e9300d2cefd",
"name": "Convert to File",
"type": "n8n-nodes-base.convertToFile",
"position": [
624,
-960
],
"parameters": {
"options": {
"fileName": "={{ $json.fileName }}",
"mimeType": "={{ $json.mimeType }}"
},
"operation": "toBinary",
"sourceProperty": "data"
},
"typeVersion": 1.1
},
{
"id": "63e86079-f906-424a-9d0a-ce4d01ad0634",
"name": "setImgeURL",
"type": "n8n-nodes-base.set",
"position": [
-80,
-960
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "044f40af-ec59-45e6-a097-678a473b7a8d",
"name": "presenter",
"type": "string",
"value": "={{ (() => { const u = $json.presenter || ''; const q = u.match(/[?&]id=([-\\w]{25,})/); const d = u.match(/\\/d\\/([-\\w]{25,})/); const any = u.match(/[-\\w]{25,}/); const id = q?.[1] || d?.[1] || (any ? any[0] : ''); return id ? 'https://drive.google.com/uc?export=view&id=' + id : ''; })() }}"
},
{
"id": "62a409c6-c607-452b-9bbb-f3d29c86dddf",
"name": "product",
"type": "string",
"value": "={{ (() => { const u = $json.product || ''; const q = u.match(/[?&]id=([-\\w]{25,})/); const d = u.match(/\\/d\\/([-\\w]{25,})/); const any = u.match(/[-\\w]{25,}/); const id = q?.[1] || d?.[1] || (any ? any[0] : ''); return id ? 'https://drive.google.com/uc?export=view&id=' + id : ''; })() }}"
}
]
},
"includeOtherFields": true
},
"typeVersion": 3.4
},
{
"id": "849a7ac8-9892-44b3-a9af-49530dd1a71e",
"name": "CreateImagebyOpernRouter (gemini-2.5-flash-image-preview:free)",
"type": "n8n-nodes-base.httpRequest",
"position": [
96,
-960
],
"parameters": {
"url": "https://openrouter.ai/api/v1/chat/completions",
"method": "POST",
"options": {},
"jsonBody": "={\n \"model\": \"google/gemini-2.5-flash-image-preview:free\",\n \"messages\": [\n {\n \"role\": \"user\",\n \"content\": [\n {\n \"type\": \"text\",\n \"text\": \"{{ $json.prompt }}\"\n },\n {\n \"type\": \"image_url\",\n \"image_url\": {\n \"url\": \"{{ $json.product }}\"\n }\n }\n ]\n }\n ]\n} ",
"sendBody": true,
"specifyBody": "json",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"notesInFlow": true,
"typeVersion": 4.2
},
{
"id": "ab591887-6ac9-48ee-86d1-a08e868749ab",
"name": "wait20sec",
"type": "n8n-nodes-base.wait",
"position": [
272,
-960
],
"parameters": {
"amount": 10
},
"typeVersion": 1.1
},
{
"id": "6ca128d7-f859-43ad-bd73-368d6c30eee7",
"name": "setBase64data",
"type": "n8n-nodes-base.code",
"position": [
448,
-960
],
"parameters": {
"jsCode": "const dataUri = $json[\"choices\"][0][\"message\"][\"images\"][0][\"image_url\"][\"url\"];\nconst [meta, base64] = dataUri.split(\",\");\nconst mime = meta.match(/:(.*?);/)[1]; // \u0e14\u0e36\u0e07 image/png\nconst ext = mime.split(\"/\")[1]; // png\n\nreturn {\n data: base64,\n mimeType: mime,\n fileName: `output.${ext}`\n};\n"
},
"typeVersion": 2
},
{
"id": "d3e80f31-1fc1-4df2-8dd7-34c784f5f7d3",
"name": "uploadImagetoGdrive",
"type": "n8n-nodes-base.googleDrive",
"position": [
800,
-960
],
"parameters": {
"name": "output.png",
"driveId": {
"__rl": true,
"mode": "list",
"value": "My Drive"
},
"options": {},
"folderId": {
"__rl": true,
"mode": "list",
"value": "1WUzYyF-Uo45wCLQaQRAuhsvCYC0lHJ9O",
"cachedResultUrl": "https://drive.google.com/drive/folders/1WUzYyF-Uo45wCLQaQRAuhsvCYC0lHJ9O",
"cachedResultName": "imageOutput"
}
},
"credentials": {
"googleDriveOAuth2Api": {
"name": "<your credential>"
}
},
"typeVersion": 3
},
{
"id": "2ec6e0e6-0e78-4775-84b7-41e2dee4e235",
"name": "updateImageURL",
"type": "n8n-nodes-base.googleSheets",
"position": [
976,
-960
],
"parameters": {
"columns": {
"value": {
"img_url": "={{ $json.webViewLink }}",
"product": "={{ $('Get Data1').item.json.product }}"
},
"schema": [
{
"id": "presenter",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "presenter",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "product",
"type": "string",
"display": true,
"removed": false,
"required": false,
"displayName": "product",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "prompt",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "prompt",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "model",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "model",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "duration",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "duration",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "generate_audio",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "generate_audio",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "resolutio",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "resolutio",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "img_url",
"type": "string",
"display": true,
"required": false,
"displayName": "img_url",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "video_url",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "video_url",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [
"product"
],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "appendOrUpdate",
"sheetName": {
"__rl": true,
"mode": "list",
"value": 997043272,
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY/edit#gid=997043272",
"cachedResultName": "Gemini"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY/edit?usp=drivesdk",
"cachedResultName": "n8n_nanoBanan_FalAI"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"name": "<your credential>"
}
},
"typeVersion": 4.6
},
{
"id": "a381a991-ec85-4a9f-993b-193a5808f1d8",
"name": "HTTP Request",
"type": "n8n-nodes-base.httpRequest",
"position": [
1024,
-576
],
"parameters": {
"url": "={{ $json.video.url }}",
"options": {},
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"typeVersion": 4.2
},
{
"id": "c393bdf9-ee80-44db-9bff-84fbc6f74d47",
"name": "uploadImagetoGdrive1",
"type": "n8n-nodes-base.googleDrive",
"position": [
1168,
-576
],
"parameters": {
"name": "={{ $json.video.url }}",
"driveId": {
"__rl": true,
"mode": "list",
"value": "My Drive"
},
"options": {},
"folderId": {
"__rl": true,
"mode": "list",
"value": "1WUzYyF-Uo45wCLQaQRAuhsvCYC0lHJ9O",
"cachedResultUrl": "https://drive.google.com/drive/folders/1WUzYyF-Uo45wCLQaQRAuhsvCYC0lHJ9O",
"cachedResultName": "imageOutput"
}
},
"credentials": {
"googleDriveOAuth2Api": {
"name": "<your credential>"
}
},
"typeVersion": 3
},
{
"id": "bb9d425a-1dc2-4f71-a22c-a3995e6df83a",
"name": "updateVideoURL",
"type": "n8n-nodes-base.googleSheets",
"position": [
1088,
-448
],
"parameters": {
"columns": {
"value": {
"product": "={{ $('Get Data').item.json.product }}",
"video_url": "={{ $json.webViewLink }}"
},
"schema": [
{
"id": "presenter",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "presenter",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "product",
"type": "string",
"display": true,
"removed": false,
"required": false,
"displayName": "product",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "prompt",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "prompt",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "model",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "model",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "duration",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "duration",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "generate_audio",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "generate_audio",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "resolutio",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "resolutio",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "img_url",
"type": "string",
"display": true,
"removed": true,
"required": false,
"displayName": "img_url",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "video_url",
"type": "string",
"display": true,
"removed": false,
"required": false,
"displayName": "video_url",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [
"product"
],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "appendOrUpdate",
"sheetName": {
"__rl": true,
"mode": "list",
"value": 997043272,
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY/edit#gid=997043272",
"cachedResultName": "Gemini"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY/edit?usp=drivesdk",
"cachedResultName": "n8n_nanoBanan_FalAI"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"name": "<your credential>"
}
},
"typeVersion": 4.6
},
{
"id": "93af04aa-a869-419a-b6aa-c47cce1b9071",
"name": "Call Fal.ai API (WAN2.2)",
"type": "n8n-nodes-base.httpRequest",
"disabled": true,
"position": [
0,
-416
],
"parameters": {
"url": "=https://queue.fal.run/fal-ai/wan/v2.2-a14b/image-to-video",
"method": "=POST",
"options": {},
"sendBody": true,
"authentication": "genericCredentialType",
"bodyParameters": {
"parameters": [
{
"name": "prompt",
"value": "=<Characters>\n{{ $json.output.characters.map(character => `<Character>\n <Name>${character.name}</Name>\n <Description>${character.description}</Description>\n</Character>`).join('\\n') }}\n</Characters>\n\n<SceneDescription>\n{{ $json.output.scene_description }}\n</SceneDescription>\n\n<CameraMovements>\n{{ $json.output.camera_movement }}\n</CameraMovements>\n\n<ObjectMovements>\n{{ $json.output.object_movements }}\n</ObjectMovements>"
},
{
"name": "num_frames",
"value": "81"
},
{
"name": "frames_per_second",
"value": "18"
},
{
"name": "resolution",
"value": "720p"
},
{
"name": "aspect_ratio",
"value": "auto"
},
{
"name": "num_inference_steps",
"value": "27"
},
{
"name": "enable_safety_checker",
"value": "true"
},
{
"name": "enable_prompt_expansion",
"value": "false"
},
{
"name": "acceleration",
"value": "regular"
},
{
"name": "guidance_scale",
"value": "3.5"
},
{
"name": "guidance_scale_2",
"value": "3.5"
},
{
"name": "shift",
"value": "5"
},
{
"name": "interpolator_model",
"value": "film"
},
{
"name": "num_interpolated_frames",
"value": "1"
},
{
"name": "adjust_fps_for_interpolation",
"value": "true"
},
{
"name": "image_url",
"value": "={{ $('Get the image').item.json.images[0].url }}"
}
]
},
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"typeVersion": 4.2
},
{
"id": "3347378b-bcfa-4a45-94f4-f124c554e882",
"name": "Analyze image",
"type": "@n8n/n8n-nodes-langchain.openAi",
"position": [
992,
-784
],
"parameters": {
"text": "Analyze the image: is it a product, a character, or both?\n\nIf product \u2192 return JSON:\n brand_name: (brand if visible/inferable)\n color_scheme:\n - hex: (HEX of main colors)\n name: (color name)\n font_style: (if visible)\n visible_text: |\n (all legible text exactly)\n product_type: (type of product)\n visual_description: (1\u20132 sentences about subject)\n\nIf character \u2192 return JSON:\n character_name: (if known/inferable)\n color_scheme:\n - hex: (HEX of main colors on outfit/character)\n name: (color name)\n outfit_style: (clothes/accessories)\n visual_description: (1\u20132 sentences about subject)\n\nOutput JSON only.\n",
"modelId": {
"__rl": true,
"mode": "list",
"value": "chatgpt-4o-latest",
"cachedResultName": "CHATGPT-4O-LATEST"
},
"options": {},
"resource": "image",
"imageUrls": "={{ (() => {\n // \u0e40\u0e25\u0e37\u0e2d\u0e01\u0e04\u0e48\u0e32\u0e41\u0e23\u0e01\u0e17\u0e35\u0e48\u0e21\u0e35 \u0e41\u0e25\u0e30 trim \u0e0a\u0e48\u0e2d\u0e07\u0e27\u0e48\u0e32\u0e07/\u0e02\u0e36\u0e49\u0e19\u0e1a\u0e23\u0e23\u0e17\u0e31\u0e14\u0e43\u0e2b\u0e21\u0e48\n const raw = ($json?.images?.[0]?.url ?? $json?.img_url ?? $json?.image_url ?? '')\n .toString()\n .trim();\n\n if (!raw) return '';\n\n // \u0e16\u0e49\u0e32\u0e44\u0e21\u0e48\u0e43\u0e0a\u0e48 Google Drive \u0e01\u0e47\u0e2a\u0e48\u0e07\u0e2d\u0e2d\u0e01\u0e44\u0e1b\u0e40\u0e25\u0e22\n if (!raw.includes('drive.google.com')) return raw;\n\n // \u0e41\u0e22\u0e01 fileId \u0e08\u0e32\u0e01\u0e17\u0e31\u0e49\u0e07 2 \u0e23\u0e39\u0e1b\u0e41\u0e1a\u0e1a\n const idFromPath = raw.match(/\\/d\\/([^/]+)/)?.[1];\n const idFromQuery = raw.match(/[?&]id=([^&]+)/)?.[1];\n const fileId = idFromPath ?? idFromQuery;\n\n // \u0e41\u0e1b\u0e25\u0e07\u0e40\u0e1b\u0e47\u0e19 direct-download URL (\u0e15\u0e49\u0e2d\u0e07\u0e17\u0e33\u0e44\u0e1f\u0e25\u0e4c\u0e43\u0e2b\u0e49 public \u0e01\u0e48\u0e2d\u0e19)\n return fileId\n ? `https://drive.google.com/uc?export=download&id=${fileId}`\n : raw;\n})() }}\n",
"operation": "analyze"
},
"credentials": {
"openAiApi": {
"name": "<your credential>"
}
},
"typeVersion": 1.8
},
{
"id": "a46204ae-c314-4489-91d8-f7196f0d6926",
"name": "Get the image",
"type": "n8n-nodes-base.httpRequest",
"position": [
800,
-784
],
"parameters": {
"url": "=https://queue.fal.run/fal-ai/nano-banana/requests/{{ $json.request_id }}",
"options": {},
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"retryOnFail": true,
"typeVersion": 4.2,
"alwaysOutputData": false
},
{
"id": "94054e50-9f19-451a-a1a3-ccc4ed31bdb4",
"name": "Wait",
"type": "n8n-nodes-base.wait",
"position": [
608,
-720
],
"parameters": {
"amount": 10
},
"typeVersion": 1.1
},
{
"id": "7defb174-8f13-4216-a0ac-d3e107939e71",
"name": "If",
"type": "n8n-nodes-base.if",
"position": [
448,
-768
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "38f5427f-4fc7-4c07-87d5-fa7f5964deb2",
"operator": {
"name": "filter.operator.equals",
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.status }}",
"rightValue": "=COMPLETED"
}
]
}
},
"typeVersion": 2.2
},
{
"id": "ddaabbef-87d4-48a0-9d73-67941198e0f7",
"name": "Get image status",
"type": "n8n-nodes-base.httpRequest",
"position": [
288,
-768
],
"parameters": {
"url": "={{ $json.status_url }}",
"options": {},
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"typeVersion": 4.2
},
{
"id": "f5d5d006-02e2-4ddc-88f4-53ed734e9834",
"name": "Call Fal.ai API (nannoBanana)",
"type": "n8n-nodes-base.httpRequest",
"position": [
112,
-768
],
"parameters": {
"url": "=https://queue.fal.run/fal-ai/{{ $('Get Data').item.json.model }}/edit",
"method": "=POST",
"options": {},
"jsonBody": "={\n \"prompt\": \"{{ $json.prompt }}\",\n \"image_urls\": [\n \"{{ $json.product }}\"\n ],\n \"num_images\": 1,\n \"output_format\": \"jpeg\"\n}",
"sendBody": true,
"specifyBody": "json",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"typeVersion": 4.2
},
{
"id": "d78f1556-3f05-4000-8bfe-65feab4d1a6d",
"name": "Edit Fields",
"type": "n8n-nodes-base.set",
"position": [
-64,
-768
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "044f40af-ec59-45e6-a097-678a473b7a8d",
"name": "presenter",
"type": "string",
"value": "={{ (() => { const u = $json.presenter || ''; const q = u.match(/[?&]id=([-\\w]{25,})/); const d = u.match(/\\/d\\/([-\\w]{25,})/); const any = u.match(/[-\\w]{25,}/); const id = q?.[1] || d?.[1] || (any ? any[0] : ''); return id ? 'https://drive.google.com/uc?export=view&id=' + id : ''; })() }}"
},
{
"id": "62a409c6-c607-452b-9bbb-f3d29c86dddf",
"name": "product",
"type": "string",
"value": "={{ (() => { const u = $json.product || ''; const q = u.match(/[?&]id=([-\\w]{25,})/); const d = u.match(/\\/d\\/([-\\w]{25,})/); const any = u.match(/[-\\w]{25,}/); const id = q?.[1] || d?.[1] || (any ? any[0] : ''); return id ? 'https://drive.google.com/uc?export=view&id=' + id : ''; })() }}"
}
]
},
"includeOtherFields": true
},
"typeVersion": 3.4
},
{
"id": "7179d640-378b-428c-bd04-defc8e7eab01",
"name": "Get Data",
"type": "n8n-nodes-base.googleSheets",
"position": [
-240,
-768
],
"parameters": {
"options": {},
"filtersUI": {
"values": [
{
"lookupColumn": "video_url"
}
]
},
"sheetName": {
"__rl": true,
"mode": "list",
"value": 658195685,
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY/edit#gid=658195685",
"cachedResultName": "nanoBanana"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1-oeo9nsFGfDUTh2OVXo1bHeoY1JBvSQx5IbDAH37epY/edit?usp=drivesdk",
"cachedResultName": "n8n_nanoBanan_FalAI"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"name": "<your credential>"
}
},
"typeVersion": 4.6
},
{
"id": "27447a25-46b9-4eed-8098-8a9a31dcdd9b",
"name": "Describe Each Scene for Video",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
-336,
-560
],
"parameters": {
"text": "=You are a Video Scene Prompt Generator for Veo3. \nYour job is to take the scene input below and expand it into a detailed 5-second video description, following these rules:\n\n1. Use the scene input as the core reference. Do not remove or alter product names, logos, or visible text from the reference image.\n2. Expand the description into a natural, realistic **UGC-style video scene**. The output must feel authentic, casual, and human-made (like a phone video).\n3. Break down the scene into these sections:\n - Characters: List all characters in the scene with age, attire, appearance, posture, emotion, and what they are doing.\n - Scene Background: Describe the environment in detail (location, lighting, colors, props, atmosphere, time of day).\n - Camera Movement: Describe how the camera moves (handheld, selfie, panning, zooming, tilt, etc.), as if filmed on a smartphone.\n - Movement in Scene: Show how the character(s) and product interact or move naturally in the 5-second clip.\n - Sound Design: Suggest casual voice/dialogue (under 150 characters, natural & authentic tone), plus ambient sounds or background noise that fit the scene.\n\n4. The **dialogue** should sound natural, short, and conversational (like talking to a friend), not scripted or commercial. \n5. Keep everything **photorealistic** and authentic, not overly polished or cinematic. Emphasize realism and relatability.\n\nScene Input (from previous step):\n{{ $json.content }}\n\nReturn your answer in **plain text** exactly in the following structure (no JSON, no extra commentary):\n\nCharacters:\n- ...\n- ...\n\nScene Background: ...\nCamera Movement: ...\nMovement in Scene: ...\nSound Design: ...\n",
"options": {},
"promptType": "define",
"hasOutputParser": true
},
"typeVersion": 2
},
{
"id": "4b806043-08c4-4b6a-bbba-cbde55d56007",
"name": "Loop Over Items",
"type": "n8n-nodes-base.splitInBatches",
"position": [
176,
-560
],
"parameters": {
"options": {}
},
"typeVersion": 3
},
{
"id": "90904d65-9d1f-42e9-beef-3199462d7cff",
"name": "Get the video",
"type": "n8n-nodes-base.httpRequest",
"position": [
864,
-528
],
"parameters": {
"url": "={{ $('Loop Over Items').item.json.response_url }}",
"options": {},
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"retryOnFail": true,
"typeVersion": 4.2,
"alwaysOutputData": false
},
{
"id": "0b24a2a7-6339-4baf-90d7-0f0875870ee4",
"name": "Video status",
"type": "n8n-nodes-base.switch",
"position": [
672,
-512
],
"parameters": {
"rules": {
"values": [
{
"outputKey": "COMPLETED",
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "6fc5bea4-1567-474b-bfca-5394eb303217",
"operator": {
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.status }}",
"rightValue": "COMPLETED"
}
]
},
"renameOutput": true
},
{
"outputKey": "IN_PROGRESS",
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "0882f634-2472-4d24-a1c3-a39f0cd94855",
"operator": {
"name": "filter.operator.equals",
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.status }}",
"rightValue": "IN_PROGRESS"
}
]
},
"renameOutput": true
},
{
"outputKey": "IN_QUEUE",
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "e6c8b207-13ac-4537-8c5c-677039bc2fef",
"operator": {
"name": "filter.operator.equals",
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.status }}",
"rightValue": "IN_QUEUE"
}
]
},
"renameOutput": true
}
]
},
"options": {}
},
"typeVersion": 3.2
},
{
"id": "de378e60-155a-46cc-848f-f106c21827c1",
"name": "Get the video status",
"type": "n8n-nodes-base.httpRequest",
"position": [
512,
-512
],
"parameters": {
"url": "={{ $('Loop Over Items').item.json.status_url }}",
"options": {},
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"typeVersion": 4.2
},
{
"id": "1b1be4c2-7825-41fb-9d0c-8bbedab5335c",
"name": "Wait for the video",
"type": "n8n-nodes-base.wait",
"position": [
352,
-512
],
"parameters": {},
"typeVersion": 1.1
},
{
"id": "a0830568-00ba-473d-9cf4-70b55204a81b",
"name": "Structured Output Parser2",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
-288,
-432
],
"parameters": {
"autoFix": true,
"schemaType": "manual",
"inputSchema": "{\n \"type\": \"object\",\n \"properties\": {\n \"characters\": {\n \"type\": \"array\",\n \"description\": \"the list of characters in the scene\",\n \"items\": {\n \"type\": \"object\",\n \"properties\": {\n \"name\": {\n \"type\": \"string\",\n \"description\": \"the name of the character\"\n },\n \"description\": {\n \"type\": \"string\",\n \"description\": \"the detailed description of the character (visual outlook)\"\n }\n },\n \"required\": [\n \"name\",\n \"description\"\n ]\n }\n },\n \"scene_description\": {\n \"type\": \"string\",\n \"description\": \"the detailed description of the scene\"\n },\n \"camera_movement\": {\n \"type\": \"string\",\n \"description\": \"the description of the camera movement (if any)\"\n },\n \"object_movements\": {\n \"type\": \"string\",\n \"description\": \"the detailed description of the movement of the objects on the screen\"\n },\n \"sound_effects\": {\n \"type\": \"string\",\n \"description\": \"the sound effects the viewer can hear during the scene\"\n }\n },\n \"required\": [\n \"characters\",\n \"scene_description\",\n \"camera_movement\",\n \"object_movements\",\n \"sound_effects\"\n ]\n}"
},
"typeVersion": 1.2
},
{
"id": "c999283b-e187-4cf0-a35b-7dfa980a97b2",
"name": "OpenAI Chat Model1",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
-368,
-432
],
"parameters": {
"model": {
"__rl": true,
"mode": "list",
"value": "gpt-4o",
"cachedResultName": "gpt-4o"
},
"options": {}
},
"credentials": {
"openAiApi": {
"name": "<your credential>"
}
},
"typeVersion": 1.2
},
{
"id": "ae94893c-3604-40a3-acd0-6959adb68c23",
"name": "Veo3",
"type": "n8n-nodes-base.httpRequest",
"position": [
0,
-560
],
"parameters": {
"url": "https://queue.fal.run/fal-ai/veo3/image-to-video",
"method": "POST",
"options": {},
"jsonBody": "={\n \"prompt\": \"{{ $json.output.characters[0].description }}{{ $json.output.scene_description }}{{ $json.output.camera_movement }}{{ $json.output.object_movements }}{{ $json.output.sound_effects }}\",\n \"image_url\": \"{{ $('Get the image').item.json.images[0].url }}\",\n \"duration\": \"8s\",\n \"generate_audio\": true,\n \"resolution\": \"720p\"\n }",
"sendBody": true,
"specifyBody": "json",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"typeVersion": 4.2
}
],
"active": false,
"settings": {
"executionOrder": "v1"
},
"versionId": "86a8a9cb-697d-4e5f-99ee-f40cc55b8081",
"connections": {
"If": {
"main": [
[
{
"node": "Get the image",
"type": "main",
"index": 0
}
],
[
{
"node": "Wait",
"type": "main",
"index": 0
}
]
]
},
"Veo3": {
"main": [
[
{
"node": "Loop Over Items",
"type": "main",
"index": 0
}
]
]
},
"Wait": {
"main": [
[
{
"node": "Get image status",
"type": "main",
"index": 0
}
]
]
},
"Get Data": {
"main": [
[
{
"node": "Edit Fields",
"type": "main",
"index": 0
}
]
]
},
"Get Data1": {
"main": [
[
{
"node": "setImgeURL",
"type": "main",
"index": 0
}
]
]
},
"wait20sec": {
"main": [
[
{
"node": "setBase64data",
"type": "main",
"index": 0
}
]
]
},
"setImgeURL": {
"main": [
[
{
"node": "CreateImagebyOpernRouter (gemini-2.5-flash-image-preview:free)",
"type": "main",
"index": 0
}
]
]
},
"Edit Fields": {
"main": [
[
{
"node": "Call Fal.ai API (nannoBanana)",
"type": "main",
"index": 0
}
]
]
},
"HTTP Request": {
"main": [
[
{
"node": "uploadImagetoGdrive1",
"type": "main",
"index": 0
}
]
]
},
"Video status": {
"main": [
[
{
"node": "Get the video",
"type": "main",
"index": 0
}
],
[
{
"node": "Wait for the video",
"type": "main",
"index": 0
}
],
[
{
"node": "Wait for the video",
"type": "main",
"index": 0
}
]
]
},
"Analyze image": {
"main": [
[
{
"node": "Describe Each Scene for Video",
"type": "main",
"index": 0
}
]
]
},
"Get the image": {
"main": [
[
{
"node": "Analyze image",
"type": "main",
"index": 0
}
]
]
},
"setBase64data": {
"main": [
[
{
"node": "Convert to File",
"type": "main",
"index": 0
}
]
]
},
"Get the video": {
"main": [
[
{
"node": "Loop Over Items",
"type": "main",
"index": 0
}
]
]
},
"updateImageURL": {
"main": [
[]
]
},
"Convert to File": {
"main": [
[
{
"node": "uploadImagetoGdrive",
"type": "main",
"index": 0
}
]
]
},
"Loop Over Items": {
"main": [
[
{
"node": "HTTP Request",
"type": "main",
"index": 0
}
],
[
{
"node": "Wait for the video",
"type": "main",
"index": 0
}
]
]
},
"Get image status": {
"main": [
[
{
"node": "If",
"type": "main",
"index": 0
}
]
]
},
"OpenAI Chat Model1": {
"ai_languageModel": [
[
{
"node": "Structured Output Parser2",
"type": "ai_languageModel",
"index": 0
},
{
"node": "Describe Each Scene for Video",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Wait for the video": {
"main": [
[
{
"node": "Get the video status",
"type": "main",
"index": 0
}
]
]
},
"uploadImagetoGdrive": {
"main": [
[
{
"node": "updateImageURL",
"type": "main",
"index": 0
}
]
]
},
"Get the video status": {
"main": [
[
{
"node": "Video status",
"type": "main",
"index": 0
}
]
]
},
"uploadImagetoGdrive1": {
"main": [
[
{
"node": "updateVideoURL",
"type": "main",
"index": 0
}
]
]
},
"Call Fal.ai API (WAN2.2)": {
"main": [
[]
]
},
"Structured Output Parser2": {
"ai_outputParser": [
[
{
"node": "Describe Each Scene for Video",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"Call Fal.ai API (nannoBanana)": {
"main": [
[
{
"node": "Get image status",
"type": "main",
"index": 0
}
]
]
},
"Describe Each Scene for Video": {
"main": [
[
{
"node": "Veo3",
"type": "main",
"index": 0
}
]
]
},
"When clicking \u2018Execute workflow\u2019": {
"main": [
[
{
"node": "Get Data",
"type": "main",
"index": 0
}
]
]
},
"CreateImagebyOpernRouter (gemini-2.5-flash-image-preview:free)": {
"main": [
[
{
"node": "wait20sec",
"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.
googleDriveOAuth2ApigoogleSheetsOAuth2ApihttpHeaderAuthopenAiApi
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
⚠️ Note: All sensitive credentials should be set via n8n Credentials or environment variables. Do not hardcode API keys in nodes.
Source: https://n8n.io/workflows/8205/ — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
🎯 Create viral TikToks, Shorts, Reels, podcasts, and ASMR videos in minutes — all on autopilot.
Generate AI viral videos with NanoBanana & VEO3, shared on socials via Blotato 2. Uses @blotato/n8n-nodes-blotato, googleSheets, lmChatOpenAi, toolThink. Event-driven trigger; 94 nodes.
The best content automation template in the market is now even better—with “deep research” on time-sensitive topics\! Unlike most n8n content automation templates that are mainly for “demo purposes,”
Inbox Guardian. Uses gmailTrigger, lmChatOpenAi, agent, textClassifier. Event-driven trigger; 66 nodes.
This template is designed for marketers, content creators, and e-commerce brands who want to automate the creation of professional ad videos at scale. It’s ideal for teams looking to generate consiste