Get a quick overview of OpenBlogAI's capabilities through these demonstration videos:
See how easy it is to create AI-powered blogs from YouTube videos
Explore the modern, responsive design and public blog browsing
Discover user profiles, admin controls, and platform statistics
OpenBlogAI is a full-stack blog generation platform that leverages artificial intelligence to automatically convert YouTube videos into comprehensive, SEO-optimized blog posts. Built with modern web technologies and multiple AI providers for maximum flexibility and performance.
After months of being away due to university commitments, I'm excited to announce the V1 Beta release of OpenBlogAI! This project represents a significant milestone in making AI-powered content creation accessible to everyone.
- Complete Role-Based Access Control (RBAC): Comprehensive user management system with multiple permission levels
- Advanced Content Moderation: Built-in moderation tools for community-driven content
- OpenRouter Integration: Access to dozens of AI models for free and premium tiers
- Enhanced User Experience: Completely redesigned interface with modern, responsive design
- Production-Ready Architecture: Scalable backend with Redis caching and security hardening
- π€ Regular Users: Create and manage personal blogs, basic AI model access
- β Verified Posters: Enhanced privileges, access to premium AI models, public blog publishing
- π‘οΈ Moderators: Content moderation tools, user management, community oversight
- π Administrators: Full system access, user role management, platform configuration
Thanks to OpenRouter integration, users can access a vast array of AI models:
- Free Tier Models: Mistral 7B, Llama variants, and other open-source models
- Premium Models: GPT-4, Claude, Gemini Pro, and cutting-edge AI systems
- Specialized Models: Code-focused, creative writing, and domain-specific AI models
- Cost-Effective: Pay-per-use pricing with transparent costs and usage tracking
- YouTube to Blog Conversion: Extract transcripts from YouTube videos and generate high-quality blog posts
- Multi-AI Provider Support: Access 40+ AI models via OpenRouter, including free and premium options
- Real-time Processing: Generate blogs in under 60 seconds with live progress tracking
- Advanced SEO Optimization: Built-in SEO scoring, structured data, and optimization recommendations
- Role-Based Access Control: Comprehensive user management with Admin, Moderator, and Verified Poster roles
- Content Moderation System: Built-in tools for community content oversight and quality control
- Responsive Design: Mobile-first design with comprehensive breakpoint system
- Interactive UI: Smooth animations with Framer Motion and modern design patterns
- Progressive Enhancement: Works offline with intelligent caching strategies
- Type Safety: Full TypeScript implementation across the stack
- Redis Caching: Intelligent caching with stampede prevention for public content
- Database Optimization: Prisma ORM with MySQL for efficient data management
- Smart Pagination: Server-side pagination with search and filtering
- Rate Limiting: Built-in API protection against abuse
- Dual Authentication System: NextAuth 5 (client) + JWT tokens (server)
- Role-based Access Control: Admin, moderator, and verified poster roles
- CSRF Protection: Built-in security against cross-site request forgery
- Token Management: Automatic refresh token rotation and security
Frontend (openblogaiclient/)
- Framework: Next.js 15 with App Router
- Styling: TailwindCSS 4 + DaisyUI components
- Animations: Framer Motion for smooth interactions
- Authentication: NextAuth 5 (beta) with credentials provider
- State Management: React hooks with server state synchronization
- Type Safety: TypeScript with strict configuration
Backend (server/)
- Runtime: Node.js with Express.js
- Database: MySQL with Prisma ORM
- Caching: Redis with ioredis client
- Authentication: JWT with refresh token rotation
- Security: Helmet, CORS, rate limiting, CSRF protection
- Logging: Winston with structured logging
- Validation: Zod schemas for type-safe validation
AI Integrations
- OpenRouter: Universal AI gateway with access to 40+ models (free and premium)
- OpenAI: GPT models via @ai-sdk/openai
- Azure AI: Azure AI services integration
- Hugging Face: Open-source models via @huggingface/inference
- YouTube Processing: Multiple transcript extraction methods
- Authentication: User logs in β NextAuth session β JWT token exchange
- Content Creation: YouTube URL β Transcript extraction β AI processing β Blog generation
- Caching: Public blogs cached in Redis with intelligent invalidation
- SEO Processing: Generated content β SEO analysis β Structured data β Search optimization
- Node.js 18+ and npm/yarn
- MySQL database
- Redis server (optional but recommended)
- API keys for AI providers (optional)
- Clone the repository
git clone https://github.com/xloyb/OpenBlogAI.git
cd OpenBlogAI- Install dependencies
# Install server dependencies
cd server
npm install
# Install client dependencies
cd ../openblogaiclient
npm install- Environment Setup
Server (.env)
# Database
DATABASE_URL="mysql://username:password@localhost:3306/openblogai"
# JWT Secrets
JWT_SECRET="your-super-secret-jwt-key-here"
REFRESH_SECRET="your-super-secret-refresh-key-here"
REFRESH_TOKEN_EXPIRES_IN="7d"
# Server Configuration
PORT=8082
BCRYPT_SALT_ROUNDS=10
# Redis (optional)
REDIS_HOST="127.0.0.1"
REDIS_PORT=6379
REDIS_PASSWORD="" # Optional
# AI Providers (optional)
OPENROUTER_API_KEY="your-openrouter-key" # Access to 40+ AI models
HUGGING_FACE_API_TOKEN="your-hf-token"
GITHUB_API="your-github-token" # For additional integrationsClient (.env.local)
# Authentication
NEXTAUTH_SECRET="your-nextauth-secret-here"
NEXTAUTH_URL="http://localhost:3000"
# Server Connection
NEXT_PUBLIC_SERVER_URL="http://localhost:8082"- Database Setup
cd server
npx prisma generate
npx prisma db push- Start Development Servers
# Terminal 1: Start the server (port 8082)
cd server
npm run dev
# Terminal 2: Start the client (port 3000)
cd openblogaiclient
npm run devVisit http://localhost:3000 to access the application!
POST /api/auth/register- User registrationPOST /api/auth/login- User loginPOST /api/auth/refresh- Refresh access tokenPOST /api/auth/logout- User logout
GET /api/blog/public/blogs- Public blogs with pagination/searchGET /api/blog/user/blogs- User's private blogsPOST /api/blog/create- Create new blogPUT /api/blog/:id- Update blogDELETE /api/blog/:id- Delete blog
POST /api/transcript/extract- Extract YouTube transcriptGET /api/transcript/:videoId- Get video transcriptPOST /api/video/upload- Register new video
OpenBlogAI/
βββ openblogaiclient/ # Next.js frontend
β βββ src/app/ # App Router pages
β βββ components/ # Reusable components
β βββ lib/ # Client utilities
β βββ auth/ # Authentication config
β βββ types/ # TypeScript definitions
βββ server/ # Express.js backend
β βββ src/
β β βββ controllers/ # Route handlers
β β βββ services/ # Business logic
β β βββ middlewares/ # Express middlewares
β β βββ routes/ # API routes
β β βββ utils/ # Shared utilities
β βββ prisma/ # Database schema
βββ docs/ # Documentation
Server
- Path Aliases: Clean imports with
@src/,@routes/, etc. - Type Safety: Zod validation for all API inputs
- Error Handling: Centralized error middleware
- Logging: Structured logging with Winston
- Hot Reload: Nodemon for development
Client
- App Router: Next.js 15 with server components
- Type Safety: TypeScript with strict configuration
- Modern CSS: TailwindCSS 4 with utility-first approach
- Component Library: DaisyUI for consistent design
- Performance: Automatic code splitting and optimization
Server
npm run dev # Development with hot reload
npm run build # TypeScript compilation
npm start # Production serverClient
npm run dev # Development with Turbopack
npm run build # Production build
npm start # Production server
npm run lint # ESLint checking# Build server
cd server
npm run build
npm start
# Build client
cd openblogaiclient
npm run build
npm start# Install PM2 globally
npm install -g pm2
# Start with PM2
pm2 start ecosystem.config.js- Set
NODE_ENV=production - Configure proper database URLs
- Set strong JWT secrets
- Configure Redis for production
- Set proper CORS origins
The application uses Redis for intelligent caching:
- Public blogs: Cached with automatic invalidation
- Stampede prevention: Prevents duplicate API calls
- Graceful fallback: Works without Redis (performance impact)
Multiple AI providers supported:
- OpenAI: Premium models with high quality
- Azure AI: Enterprise-grade AI services
- Hugging Face: Open-source models (free tier available)
Key models:
- User: Authentication, roles, permissions
- Blog: Content, SEO data, visibility settings
- Video: YouTube video metadata
- Transcript: Extracted video transcripts
- RefreshToken: Secure token management
- Fork the repository
- Create feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Follow TypeScript strict mode
- Use Prettier for code formatting
- Write descriptive commit messages
- Add tests for new features
- Update documentation as needed
This project is open source and available under the MIT License.


