Fully automated YouTube Shorts generation with AI - From text prompt to published video in minutes.
- AI Script Generation - Uses Perplexity AI for engaging, factual scripts
- Text-to-Speech - Google Cloud TTS with natural Neural2 voices
- AI Image Generation - Pollinations.ai (100% FREE, no API key)
- Stock Videos - Pexels integration for B-roll
- Video Rendering - FFmpeg with transitions, captions, and effects
- Auto Upload - Direct YouTube Shorts publishing
- Beautiful Next.js 14 frontend with dark mode
- Real-time video generation progress
- API key management with rate limiting
- Usage analytics and cost tracking
- User authentication (JWT + Sessions)
- Model Context Protocol server for AI agents
- Claude Desktop compatible
- Full API access through natural language
| Service | Cost per Video |
|---|---|
| Perplexity AI | ~$0.02 |
| Google TTS | ~$0.01 |
| Pexels | FREE |
| Pollinations AI | FREE |
| Total | ~$0.03/video |
- Node.js 20+
- pnpm 10.28.0+ (required - npm not supported)
- PostgreSQL 16+
- FFmpeg (for video rendering)
# Install pnpm
npm install -g pnpm
# Install FFmpeg (macOS)
brew install ffmpeg
# Install FFmpeg (Ubuntu)
sudo apt install ffmpeg# Clone the repository
git clone https://github.com/aayushbaluni/Video-Automation-Creation.git
cd Video-Automation-Creation
# Install dependencies
cd backend && pnpm install
cd ../frontend && pnpm install
cd ..
# Configure environment
cp backend/env.template backend/.env
# Edit backend/.env with your API keys
# Setup database
cd backend
pnpm run db:migrate
# Start everything
cd ..
./start-local.shOpens:
- Frontend Dashboard: http://localhost:3000
- Backend API: http://localhost:8000
- API Health: http://localhost:8000/api/v1/health
Copy backend/env.template to backend/.env and configure:
| Variable | Description | Get it from |
|---|---|---|
DATABASE_URL |
PostgreSQL connection | Your PostgreSQL instance |
JWT_SECRET |
Auth secret (32+ chars) | openssl rand -hex 32 |
PERPLEXITY_API_KEY |
Script generation | perplexity.ai |
GOOGLE_CLOUD_TTS_API_KEY |
Text-to-speech | Google Cloud Console |
PEXELS_API_KEY |
Stock videos | pexels.com/api |
| Variable | Description |
|---|---|
YOUTUBE_* |
YouTube upload (OAuth) |
AWS_* |
S3 video storage |
SMTP_* |
Email verification |
HUGGINGFACE_TOKEN |
Additional AI images |
Video-Automation-Creation/
βββ backend/ # Node.js/Express/TypeScript API
β βββ src/
β β βββ api/ # REST API routes
β β βββ mcp/ # MCP server for AI agents
β β βββ pipeline/ # Video generation pipeline
β β βββ services/ # External service integrations
β β βββ db/ # Database migrations
β βββ env.template # Environment template
βββ frontend/ # Next.js 14 React dashboard
β βββ src/
β βββ app/ # App router pages
β βββ components/ # React components
β βββ lib/ # Utilities
βββ documentation/ # Project documentation
βββ start-local.sh # Start all services
βββ stop-local.sh # Stop all services
pnpm run dev:api # Start API server (development)
pnpm run dev:mcp # Start MCP server for Claude
pnpm run db:migrate # Run database migrations
pnpm run db:seed # Seed initial data
pnpm run build # Build for production
pnpm run generate # CLI: Generate videopnpm run dev # Start development server
pnpm run build # Build for production
pnpm run lint # Run linter# Login to get session token
curl -X POST http://localhost:8000/api/v1/auth/login \
-H "Content-Type: application/json" \
-d '{"email": "user@example.com", "password": "your-password"}'# Start video generation
curl -X POST http://localhost:8000/api/v1/pipeline/generate \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"topic": "5 Amazing Facts About Space",
"style": "educational",
"duration": 60
}'curl http://localhost:8000/api/v1/pipeline/jobs/JOB_ID \
-H "Authorization: Bearer YOUR_API_KEY"See API Documentation for full API reference.
Add to your Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json):
{
"mcpServers": {
"video-automation": {
"command": "pnpm",
"args": ["run", "dev:mcp"],
"cwd": "/absolute/path/to/Video-Automation-Creation/backend",
"env": {
"API_KEY": "your-api-key-here"
}
}
}
}Then ask Claude: "Generate a 60-second video about AI trends in 2026"
- β JWT authentication with refresh tokens
- β API key management with scoped permissions
- β Rate limiting per key/IP
- β Email verification
- β Password hashing (bcrypt)
- β CORS configuration
- β Helmet security headers
- β Input validation (Zod schemas)
| Layer | Technology |
|---|---|
| Backend | Node.js 20, TypeScript, Express.js |
| Frontend | Next.js 14, React 18, Tailwind CSS |
| Database | PostgreSQL 16 |
| Video | FFmpeg |
| AI | Perplexity, Google TTS, Pollinations.ai |
| Storage | AWS S3 (optional) |
| Package Manager | pnpm 10.28.0 |
./stop-local.sh && ./start-local.sh# macOS
brew services start postgresql@16
# Or check if running
pg_isready# macOS
brew install ffmpeg
# Ubuntu/Debian
sudo apt install ffmpeg
# Verify
ffmpeg -versionnpm install -g pnpm
# OR
brew install pnpm- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Use
pnpmexclusively (not npm or yarn) - Follow TypeScript strict mode
- Write meaningful commit messages
- Add tests for new features
- Update documentation as needed
This project is licensed under the MIT License - see the LICENSE file for details.
- Perplexity AI - Script generation
- Google Cloud TTS - Text-to-speech
- Pollinations.ai - Free AI image generation
- Pexels - Free stock videos
- FFmpeg - Video processing
| Component | Status |
|---|---|
| Backend API | β Production Ready |
| Frontend Dashboard | β Production Ready |
| MCP Server | β Complete |
| Documentation | β Complete |
| Tests | π§ In Progress |
Ready to generate videos? Run ./start-local.sh and visit http://localhost:3000 π