AI-driven YouTube video generator that creates viral content automatically - from script to upload in minutes. Modern SaaS platform built with Laravel, Vue.js, n8n and Docker, featuring intelligent automation and seamless YouTube integration.
YouTube Video Generator - Free Services Setup Guide
Overview
This YouTube Video Generator SaaS uses completely FREE services to create videos automatically:
- Google Gemini: Free AI script generation (1M tokens/day)
- Pixabay: Free stock videos (5000 requests/hour)
- Unsplash: Free stock images (50 requests/hour for demo)
- gTTS: Free Google Text-to-Speech (unlimited)
- FFmpeg: Free video processing (open source)
Quick Start with Docker
1. Get Free API Keys
Gemini API (Free):
- Visit: https://makersuite.google.com/app/apikey
- Sign in with Google account
- Click "Create API key"
- Copy the key
Pixabay API (Free):
- Visit: https://pixabay.com/api/docs/
- Create account and verify email
- Copy your API key from account settings
Unsplash API (Free for Development):
- Visit: https://unsplash.com/developers
- Create developer account
- Create new app
- Copy Access Key
2. Configure Environment
Create .env file in project root:
# Database
DB_CONNECTION=mysql
DB_HOST=db
DB_PORT=3306
DB_DATABASE=youtube_generator
DB_USERNAME=laravel_user
DB_PASSWORD=secure_password
# Laravel
APP_NAME="YouTube Generator"
APP_ENV=local
APP_KEY=base64:YOUR_APP_KEY_HERE
APP_DEBUG=true
APP_URL=http://localhost:8000
# API Keys (FREE)
GEMINI_API_KEY=your_gemini_api_key_here
PIXABAY_API_KEY=your_pixabay_api_key_here
UNSPLASH_ACCESS_KEY=your_unsplash_access_key_here
# Redis
REDIS_HOST=redis
REDIS_PASSWORD=null
REDIS_PORT=6379
# N8n
N8N_BASIC_AUTH_ACTIVE=true
N8N_BASIC_AUTH_USER=admin
N8N_BASIC_AUTH_PASSWORD=password123
3. Update N8n Workflow Keys
Edit docker/n8n/workflows/video-generation.json and replace:
gemini_api_key: "YOUR_GEMINI_API_KEY"
pixabay_api_key: "YOUR_PIXABAY_API_KEY"
unsplash_access_key: "YOUR_UNSPLASH_ACCESS_KEY"
4. Start the Application
# Build and start all services
docker-compose up --build
# In separate terminal - run database migrations
docker-compose exec app php artisan migrate
# Generate application key
docker-compose exec app php artisan key:generate
5. Access the Application
- Main App: http://localhost:8000
- N8n Workflows: http://localhost:5678 (admin/password123)
How It Works
Free Video Generation Process:
- Script Generation: Gemini AI creates engaging YouTube scripts
- Media Collection: Pixabay provides background videos, Unsplash provides images
- Voice Creation: gTTS converts script to natural speech audio
- Video Assembly: FFmpeg combines media, audio, and effects
- YouTube Upload: Automated upload via Google API
Cost Breakdown (FREE for Development):
- Gemini: 1 million tokens/day free (≈500 video scripts)
- Pixabay: 5000 API requests/hour free (≈200 videos/hour)
- Unsplash: 50 requests/hour free (≈50 image sets/hour)
- gTTS: Unlimited free text-to-speech
- FFmpeg: Open source, completely free
- Hosting: Your own Docker containers
Production Scaling
For production with millions of videos:
- Gemini Pro: $0.50 per 1M tokens (very affordable)
- Pixabay Pro: $9.99/month for unlimited requests
- Unsplash+: $10/month for 10,000 requests
- ElevenLabs: Premium TTS if needed
- Cloud Storage: AWS S3 for video storage
API Endpoints
The Laravel application provides these API endpoints for n8n:
POST /api/videos/{id}/status- Update video generation statusPOST /api/videos/{id}/youtube- Update YouTube upload statusGET /api/autopilot/topics- Get next topic for autopilotPOST /api/autopilot/complete- Mark autopilot video complete
Demo Features
- Demo Login: Skip OAuth setup during development
- Manual Topics: Test video generation with custom topics
- Progress Tracking: Real-time status updates
- Autopilot Mode: Fully automated video creation
Free Service Limits
During development (1 month period):
- Videos per day: ~200-500 depending on complexity
- API costs: $0 (all free tiers)
- Storage: Local Docker volumes (free)
- Bandwidth: Your server only
Perfect for:
- MVP development
- Testing and validation
- Demo presentations
- Small-scale content creation
Troubleshooting
If videos fail to generate:
- Check API keys in n8n workflow
- Verify Python dependencies:
docker-compose exec app pip3 list - Check n8n logs:
docker-compose logs n8n - Test FFmpeg:
docker-compose exec app ffmpeg -version
If workflows don't trigger:
- Import workflows manually in n8n interface
- Activate workflows in n8n
- Check webhook URLs match Laravel routes
Next Steps
- Test demo login and video generation
- Configure your actual API keys
- Import and activate n8n workflows
- Generate your first automated video!
The system is designed to be completely free for development and testing, making it perfect for building your MVP before scaling to production.