A full-stack booking and management platform built with Next.js (frontend) and Node.js/Express/MongoDB (backend), designed for role-based access control, real-time features, and a seamless experience.
Amethyst Inn is a feature-rich system for client/guest appointment booking, staff management, and administrative control. It utilizes a modern stack, beautiful responsive UI, and scalable backend architecture. This project covers comprehensive practical features for Patients/Guests, Staff, and Administrators.
- Multi-Role System: Dashboards tailored for Patients/Guests, Staff, and Administrators
- Secure Authentication: Auth with email/password and OAuth (
Better Auth) - Real-time Notifications: Email notifications for events, updates, confirmations
- Responsive Design: Sleek UI with TailwindCSS, Radix UI, Shadcn/ui
- Type-Safe: TypeScript for the frontend, Zod validation schemas
- Database-Driven: MongoDB + Mongoose & Prisma ORM
- Payment Integration: Stripe for service payments
- Booking: Search and book services or appointments
- Manage Bookings: View, reschedule, or cancel
- Profile: Health records/history or reservation history
- Payments: Payment history and online checkout
- Notifications: Alerts for confirmations, reminders, changes
- Dashboard: Daily schedule and stats
- Manage Availability: Set working hours, update profile
- Client Management: Patient/guest lists, records, services/treatments
- Booking Management: Confirm, reschedule, cancel
- Notifications: Updates on bookings
- System Analytics: Usage stats, revenue, metrics
- User Management: Manage patients, staff, accounts
- Booking/Appointment Oversight: View/manage all bookings
- Service Management: Add/edit offered services
- Settings: Configure system, emails, payments
- Next.js: Modern React framework, App Router
- TypeScript: Type safety throughout
- Tailwind CSS, Radix UI, Shadcn/ui: Fast, accessible, beautiful UI
- React Hook Form, Zod: Form state and validation
- Motion, Recharts, Lucide: Animation, charts, icons
- Node.js + Express.js: Robust API server
- MongoDB + Mongoose: Data persistence for medical/guest data
- Prisma (if used for some domain models)
- Stripe: Payments
- Resend: Email handling
- Authentication: JWT, OAuth, and multi-factor support
- ESLint, Prisma Studio, Turbopack
- Node.js 18+
- MongoDB (local/Atlas)
- npm/yarn/pnpm/bun
- Git
git clone https://github.com/bry-ly/Amethyst-Inn.git
git clone https://github.com/bry-ly/amethyst-inn-server.gitFrontend:
cd Amethyst-Inn
pnpm install # or npm/yarnBackend:
cd ../amethyst-inn-server
npm install # or yarn/pnpmSet up the following (.env for both projects):
NEXT_PUBLIC_APP_URL=http://localhost:3000
DATABASE_URL="mongodb+srv://username:password@cluster.mongodb.net/amethyst_inn"
BETTER_AUTH_SECRET=your_secret
BETTER_AUTH_URL=http://localhost:3000
GOOGLE_CLIENT_ID=your_google_client_id
GOOGLE_CLIENT_SECRET=your_google_client_secret
RESEND_API_KEY=your_resend_api_key
EMAIL_SENDER_NAME="Amethyst Inn"
EMAIL_SENDER_ADDRESS="send@amethystinn.com"
STRIPE_SECRET_KEY=sk_test_...
STRIPE_WEBHOOK_SECRET=whsec_...
NEXT_STRIPE_PUBLISHABLE_KEY=pk_test_...Consult config/ for custom variables:
- Database connection, JWT secret, SMTP/API keys, Stripe keys, etc.
Backend:
- MongoDB must be running/Atlas up and URI in env.
- Seeders are in
seeder/
Frontend:
cd Amethyst-Inn
pnpm dev # or yarn/ npm run devBackend:
cd amethyst-inn-server
npm run dev # or node server.js / app.jsVisit http://localhost:3000
Amethyst-Inn/
βββ app/
β βββ (auth)/
β βββ (main)/
β βββ api/
β βββ docs/
β βββ services/
β βββ page.tsx
βββ components/
βββ hooks/
βββ lib/
β βββ actions/
β βββ auth-session/
β βββ email/
β βββ types/
βββ public/
βββ types/
βββ utils/
βββ middleware.ts
amethyst-inn-server/
βββ api/ # REST API logic
βββ config/ # Configuration files (env, DB, Stripe, Mail, etc)
βββ controllers/ # Route logic/handlers
βββ docs/ # API docs, guides
βββ middleware/ # Middleware logic
βββ models/ # Mongoose models
βββ routes/ # API routes
βββ scripts/ # Utilities / tasks scripts
βββ seeder/ # DB seed scripts
βββ services/ # Business logic/services
βββ uploads/ # Static uploads
βββ utils/ # Helpers/utilities
βββ server.js # Server entry
βββ app.js # Express app logic
βββ package.json
βββ vercel.json
Both apps support secure login, registration, and session management, using JWT, cookies, and optionally Google OAuth. Email verification, password reset, and role-based dashboards are provided.
- User: (role, profile, payment)
- Service: (name, category, pricing)
- Appointment: (patient/guest, provider, slot, status)
- Payment, Notification, Audit Log, etc
See backend /models and frontend /prisma/schema.prisma (if TypeScript models exist).
- Stripe: Secure checkout, PCI-compliant, payment history, multi-methods
(Frontend)
pnpm run dev # Dev server
pnpm run build # Build production
pnpm run lint # Code lint(Backend)
npm run dev # Start API server
npm run seed # Seed DB (see /seeder)- Frontend: Vercel recommended (see Vercel, Netlify, or similar)
- Backend: Vercel, Railway, Render, or own VPS
- MongoDB: Atlas preferred
Don't forget:
- Update production URLs and secrets; whitelist IP for Atlas
- Using Resend for transactional emails (verification, reminders, etc)
- Email config in
.env
- Database: Ensure MongoDB Atlas/local is up & URI correct
- Email: Resend API key, verify sender address
- Payments: Stripe test keys for dev, check webhooks
Educational/demo only.
- [Your Name/Team Name]
For issues:
- Open GitHub issues
- Contact maintainers
- See
/docs
Built with β€οΈ using Next.js, Node.js, MongoDB, and modern web tech.