Complete setup instructions for getting DraftDeckAI running locally on your machine.
Before you start, make sure you have:
- Node.js 18.0.0 or higher (download here)
- npm 9.0.0 or higher (comes with Node.js)
- Git (download here)
- Code Editor (VS Code recommended)
node --version # Should be v18.0.0 or higher
npm --version # Should be 9.0.0 or higher
git --version # Any recent version# Clone your forked repository
git clone https://github.com/YOUR_USERNAME/DraftDeckAI.git
cd DraftDeckAI
# Add upstream remote to sync with main repo
git remote add upstream https://github.com/Muneerali199/DraftDeckAI.gitnpm install
# If you encounter issues:
npm cache clean --force
rm -rf node_modules package-lock.json
npm installCreate a new file named .env.local in the root directory (same level as package.json):
touch .env.local # On macOS/Linux
# or manually create .env.local in your editor# ============================================
# 🎯 REQUIRED - App won't start without these
# ============================================
# Supabase Database & Authentication
NEXT_PUBLIC_SUPABASE_URL=your_supabase_url_here
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_anon_key_here
SUPABASE_SERVICE_ROLE_KEY=your_supabase_service_role_key
# ============================================
# 🤖 REQUIRED - For AI Features (pick at least one)
# ============================================
# Google Gemini (Recommended - easiest to set up)
GEMINI_API_KEY=your_gemini_api_key_here
# Alternative: Mistral AI (Optional)
# MISTRAL_API_KEY=your_mistral_api_key_here
# Alternative: Qwen (Optional)
# QWEN_API_KEY=your_qwen_api_key_here
# ============================================
# 💳 OPTIONAL - Stripe Payments (for testing)
# ============================================
NEXT_PUBLIC_ENABLE_STRIPE=false
# NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY=pk_test_xxxxx
# STRIPE_SECRET_KEY=sk_test_xxxxx
# STRIPE_WEBHOOK_SECRET=whsec_xxxxx
# STRIPE_PRICE_ID=price_xxxxx
# ============================================
# 🖼️ OPTIONAL - Image APIs
# ============================================
# UNSPLASH_ACCESS_KEY=your_unsplash_key_here
# PEXELS_API_KEY=your_pexels_key_here
# ============================================
# 🌐 App Configuration
# ============================================
NEXT_PUBLIC_APP_NAME=DraftDeckAI
NEXT_PUBLIC_APP_URL=http://localhost:3000Time: 5 minutes
- Go to supabase.com
- Click "Sign Up" and create an account
- Click "New Project" button
- Fill in project name:
draftdeckai-dev - Set password for database
- Click "Create new project"
- Wait for project to initialize (2-3 minutes)
- Go to Settings → API
- Copy these three keys into
.env.local:Project URL→NEXT_PUBLIC_SUPABASE_URLanon public→NEXT_PUBLIC_SUPABASE_ANON_KEYservice_role secret→SUPABASE_SERVICE_ROLE_KEY
✅ Done! Supabase is ready.
Time: 5 minutes
- Go to ai.google.dev
- Click "Get API Key" (free tier available)
- Click "Create API Key"
- Choose "Create API key in new project"
- Copy the generated key
- Paste into
.env.localasGEMINI_API_KEY
✅ Free tier includes:
- 60 requests per minute
- 1,500 requests per day
- Perfect for local development
Time: 5 minutes | ⏭️ Skip for now
To test payment functionality later:
- Go to stripe.com
- Click "Start now" → Create account
- Skip onboarding (can be done later)
- Go to Developers → API Keys (left sidebar)
- Copy the Publishable Key and Secret Key
- In
.env.local, setNEXT_PUBLIC_ENABLE_STRIPE=trueand add the keys
false)
Choose one or both:
Unsplash (Recommended)
- Go to unsplash.com/developers
- Create account → Create application
- Copy Access Key → Add to
.env.local
Pexels
- Go to pexels.com/api/
- Signup → Create API key
- Copy key → Add to
.env.local
Run this command to check if everything is configured:
npm run build
# Expected output:
# ✓ Build successful
# ✓ No errorsIf you see errors about missing environment variables, you missed a required API key. Check Step 3 again.
npm run devYou should see output like:
> draftdeckai@2.0.0 dev
> next dev
▲ Next.js 14.2.0
- Local: http://localhost:3000
- Environments: .env.local
✓ Ready in 3.2s
Open your browser and go to:
http://localhost:3000
You should see the DraftDeckAI homepage! 🎉
- Go to Dashboard → New Resume
- Describe your experience
- Watch AI generate a professional resume ✨
- Go to Dashboard → New Presentation
- Enter a topic (e.g., "Climate Change")
- Watch AI create slides 🎯
- Go to Dashboard → New Diagram
- Choose a diagram type
- Add your content
- Export as PNG/SVG 📊
- Go to Dashboard → New Letter
- Paste a job URL (e.g., LinkedIn job posting)
- AI tailors a cover letter ✉️
npm test # Run all tests
npm run test:watch # Watch mode (re-runs on file changes)npm run lint # Check linting errors
npm run lint:fix # Auto-fix linting errors
npm run build # Check for build errors# Generate TypeScript types from database
npm run supabase:generate-typesnpm outdated # Show outdated packages
npm update # Update packagesSolution:
npm install
# Still failing?
rm -rf node_modules package-lock.json
npm installSolution:
- Check
.env.localexists in root directory - Check variable name is exactly
GEMINI_API_KEY - Check value is not empty
- Restart dev server:
npm run dev
# Verify on macOS/Linux
cat .env.local | grep GEMINI
# Verify on Windows (PowerShell)
Get-Content .env.local | Select-String "GEMINI"Solution:
# Kill process using port 3000
# macOS/Linux:
lsof -ti :3000 | xargs kill -9
# Windows PowerShell:
Get-Process -Id (Get-NetTCPConnection -LocalPort 3000).OwningProcess | Stop-Process -Force
# Or use different port:
npm run dev -- -p 3001Solution:
- Check
NEXT_PUBLIC_SUPABASE_URLis not empty - Verify URL format:
https://xxxxx.supabase.co - Check
NEXT_PUBLIC_SUPABASE_ANON_KEYexists - Restart dev server
Solution:
# Check TypeScript errors
npm run build
# Read the specific error message
# Fix the file mentioned
# Re-run buildgit config --global user.name "Your Name"
git config --global user.email "your.email@example.com"git checkout -b feature/your-feature-name
# Example: git checkout -b feature/add-new-resume-templategit add .
git commit -m "feat: add new resume template"
# Use conventional commits: feat, fix, docs, style, refactor, test, choregit push origin feature/your-feature-name- Go to GitHub
- You should see a "Compare & pull request" button
- Click it and fill in the description
- Next.js Documentation: https://nextjs.org/docs
- React Documentation: https://react.dev
- TypeScript Documentation: https://www.typescriptlang.org/docs/
- Supabase Documentation: https://supabase.com/docs
- Tailwind CSS Documentation: https://tailwindcss.com/docs
- shadcn/ui Documentation: https://ui.shadcn.com
✅ Always sync with upstream before starting new work:
git fetch upstream
git rebase upstream/main✅ One feature per branch - Don't mix multiple features
✅ Test locally before pushing:
npm run lint && npm test && npm run build✅ Keep .env.local secret - Never commit it!
✅ Read related files before making changes
✅ Ask questions if anything is unclear
- 💬 Comment on GitHub issues - Ask for clarification
- 📖 Check CONTRIBUTING.md - General contribution guidelines
- 🗣️ Discord community - Ask mentors and contributors
- 🔗 LinkedIn - Connect with project maintainers
You now have a fully functional DraftDeckAI development environment.
Next steps:
- Explore the codebase (
app/,components/,lib/) - Read CONTRIBUTING.md for contribution guidelines
- Check GitHub Issues for tasks to work on
- Make your first contribution! 🚀
Happy coding! 🎉
Last Updated: May 2026 Maintained by: DraftDeckAI Community