A modern telehealth platform for finding doctors, booking appointments, and meeting securely by video.
Built with Next.js, Clerk, Prisma, PostgreSQL, and Vonage Video.
EasyClinic brings the essential clinic experience into one application. Patients can discover verified doctors, schedule appointments using consultation credits, and join a video consultation. Doctors manage their availability and appointments, while administrators review and verify provider profiles.
- Role-based journeys for patients, doctors, and administrators.
- Doctor discovery by specialty, with verified-provider workflows.
- Appointment scheduling that checks availability and prevents overlapping bookings.
- Consultation credits for booking and provider earnings tracking.
- Secure video consultations powered by the Vonage Video API.
- Doctor availability management and patient appointment history.
- Responsive dark interface built with Tailwind CSS and shadcn/ui components.
| Role | What they can do |
|---|---|
| Patient | Complete a profile, find doctors, purchase/use credits, book appointments, and join video calls. |
| Doctor | Complete onboarding, submit credentials, manage availability, review appointments, and join consultations. |
| Administrator | Review pending providers and manage verified doctors. |
| Area | Technology |
|---|---|
| Framework | Next.js 15 (App Router) and React 19 |
| Styling | Tailwind CSS, shadcn/ui, Radix UI, Lucide icons |
| Authentication | Clerk |
| Database | PostgreSQL via Prisma ORM |
| Video | Vonage Video API |
| Validation & forms | Zod, React Hook Form |
| Feedback | Sonner notifications |
- Node.js 18.18 or later
- A PostgreSQL database (for example, Neon)
- A Clerk application
- A Vonage Video API application
git clone <your-repository-url>
cd EasyClinic
npm installCreate a .env file in the project root:
DATABASE_URL="postgresql://..."
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY="pk_..."
CLERK_SECRET_KEY="sk_..."
NEXT_PUBLIC_VONAGE_APPLICATION_ID="..."
VONAGE_PRIVATE_KEY="..."Keep .env private. Never commit database URLs, Clerk secrets, or Vonage private keys.
npm run prisma:generate
npx prisma db pushnpm run devOpen http://localhost:3000 in your browser.
| Command | Description |
|---|---|
npm run dev |
Generates the Prisma client and starts the development server. |
npm run build |
Generates the Prisma client and creates a production build. |
npm run start |
Starts the production server after a build. |
npm run prisma:generate |
Regenerates Prisma Client from prisma/schema.prisma. |
npm run lint |
Runs the configured lint command. |
.
├── action/ # Server actions for appointments, users, credits, and admin data
├── prisma/
│ └── schema.prisma # Database schema and relations
├── public/
│ └── screenshots/ # README visuals
├── src/
│ ├── app/ # App Router pages, layouts, and route groups
│ ├── components/ # Reusable interface components
│ └── lib/ # Prisma client, validation, and application data
└── hooks/ # Shared React hooks
- A visitor registers and completes patient or doctor onboarding.
- A doctor submits credentials and is verified by an administrator.
- A patient finds a verified doctor, selects an available time, and books with credits.
- EasyClinic creates a video session and both participants join at the appointment time.
The Prisma schema models User, Availability, Appointment, CreditTransaction, and Payout records. It also defines role, appointment, verification, slot, transaction, and payout states to support the application’s workflows.
Contributions are welcome. Please create a focused branch, keep changes scoped, and verify the affected flow locally before opening a pull request.
Arvind Rana
