A modern, full-stack mentorship platform built specifically for healthcare professionals, connecting nursing students and preceptors with AI-powered matching, real-time communication, and comprehensive clinical placement management.
Built with Next.js 15, Supabase PostgreSQL, Clerk authentication, AI-enhanced matching (OpenAI/Gemini), and comprehensive healthcare compliance features.
Production: sandboxmentoloop.online
Deployed via GitHub → Netlify. Preview environment available. Documentation lives in docs/ within this repo.
- 🏥 AI-Powered Matching - MentorFit™ algorithm with OpenAI/Gemini enhancement for optimal student-preceptor pairing
- 👩🎓 Student Management - Complete intake workflow with MentorFit assessment and rotation tracking
- 👨⚕️ Preceptor Management - Credential verification, availability management, and student evaluation tools
- 💬 HIPAA-Compliant Messaging - Secure real-time communication with file attachments
- 📧 Automated Communications - SendGrid email templates and Twilio SMS for notifications
- 📊 Clinical Hours Tracking - Comprehensive logging, approval workflow, and progress analytics
- 🔄 Real-time Updates - Live match status, messages, and progress sync across all devices
- 📋 Survey & Evaluation System - Post-rotation feedback and quality improvement tracking
- 🏛️ Enterprise Support - Multi-school management with role-based access control
- 🚀 Next.js 15 with App Router - Latest React framework with server components
- ⚡️ Turbopack - Ultra-fast development with hot module replacement
- 🎨 TailwindCSS v4 - Modern utility-first CSS with custom design system
- 🔐 Clerk Authentication - Complete user management with role-based access
- 🗄️ Convex Real-time Database - Serverless backend with real-time sync
- 🧠 AI Integration - OpenAI and Google Gemini for MentorFit™ and documentation assistance
- 📞 Third-party Integrations - SendGrid, Twilio, Stripe for communications and payments
- 🧾 Payments Reliability - Stripe idempotency on all writes and webhook de-duplication via Convex
webhookEvents - 🧪 Comprehensive Testing - Vitest unit tests, Playwright E2E tests, integration testing
- 🛡️ Security & Compliance - HIPAA/FERPA compliant with audit logging
- 📱 Responsive Design - Mobile-first approach with PWA capabilities
- 🚢 Production Ready - Full deployment infrastructure and monitoring
- Next.js 15 - React framework with App Router
- TailwindCSS v4 - Utility-first CSS framework
- shadcn/ui - Modern component library
- Radix UI - Accessible component primitives
- Framer Motion - Smooth animations and transitions
- Motion Primitives - Advanced animation components
- Lucide React & Tabler Icons - Beautiful icon libraries
- Recharts - Data visualization components
- React Bits - Custom animation components
- Supabase - PostgreSQL database with RLS policies and real-time subscriptions
- Clerk - Authentication and user management
- OpenAI - AI-enhanced matching with GPT-4
- Google Gemini Pro - Alternative AI provider
- SendGrid - Email automation
- Twilio - SMS notifications
- Stripe - Payment processing
- Svix - Webhook validation
- TypeScript - Type safety throughout
- Vitest - Unit testing framework
- Playwright - End-to-end testing
- Testing Library - Component testing
- Turbopack - Fast build tool
- Netlify - Primary deployment (connected to GitHub)
- GitHub Actions - CI pipeline
- Environment Management - Secrets in Netlify dashboard
Secrets managed in Netlify dashboard. Required for production:
| Key | Description |
|---|---|
SUPABASE_URL |
Supabase project URL (server-side) |
NEXT_PUBLIC_SUPABASE_URL |
Supabase project URL (client-side) |
SUPABASE_ANON_KEY |
Supabase anon key (server utilities/tests) |
NEXT_PUBLIC_SUPABASE_ANON_KEY |
Supabase anon key (client-side) |
SUPABASE_SERVICE_ROLE_KEY |
Supabase service role key (server-side) |
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY |
Clerk publishable key |
CLERK_SECRET_KEY |
Clerk secret key |
NEXT_PUBLIC_CLERK_FRONTEND_API_URL |
Clerk JWT template issuer URL |
STRIPE_SECRET_KEY |
Stripe secret key |
STRIPE_WEBHOOK_SECRET |
Stripe webhook secret |
NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY |
Stripe publishable key |
SENTRY_DSN |
Sentry DSN (auto-injected to client) |
SENDGRID_API_KEY |
SendGrid API key |
TWILIO_ACCOUNT_SID, TWILIO_AUTH_TOKEN, TWILIO_PHONE_NUMBER |
Twilio credentials |
- Push to
main→ Netlify auto-builds - Build runs:
npm run lint,npm run type-check,npm run build - Deploy succeeds if build passes
- Verify at https://sandboxmentoloop.online
GET /api/health- JSON response with service status- Expected: HTTP 200 with
"status": "ok"
- Node.js 22 LTS
- npm 10.9.3
- Supabase project
- Clerk account
- Stripe account (test mode)
- SendGrid account
- Twilio account
npm install
cp .env.example .env.localConfigure .env.local:
NEXT_PUBLIC_SUPABASE_URL=your-project-url
NEXT_PUBLIC_SUPABASE_ANON_KEY=your-anon-key
SUPABASE_SERVICE_ROLE_KEY=your-service-role-key
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=pk_test_...
CLERK_SECRET_KEY=sk_test_...
NEXT_PUBLIC_CLERK_FRONTEND_API_URL=https://...
NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY=pk_test_...
STRIPE_SECRET_KEY=sk_test_...
STRIPE_WEBHOOK_SECRET=whsec_...npm run dev # Start dev server
npm run type-check # TypeScript validation
npm run lint # ESLint
npm run build # Production build
npm run test:unit:run # Vitest
npx playwright test # E2E testsSupabase PostgreSQL with Row Level Security policies. Service resolver pattern at lib/supabase/serviceResolver.ts routes API calls to service implementations in lib/supabase/services/.
Clerk handles auth. Users synced to Supabase via webhook. Protected routes use middleware checking Clerk session.
Stripe checkout integration. 70/30 revenue split for preceptor compensation. Webhook validates payment events.
/- Landing page/dashboard- Protected dashboard/student-intake- Student onboarding flow/preceptor-intake- Preceptor onboarding flow
├── app/ # Next.js 15 App Router
│ ├── (landing)/ # Public landing pages
│ ├── dashboard/ # Protected dashboards
│ ├── student-intake/ # Student onboarding
│ └── preceptor-intake/ # Preceptor onboarding
├── components/
│ ├── ui/ # shadcn/ui components
│ └── react-bits/ # Custom animations
├── docs/ # Project documentation
│ └── reports/ # Generated reports and plans
├── lib/
│ ├── supabase/ # Database layer
│ │ ├── services/ # Service implementations
│ │ └── serviceResolver.ts # API router
│ ├── supabase-hooks.ts # React hooks
│ └── supabase-api.ts # API definitions
├── scripts/ # Utility scripts
└── middleware.ts # Route protection
Detailed documentation, reports, and implementation plans can be found in the docs/ directory.
- Reports & Plans:
docs/reports/contains generated reports, migration plans, and status updates. - Architecture:
docs/architecture/contains architectural decisions and diagrams. - Security:
docs/security/contains security audits and implementation guides.
- Hero Section - Animated hero with CTAs
- Features Section - Interactive feature showcase
- Pricing Table - Custom Clerk billing integration
- Testimonials - Social proof section
- FAQ Section - Common questions
- Footer - Links and information
- Sidebar Navigation - Collapsible sidebar with user menu
- Interactive Charts - Data visualization with Recharts
- Data Tables - Sortable and filterable tables
- Payment Gating - Subscription-based access control
- Splash Cursor - Interactive cursor effects
- Animated Lists - Smooth list animations
- Progressive Blur - Modern blur effects
- Infinite Slider - Continuous scrolling elements
The starter kit includes a fully customizable theme system. You can customize colors, typography, and components using:
- Theme Tools: tweakcn.com, themux.vercel.app, or ui.jln.dev
- Global CSS: Modify
app/globals.cssfor custom styling - Component Themes: Update individual component styles in
components/ui/
See .env.example for complete list. Required:
- Supabase URL, anon key, service role key
- Clerk publishable key, secret key, frontend API URL
- Stripe publishable key, secret key, webhook secret
All secrets stored in Netlify for production.
- Connect GitHub repo to Netlify
- Configure environment variables in Netlify dashboard
- Push to
maintriggers auto-deploy
Add new service methods to lib/supabase/services/ and register in serviceResolver.ts.
npm run dev # Development server
npm run build # Production build
npm run type-check # TypeScript validation (REQUIRED before commit)
npm run lint # ESLint + semantic token validation
npm run test:unit:run # Vitest unit tests
npx playwright test # E2E tests- Supabase RLS policies enforce data isolation
- Clerk handles authentication
- No PHI in logs
- Audit trails via
lib/supabase/services/admin.ts
We welcome contributions from healthcare professionals, developers, and educators! Please see our Contributing Guide for detailed information.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Follow healthcare compliance standards (HIPAA/FERPA)
- Write tests for new features
- Maintain accessibility standards (WCAG 2.1 AA)
- Use TypeScript for type safety
- Follow existing code style and patterns
- Discord: Join our developer community
- Discussions: GitHub Discussions
- Issues: Report bugs or request features
- Blog: Read our development blog
- Healthcare Professionals: Thank you to the nurses and educators who provided feedback
- Open Source Community: Built on the shoulders of amazing open source projects
- Beta Testers: Early adopters who helped shape the platform
- Nursing Schools: Partner institutions who supported development
MIT License
Next.js 15 • Supabase • Clerk • Stripe • SendGrid • Twilio