npm installCopy .env.example to .env.local:
cp .env.example .env.localThen update .env.local with your actual credentials:
A. Database (PostgreSQL)
- Option 1: Use Neon (Free PostgreSQL)
- Option 2: Use Supabase (Free PostgreSQL)
- Option 3: Local PostgreSQL
# Install PostgreSQL locally # Create a database named 'unipath' # Update DATABASE_URL in .env.local
B. Clerk Authentication (Required)
- Go to Clerk Dashboard
- Create a new application
- Copy your publishable and secret keys
- Update in
.env.local:NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=pk_test_... CLERK_SECRET_KEY=sk_test_...
C. Google Gemini API (Required for AI features)
- Go to Google AI Studio
- Create an API key
- Update in
.env.local:GEMINI_API_KEY=your_key_here
D. Inngest (Optional - for background jobs)
- Go to Inngest
- Sign up and get your keys
- Update in
.env.local
Run Prisma migrations:
npx prisma generate
npx prisma db pushnpm run devThe app will be available at http://localhost:3000
If you just want to test the UI without database:
- Install dependencies:
npm install - Get Clerk keys (free): https://dashboard.clerk.com
- Update
.env.localwith Clerk keys - Comment out database calls in the code (temporary)
- Run:
npm run dev
- Go to https://neon.tech
- Sign up for free
- Create a new project
- Copy the connection string
- Paste in
.env.localasDATABASE_URL
- Go to https://supabase.com
- Create a new project
- Go to Project Settings > Database
- Copy the connection string (set mode to "Session")
- Paste in
.env.localasDATABASE_URL
# Install PostgreSQL
# Windows: https://www.postgresql.org/download/windows/
# Mac: brew install postgresql
# Create database
createdb unipath
# Update .env.local
DATABASE_URL="postgresql://postgres:your_password@localhost:5432/unipath"- Verify your
DATABASE_URLis correct - Make sure your database is running
- Run:
npx prisma db push
- Check your Clerk keys are correct
- Make sure you're using the right environment keys (test vs production)
- Visit the Clerk claim URL if in keyless mode
The app will automatically use the next available port (e.g., 3001)
rm -rf node_modules package-lock.json
npm installFor deploying to production:
- Set up production database (Neon, Supabase, etc.)
- Update environment variables on your hosting platform
- Run build:
npm run build npm start
For issues or questions:
- Check the documentation
- Open an issue on GitHub
- Contact the UniPath team
Happy coding! 🚀