Global AI Network
Agent Template v1.0

Telegram UGC Product Ad Video Generator

Transform product images into professional UGC video ads instantly. Receive images via Telegram, generate AI scripts with Gemini, and create videos automatically—all in one seamless workflow.

453+
Deployments
10m
Setup Time
Free
Pricing

Need custom configuration?

Our solution engineers can help you adapt this agent to your specific infrastructure and requirements.

Enterprise Grade Best Practices Production Optimized

INTEGRATED_MODULES

Google Gemini
Google Gemini
Google Veo 3
Google Veo 3
Telegram
Telegram
Step by Step

Setup Tutorial

mission-briefing.md

TaskAGI UGC Video Generation Workflow Setup Guide

What This Agent Does

This powerful workflow automates the creation of User-Generated Content (UGC) product advertisement videos directly from product images shared via Telegram. Simply send a product photo to your bot, and the system intelligently analyzes the product, generates a professional ad script, creates a polished video, and delivers it back to you—all without manual intervention.

Key benefits and time savings:

  • 90% faster content creation: Transform product images into finished videos in minutes instead of hours
  • Professional quality: Leverages AI-powered script writing and video generation for consistent, engaging ads
  • Seamless workflow: Integrated Telegram interface means no context switching between platforms
  • Scalable production: Process unlimited product images with consistent quality and branding
  • Cost-effective: Automate repetitive creative tasks and reduce dependency on freelance creators

Target use cases:

  • E-commerce businesses needing rapid product video ads
  • Social media marketers managing multiple product launches
  • Dropshipping operations requiring bulk UGC content
  • Digital agencies producing ads for multiple clients
  • Content creators building video libraries for TikTok, Instagram Reels, and YouTube Shorts

Who Is It For

This workflow is ideal for:

  • E-commerce entrepreneurs who need to produce high-volume product ads quickly
  • Marketing teams managing campaigns across multiple platforms and products
  • Digital agencies delivering UGC content to clients at scale
  • Social media managers constantly needing fresh video content
  • Dropshippers launching new products weekly and needing promotional videos
  • Content creators looking to automate repetitive production tasks

No video editing experience required—the AI handles all creative and technical aspects.


Required Integrations

Telegram

Why it's needed: Telegram serves as your primary interface for this workflow. It receives product images from users, triggers the entire automation pipeline, and delivers the finished videos back. This creates a seamless, user-friendly experience where creators simply upload images and receive videos.

Setup steps:

  1. Create a Telegram Bot

    • Open Telegram and search for @BotFather
    • Send the command /newbot
    • Follow the prompts to name your bot (e.g., "UGC Video Generator")
    • Copy the API token provided (format: 123456789:ABCdefGHIjklmnoPQRstuvWXYZabcdefgh)
  2. Obtain Your Bot Token

    • Save the token in a secure location
    • This is your primary credential for Telegram integration
  3. Set Up Webhook in TaskAGI

    • In TaskAGI, navigate to IntegrationsTelegram
    • Select Add New Integration
    • Paste your bot token in the API Token field
    • Click Authenticate
    • TaskAGI will generate a webhook URL
  4. Configure Webhook in BotFather

    • Return to @BotFather in Telegram
    • Send /setwebhook
    • Provide the webhook URL from TaskAGI
    • Confirm the webhook is active
  5. Test the Connection

    • Send a test message to your bot
    • Verify it appears in TaskAGI's activity logs

How to obtain API keys/credentials:

  • Bot tokens are generated automatically by BotFather
  • Keep your token confidential—treat it like a password
  • You can regenerate tokens anytime via BotFather if compromised

Configuration in TaskAGI:

  • Store the token in your Secrets Manager for security
  • Reference it as {{secrets.telegram_token}} in node configurations
  • Enable message logging for debugging

Google Gemini

Why it's needed: Google Gemini's advanced vision AI analyzes product images and generates compelling, professional UGC ad scripts. It understands product features, benefits, and emotional appeals—creating scripts optimized for conversion.

Setup steps:

  1. Access Google Cloud Console

    • Visit console.cloud.google.com
    • Sign in with your Google account
    • Create a new project (name it "TaskAGI UGC Generator")
  2. Enable the Gemini API

    • In the Cloud Console, go to APIs & ServicesLibrary
    • Search for "Generative Language API"
    • Click the result and select Enable
    • Wait for activation (usually instant)
  3. Create an API Key

    • Navigate to APIs & ServicesCredentials
    • Click Create CredentialsAPI Key
    • Copy the generated key (format: AIzaSy...)
    • Restrict the key to Generative Language API only for security
  4. Configure in TaskAGI

    • Go to IntegrationsGoogle Gemini
    • Select Add New Integration
    • Paste your API key
    • Click Test Connection
    • Verify success message appears
  5. Set Model Parameters

    • Model: gemini-2.5-flash (optimized for speed and quality)
    • Temperature: 0.7 (balanced creativity and consistency)
    • Max tokens: 1500 (sufficient for detailed scripts)

How to obtain API keys/credentials:

  • API keys are generated in Google Cloud Console
  • Free tier includes generous monthly quotas
  • Monitor usage in APIs & ServicesQuotas

Configuration in TaskAGI:

  • Store API key in Secrets Manager as {{secrets.gemini_api_key}}
  • Set up billing alerts to avoid unexpected charges
  • Test with sample images before production use

Google Veo 3

Why it's needed: Google Veo 3 is a cutting-edge video generation AI that transforms scripts into polished, professional UGC-style videos. It handles cinematography, pacing, transitions, and visual effects—producing broadcast-quality content automatically.

Setup steps:

  1. Access Google AI Studio

  2. Generate Veo 3 API Key

    • Click Create API Key
    • Select Google Veo 3 from available APIs
    • Copy the generated key
    • Note: Veo 3 may require waitlist access—check availability in your region
  3. Set Up Billing

    • Veo 3 video generation incurs costs per video
    • Configure billing in Google Cloud Console
    • Set monthly budget limits to control expenses
    • Typical cost: $0.10-0.50 per video depending on length/quality
  4. Configure in TaskAGI

    • Go to IntegrationsGoogle Veo 3
    • Select Add New Integration
    • Paste your API key
    • Set video parameters:
      • Duration: 15-30 seconds (optimal for social media)
      • Resolution: 1080p (standard for TikTok/Instagram)
      • Frame rate: 24fps (cinematic quality)
  5. Test Video Generation

    • Use a sample script to generate a test video
    • Verify output quality and duration
    • Check that videos download successfully

How to obtain API keys/credentials:

  • Keys generated through Google AI Studio
  • Veo 3 may have limited availability—join waitlist if needed
  • Consider alternative video APIs if Veo 3 unavailable in your region

Configuration in TaskAGI:

  • Store API key as {{secrets.veo3_api_key}}
  • Set up cost monitoring to track video generation expenses
  • Configure fallback options if API rate limits are exceeded

Configuration Steps

Node-by-Node Configuration Guidance

Node 1: Workflow Overview (core.workflow_note)

  • Purpose: Documentation node explaining the workflow
  • Configuration: Add a descriptive note:
    UGC Video Generation Workflow
    Converts product images → AI scripts → Professional videos
    Triggered via Telegram, delivered back to user
    
  • No parameters to configure—informational only

Node 2: Receive Product Image (telegram.webhook)

  • Purpose: Listens for incoming product images from Telegram users
  • Configuration:
    • Trigger type: message_with_photo
    • Bot token: {{secrets.telegram_token}}
    • Expected input: Photo file from Telegram
  • Data output: Image file ID, user ID, caption (if provided)
  • Example: User sends product photo with caption "Blue wireless headphones"

Node 3: Extract Image & Caption (core.edit_data)

  • Purpose: Parses incoming Telegram data and prepares it for processing
  • Configuration:
    • Input data: Raw Telegram webhook payload
    • Extract fields:
      • photo_id → Store as {{photo_id}}
      • caption → Store as {{product_caption}}
      • user_id → Store as {{user_id}}
    • Transformation: Convert photo ID to downloadable format
  • Example output:
    {
      "photo_id": "AgADAgADr6cxG...",
      "product_caption": "Blue wireless headphones",
      "user_id": "123456789"
    }
    

Node 4: Download Telegram Image (telegram.getFile)

  • Purpose: Downloads the actual image file from Telegram servers
  • Configuration:
    • File ID: {{photo_id}} (from Node 3)
    • Bot token: {{secrets.telegram_token}}
    • Output format: Binary image file
    • Storage: Temporary cache (auto-deleted after workflow completion)
  • Parameter: file_path will be generated automatically

Node 5: Analyze Product & Generate Script (googlegemini.analyzeImage)

  • Purpose: AI analyzes the product image and writes a compelling UGC ad script
  • Configuration:
    • API key: {{secrets.gemini_api_key}}
    • Model: gemini-2.5-flash
    • Input image: {{downloaded_image}} (from Node 4)
    • System prompt:
      You are a professional UGC ad scriptwriter specializing in 
      high-converting product advertisements. Analyze the product 
      image and create a 30-second script that:
      - Opens with a relatable problem
      - Showcases product benefits naturally
      - Includes a clear call-to-action
      - Uses conversational, authentic language
      - Targets social media audiences (TikTok/Instagram style)
      
    • Temperature: 0.7 (balanced creativity)
    • Max tokens: 1500
  • Example output:
    "You know that frustrating moment when your headphones 
    keep falling out during workouts? These wireless headphones 
    have this incredible secure-fit design... [continues for 30 seconds]"
    

Node 6: Generate UGC Video (googleveo3.generateVideo)

  • Purpose: Creates a professional video from the AI-generated script
  • Configuration:
    • API key: {{secrets.veo3_api_key}}
    • Input script: {{generated_script}} (from Node 5)
    • Input image: {{downloaded_image}} (from Node 4)
    • System prompt:
      Create a UGC-style product advertisement video for social media.
      - Duration: 15-30 seconds
      - Style: Authentic, relatable, high-energy
      - Include product shots, lifestyle imagery, and text overlays
      - Optimize for TikTok/Instagram Reels (9:16 aspect ratio)
      - Add trending background music and sound effects
      
    • Video parameters:
      • Duration: 30 seconds
      • Resolution: 1080x1920 (mobile-optimized)
      • Frame rate: 24 fps
      • Aspect ratio: 9:16 (vertical for social media)
  • Processing time: 2-5 minutes per video
  • Output: MP4 video file

Node 7: Send Video to User (telegram.sendVideo)

  • Purpose: Delivers the finished video back to the user via Telegram
  • Configuration:
    • Bot token: {{secrets.telegram_token}}
    • Chat ID: {{user_id}} (from Node 3)
    • Video file: {{generated_video}} (from Node 6)
    • Caption:
      ✨ Your UGC video is ready!
      
      Product: {{product_caption}}
      Generated with AI
      Ready to post on TikTok, Instagram, YouTube Shorts
      
    • Parse mode: HTML (for formatted text)
  • Notification: User receives video instantly in Telegram

Nodes 8-9: Documentation Notes

  • AI Script Generation and Video Generation: Informational nodes documenting each stage
  • No configuration needed—reference only

Data Flow Between Nodes

The workflow follows this sequential data pipeline:

Telegram Image (Node 2)
    ↓
Extract metadata (Node 3)
    ↓
Download image file (Node 4)
    ↓
Analyze + Generate script (Node 5)
    ↓
Create video (Node 6)
    ↓
Send to user (Node 7)

Key data transformations:

  • Node 2→3: Raw webhook → Structured data
  • Node 3→4: Photo ID → Binary image file
  • Node 4→5: Image file → Text script
  • Node 5→6: Script + image → Video file
  • Node 6→7: Video file → Telegram message

Testing Your Agent

Step 1: Pre-Launch Verification

Before running your first workflow:

  1. Verify all integrations are connected

    • Go to Integrations dashboard
    • Confirm green checkmarks next to Telegram, Gemini, and Veo 3
    • Test each connection individually
  2. Check API quotas and billing

    • Verify Gemini API has available quota
    • Confirm Veo 3 billing is active and funded
    • Set up cost alerts for Veo 3 usage
  3. Validate webhook configuration

    • Send a test message to your Telegram bot
    • Verify it appears in TaskAGI activity logs
    • Confirm webhook URL is active

Step 2: Execute Test Workflow

  1. Prepare a test product image

    • Use a clear, well-lit product photo
    • Include product in frame with context
    • Recommended: 1080x1080px or larger
  2. Send test image to your bot

    • Open Telegram and find your bot
    • Send the product image with caption: "Test product: Blue wireless headphones"
    • Note the timestamp
  3. Monitor workflow execution

    • In TaskAGI, go to WorkflowsExecutions
    • Find your test execution
    • Watch real-time progress through each node

Step 3: Verify Each Processing Stage

At Node 2 (Receive Image):

  • ✅ Image received and logged
  • ✅ User ID captured correctly
  • ✅ Caption extracted (if provided)

At Node 3 (Extract Data):

  • ✅ Photo ID extracted
  • ✅ Metadata properly formatted
  • ✅ No data loss or corruption

At Node 4 (Download Image):

  • ✅ Image file successfully downloaded
  • ✅ File size reasonable (typically 100KB-5MB)
  • ✅ No timeout errors

At Node 5 (Generate Script):

  • ✅ Gemini API responds within 30 seconds
  • ✅ Script generated (typically 200-400 words)
  • ✅ Script is coherent and product-focused
  • ✅ No API errors or quota exceeded messages

At Node 6 (Generate Video):

  • ✅ Veo 3 API accepts request
  • ✅ Video generation starts (processing time: 2-5 minutes)
  • ✅ Video file created (typically 5
Similar Solutions

Related Agents

Explore these powerful automation agents that complement your workflow.

Telegram Expense Tracker AI Agent

Telegram Expense Tracker AI Agent

Automate expense tracking via Telegram with AI-powered voice transcription, OCR receipt scanning, and intelligent expens...

Telegram News Article RAG Chat Bot

Telegram News Article RAG Chat Bot

Automate news analysis and intelligent Q&A with Pinecone vector search—instantly summarize articles from Telegram links...

Telegram UGC Video Generator

Telegram UGC Video Generator

Transform product images into viral UGC videos instantly—from Telegram to social platforms with AI-powered scripts and a...