Create viral videos from reference images with VIDU & upload to YouTube/TikTok
This workflow automates the process of creating short videos from multiple image references (up to 7 images). It uses "Vidu Reference to Video" model, a video generation API to transform a user-provided prompt and image set into a consistent, AI-generated video.
This workflow automates the process of generating AI-powered videos from a set of reference images and then uploading them to TikTok and Youtube. The process is initiated via a user-friendly web form.
Advantages
- ✅ Consistent Video Creation: Uses multiple reference images to maintain subject consistency across frames.
- ✅ Easy Input: Just a simple form with prompt + image URLs.
- ✅ Automation: No manual waiting—workflow checks status until video is ready.
- ✅ SEO Optimization: Automatically generates a catchy, optimized YouTube title using AI.
- ✅ Multi-Platform Publishing: Uploads directly to Google Drive, YouTube, and TikTok in one flow.
- ✅ Time Saving: Removes repetitive tasks of video generation, download, and manual uploading.
- ✅ Scalable: Can run periodically or on-demand, perfect for content creators and marketing teams.
- ✅ UGC & Social Media Ready: Designed for creating viral short videos optimized for platforms like TikTok and YouTube Shorts.
How It Works
- Form Trigger: A user submits a web form with two key pieces of information: a text
Promptdescribing the desired video and a list ofReference images(URLs separated by commas or new lines). - Data Processing: The workflow processes the submitted image URLs, converting them from a text string into a proper array format for the AI API.
- AI Video Generation: The processed data (prompt and image array) is sent to the Fal.ai VIDU API endpoint (
reference-to-video) to start the video generation job. This node returns arequest_id. - Status Polling: The workflow enters a loop where it periodically checks the status of the generation job using the
request_id. It waits for 60 seconds and then checks if the status is"COMPLETED". If not, it waits and checks again. - Result Retrieval: Once the video is ready, the workflow fetches the URL of the generated video file.
- Title Generation: Simultaneously, the original user prompt is sent to an AI model (GPT-4o-mini via OpenRouter) to generate an optimized, engaging title for the social media post.
- Upload & Distribution:
- The video file is downloaded from the generated URL.
- A copy is saved to a specified Google Drive folder for storage.
- The video, along with the AI-generated title, is automatically uploaded to YouTube and TikTok via the Upload-Post.com API service.
Set Up Steps
This workflow requires configuration and API keys from three external services to function correctly.
Step 1: Configure Fal.ai for Video Generation
- Create an account and obtain your API key.
- In the "Create Video" HTTP node, edit the "Header Auth" credentials.
- Set the following values:
- Name:
Authorization - Value:
Key YOUR_FAL_API_KEY(replaceYOUR_FAL_API_KEYwith your actual key)
- Name:
Step 2: Configure Upload-Post.com for Social Media Uploads
- Get an API key from your Upload-Post Manage Api Keys dashboard (10 free uploads per month).
- In both the "HTTP Request" (YouTube) and "Upload on TikTok" nodes, edit their "Header Auth" credentials.
- Set the following values:
- Name:
Authorization - Value:
Apikey YOUR_UPLOAD_POST_API_KEY(replaceYOUR_UPLOAD_POST_API_KEYwith your actual key)
- Name:
- Crucial: In the body parameters of both upload nodes, find the
userfield and replaceYOUR_USERNAMEwith the exact name of the social media profile you configured on Upload-Post.com (e.g.,my_youtube_channel).
Step 3: Configure Google Drive (Optional Storage)
The "Upload Video" node is pre-configured to save the video to a Google Drive folder named "Fal.run". Ensure your Google Drive credentials in n8n are valid and that you have access to this folder, or change the folderId parameter to your desired destination.
Step 4: Configure AI for Title Generation
The "Generate title" node uses OpenAI to access the gpt-5-mini model..
Need help customizing?
Contact me for consulting and support or add me on Linkedin.
n8n Workflow: Create Viral Videos from Reference Images with VIDU & Upload to YouTube/TikTok
This n8n workflow automates the process of generating a video from a set of reference images using an external API, and then preparing it for upload. While the workflow name suggests uploading to YouTube/TikTok, the provided JSON primarily focuses on the video generation and data manipulation steps, with the upload functionality indicated as a potential next step.
What it does
This workflow orchestrates the following actions:
- Triggers on Form Submission: It starts when a form is submitted, likely containing information or links to reference images for video generation.
- Prepares Data for API Request: It processes the incoming form data, potentially extracting relevant fields to be used in the subsequent API call.
- Initiates Video Generation: It makes an HTTP request to an external API (likely VIDU, based on the directory name) to start the video creation process using the provided reference images.
- Waits for Video Processing: After initiating the video generation, it introduces a delay, allowing the external API time to process and create the video.
- Retrieves Video Status/Details: It then makes another HTTP request to check the status of the video generation or retrieve details about the newly created video.
- Conditional Logic for Video Status: It includes an "If" node to evaluate the response from the video status check. This suggests branching logic based on whether the video generation was successful or requires further action.
- Processes Successful Video Data: If the video generation is successful, it further processes the output, potentially extracting video URLs or other metadata.
- Handles Unsuccessful Video Generation: If the video generation is not successful, it would follow a different path (not fully defined in the provided JSON, but implied by the "If" node).
- Interacts with Google Drive: It includes a Google Drive node, indicating that it might store or retrieve files related to the video generation process (e.g., source images, generated video files, or metadata).
- Executes Custom Code: A "Code" node is present, allowing for custom JavaScript logic to be executed at a specific point in the workflow. This could be used for advanced data manipulation, formatting, or integration with other services not directly supported by n8n nodes.
Prerequisites/Requirements
To use this workflow, you will need:
- n8n Instance: A running instance of n8n.
- External Video Generation API Account: Access to an external API for video generation (e.g., VIDU API key and endpoint).
- Google Drive Account: A Google Drive account with appropriate permissions, and an n8n credential configured for it.
- OpenAI Account: An OpenAI API key and an n8n credential configured for it, as an OpenAI node is present.
Setup/Usage
- Import the Workflow: Download the JSON provided and import it into your n8n instance.
- Configure Credentials:
- Set up credentials for your external video generation API (e.g., an HTTP Basic Auth or API Key credential for the "HTTP Request" nodes).
- Configure your Google Drive OAuth2 credential.
- Configure your OpenAI API Key credential.
- Configure "On form submission" Trigger:
- Activate the "On form submission" node. This will provide you with a webhook URL.
- Integrate this webhook URL into your form submission system (e.g., a website form, another n8n workflow, or a custom application) to send data to this workflow.
- Customize Nodes:
- HTTP Request (Video Generation): Update the URL, HTTP method, headers, and body of the first "HTTP Request" node to match the specifications of your video generation API. Ensure it uses the data from the "On form submission" node.
- Wait: Adjust the duration of the "Wait" node based on the typical processing time of your video generation API.
- HTTP Request (Check Status): Configure the second "HTTP Request" node to query the status or retrieve the generated video details from your API.
- If: Define the conditions in the "If" node to correctly evaluate the API response and branch the workflow based on success or failure.
- Edit Fields (Set): Customize this node to extract and format the necessary data from the API responses.
- Google Drive: Configure the Google Drive node for its intended purpose (e.g., uploading the generated video, storing metadata, or retrieving source images).
- OpenAI: Configure the OpenAI node for its intended purpose, which could involve generating video descriptions, titles, or scripts based on the input.
- Code: Modify the JavaScript in the "Code" node for any custom logic required.
- Extend for Uploads: The current workflow focuses on video generation. To upload to YouTube/TikTok, you would need to add additional nodes (e.g., YouTube node, TikTok node, or further HTTP Request nodes for their respective APIs) after the successful video generation path, using the video URL or file obtained from the video generation API.
- Activate the Workflow: Once configured, activate the workflow to start processing form submissions.
Related Templates
Automate bank statement and invoice reconciliation with GPT and Google Sheets
🟢 Manual Trigger Workflow starts manually to initiate the reconciliation process on demand. 📄 Fetch Invoices & Bank Statements Retrieves invoice data and bank statement data from Google Sheets for comparison. 🔀 Merge Data Combines both datasets into a single structured dataset for processing. 🧩 Format Payload for AI Function node prepares and structures the merged data into a clean JSON payload for AI analysis. 🤖 AI Reconciliation AI Agent analyzes the invoice and bank statement data to identify matches, discrepancies, and reconciled entries. 🧮 Parse AI Output Parses the AI response into a structured format suitable for adding back to Google Sheets. 📊 Update Sheets Adds the reconciled data and reconciliation results into the target Google Sheet for recordkeeping. 🧾 Prerequisites ✅ OpenAI API Credentials Required for the AI Reconciliation node to process and match transactions. Add your OpenAI API key in n8n → Credentials → OpenAI. ✅ Google Sheets Credentials Needed to read invoice and bank statement data and to write reconciled results. Add credentials in n8n → Credentials → Google Sheets. ✅ Google Sheets Setup The connected spreadsheet must contain the following tabs: Invoices – for invoice data Bank_Statement – for bank transaction data Reconciled_Data – for storing the AI-processed reconciliation output ✅ Tab Structure & Required Headers Invoices Sheet Columns: Invoice_ID Invoice_Date Customer_Name Amount Status Bank_Statement Sheet Columns: Transaction_ID Transaction_Date Description Debit/Credit Amount Reconciled_Data Sheet Columns: Invoice_ID Transaction_ID Matched_Status Remarks Confidence_Score ⚙️ n8n Environment Setup Ensure all nodes are connected correctly and the workflow has permission to access the required sheets. Test each fetch and write operation before running the full workflow.
Filter the feedback from Typeform and store in Google Sheets
This workflow allows you to filter positive and negative feedback received from a Typeform and insert the data into Google Sheets. Typeform Trigger node: Start the workflow when a new form is submitted via Typeform Set node: Extract the information submitted in typeform IF node: Filter positive and negative reviews (i.e. ratings above or below 3 out of 5). Google Sheets node: Store the positive and negative reviews and ratings in two different sheets for each case.
Write HTTP query string on image
Receives data from an incoming HTTP Request Reads file from internet Writes data on image Returns the data The URL to call will look like this: http://localhost:5678/webhook-test/webhook/test?name=Jim Once called it will return an image like this: