AI-friendly full-stack template with authentication, payments, and vector search.
# 1. Clone and setup (instant demo mode)
git clone https://github.com/yourusername/prompt-stack.git
cd prompt-stack
./setup.sh
# 2. Visit your app (already working!)
open http://localhost:3000
# Optional: Using custom ports?
# If ports 3000 or 8000 are busy:
./scripts/check-ports.sh
# See docs/CUSTOM_PORTS.md for detailsThat's it! You have a working app in demo mode.
# Add authentication & database
./setup.sh supabase
# (Auto-restarts Docker, shows migration instructions)
# Add AI providers
./setup.sh ai
# (Auto-restarts Docker, AI is ready!)
# Or configure everything at once
./setup.sh configure
# Check what's configured
./setup.sh statusEach step builds on the previous one. Start simple, add features as needed.
π See the detailed quick start guide for step-by-step instructions.
- π Authentication - Demo auth that works without configuration
- π€ AI Chat - Demo responses to test your UI
- π³ Payments - Test payment flows with mock data
- π Vector Search - In-memory vector operations
- π API Docs - Auto-generated at /docs
- ποΈ Next.js 15 - Latest React framework
- π FastAPI - High-performance Python backend
- ποΈ Supabase - Database, auth, storage, vectors
- π€ Multi-AI - OpenAI, Anthropic, Gemini, DeepSeek
- π° Payments - Stripe & Lemon Squeezy
- π§ Email - Resend integration
- π³ Docker - Development & production ready
βββ frontend/ # Next.js app
βββ backend/ # FastAPI app
βββ supabase/ # Database migrations
βββ scripts/ # Utility scripts
βββ docs/ # Documentation
βββ docker-compose.yml # Local development
No configuration needed! Everything works with mock data.
- Supabase first (required for auth)
- Then AI providers (at least one)
- Optional: Payments, Email
Backend (backend/.env):
# 1οΈβ£ FIRST: Supabase (required!)
SUPABASE_URL=your_url
SUPABASE_ANON_KEY=your_key
SUPABASE_SERVICE_KEY=your_service_key
# 2οΈβ£ SECOND: Add at least one AI provider
DEEPSEEK_API_KEY=your_key # Recommended - $0.14/million tokens!
# Or use: OPENAI_API_KEY, ANTHROPIC_API_KEY, GEMINI_API_KEY
# 3οΈβ£ OPTIONAL: Admin emails (first user is admin by default)
ADMIN_EMAILS=["admin@company.com","rose@company.com"]Frontend (frontend/.env.local):
# Copy from frontend/.env.example
NEXT_PUBLIC_SUPABASE_URL=your_url
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_key
β οΈ IMPORTANT: Environment Variable ChangesAfter changing ANY environment variables, you MUST do a FULL RESTART:
docker-compose down && docker-compose up -dSimple
docker-compose restartis NOT sufficient - environment variables are loaded at container creation time!
make dev # Start everything
make dev-frontend # Frontend only
make dev-backend # Backend only
make test-api # Test API endpoints
make clean # Stop and cleanup
./scripts/diagnose.sh # π Diagnose issues (NEW!)# Quick health check
./scripts/diagnose.sh
# Check detailed system status
curl http://localhost:8000/health/detailed | jq
# View feature configuration
curl http://localhost:8000/health/features | jqcd frontend && vercel --prodrailway up # or use render.yaml# Test API endpoints
./scripts/test-api-simple.sh
# Comprehensive test
./scripts/test-api-comprehensive.sh- Demo First: Start with demo mode, upgrade when ready
- DeepSeek: Most cost-effective AI ($0.14/M tokens)
- Test Keys: Use Stripe test mode for development
- Local Dev: Full stack runs on your machine
- Clean Start: Delete
/app/prompt-stackfolder to remove all demos - Custom Ports: Set
FRONTEND_PORT=3001andBACKEND_PORT=8002in.envfile
- β
Build your app in:
frontend/app/ - β NOT in:
frontend/app/prompt-stack/(demo pages only!) - ποΈ When ready: Delete the entire
prompt-stackfolder
- β Authentication (JWT + Demo auth)
- β User profiles with roles (Admin Setup Guide)
- β LLM chat/completion
- β Vector search
- β File uploads
- β Payment processing
- β Webhooks
These work without any configuration:
POST /api/auth/demo/signin- Demo sign inPOST /api/auth/demo/signup- Demo sign upGET /api/auth/demo/check- Check demo auth availabilityPOST /api/llm/generate-demo- Generate text with demo AIPOST /api/llm/embedding-demo- Create demo embeddingsGET /api/llm/providers- List available AI providersGET /api/payments-demo/stripe/status- Stripe configuration statusGET /api/payments-demo/lemonsqueezy/status- Lemon Squeezy statusGET /api/examples/- Example data endpointsGET /api/dev/health- Comprehensive health check (dev mode)
Core Pages (keep these):
- β
Homepage with service status (
/) - β
Auth pages (
/auth/*)
Demo Pages (in /prompt-stack folder - safe to delete):
- β
Prompt-Stack hub (
/prompt-stack) - β
Developer guide (
/prompt-stack/guide) - β
Form components showcase (
/prompt-stack/guide/forms) - β
LLM demo page (
/prompt-stack/demo) - β
API test page (
/prompt-stack/api-test) - β
Example dashboard (
/prompt-stack/dashboard) - β
Example profile (
/prompt-stack/profile) - β
Example settings (
/prompt-stack/settings)
- β Hot reload
- β Type safety
- β API documentation
- β Error handling
- β Rate limiting
- β GitHub Actions CI/CD
- β Database migrations
- β Test framework ready
Contributions welcome! Please read our contributing guidelines.
MIT License - use this template for anything!
Built for developers who want to ship fast with AI π