https://github.com/xenios7/healthcare-booking
End-to-end medical appointments platform.
https://github.com/xenios7/healthcare-booking
booking healthcare koyeb postgresql react spring-boot
Last synced: about 2 months ago
JSON representation
End-to-end medical appointments platform.
- Host: GitHub
- URL: https://github.com/xenios7/healthcare-booking
- Owner: Xenios7
- License: mit
- Created: 2025-08-29T11:18:21.000Z (2 months ago)
- Default Branch: main
- Last Pushed: 2025-08-29T17:45:24.000Z (2 months ago)
- Last Synced: 2025-08-29T20:06:07.448Z (2 months ago)
- Topics: booking, healthcare, koyeb, postgresql, react, spring-boot
- Homepage: https://medicalbooking.koyeb.app/
- Size: 419 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ๐ฅ Healthcare Booking App
End-to-end medical appointments platform โ patients book visits, doctors manage availability, admins oversee operations.
---
## ๐งท Repositories
- **API:** https://github.com/Xenios7/Healthcare-Booking-Api
- **Web:** https://github.com/Xenios7/Healthcare-Booking-Frontend
> Looking for implementation details? See each repoโs README. This hub is the product page.
---
## ๐ Live Demo (Cloud-only)
Everything runs in the cloud โ **no local setup required**.
- **Web:** https://medicalbooking.koyeb.app/
- **API:** https://medicalbooking-api.koyeb.app/ โ Swagger at `/swagger-ui`
- **Region/Platform:** Frankfurt (eu-central-1) on Koyeb
- **Database:** Postgres v17 (`ep-cold-scene-a2ffs6hj.eu-central-1.pg.koyeb.app`)
> โ ๏ธ Local development is **optional** and not needed for trying the app. This README is **cloud-first** because the frontend points to the cloud API.
---
## โจ Features
- ๐
Appointment booking flow (create, confirm, cancel)
- ๐ฅ Role-based access (patient / doctor / admin)
- ๐๏ธ Doctor availability & calendar view
- ๐ JWT authentication
- ๐ OpenAPI/Swagger documentation
- ๐ Cloud deployment on Koyeb (web + API + DB)
---
## ๐งฐ Tech Stack
- **Backend:** Spring Boot, PostgreSQL, JWT
- **Frontend:** React
- **Infra:** Koyeb (Web, API, DB)
---
## ๐ฅ Demo Video
Place your video under `docs/` and it will appear here.
- **High quality (download/preview):** `docs/demo.mov`
- **Best browser compatibility:** convert a copy to MP4 โ `docs/demo.mp4`
Your browser does not support the video tag.
Download the demo video.
---
## ๐ธ Screenshots
Put images in `docs/screens/` (use any filenames). A few examples:
- `docs/screens/landing.png`
- `docs/screens/booking.png`
- `docs/screens/calendar.png`
- `docs/screens/admin.png`
> ๐ก Tip: Keep images ~1200px wide for crisp rendering. PNG for UI, SVG/PNG for diagrams.
---
## ๐ง Architecture
Export your diagram to `docs/architecture.png`.
**Flow:** Web (React) โ API (Spring Boot) โ PostgreSQL
**Auth:** JWT (role-based endpoints)
**Deploy:** Koyeb (Frankfurt, eu-central-1)

---
## ๐๏ธ Database
## ๐งฉ ERD


### ๐ Entities & Tables (baseline)
> Replace/extend with your exact fields as implemented.
#### `users`
| field | type | notes |
|---------------|--------------|--------------------------------|
| id | UUID (PK) | |
| email | varchar(255) | unique |
| password_hash | varchar(255) | |
| role | enum | `PATIENT` `DOCTOR` `ADMIN` |
| created_at | timestamptz | default now() |
| updated_at | timestamptz | |
#### `patients`
| field | type | notes |
|--------------|------------------------|-------------------|
| id | UUID (PK/FKโusers.id) | one-to-one user |
| first_name | varchar(100) | |
| last_name | varchar(100) | |
| dob | date | |
| phone | varchar(30) | |
| insurance_no | varchar(100) | nullable |
#### `doctors`
| field | type | notes |
|----------------|------------------------|-----------------------|
| id | UUID (PK/FKโusers.id) | one-to-one user |
| specialization | varchar(120) | |
| bio | text | nullable |
| clinic_id | UUID (FKโclinics.id) | nullable |
#### `clinics`
| field | type | notes |
|---------|----------------|-------|
| id | UUID (PK) | |
| name | varchar(150) | |
| address | text | |
| phone | varchar(30) | |
#### `availability_slots`
| field | type | notes |
|--------------|------------------------|---------------------------------------|
| id | UUID (PK) | |
| doctor_id | UUID (FKโdoctors.id) | |
| start_time | timestamptz | |
| end_time | timestamptz | |
| is_recurring | boolean | default false |
| rrule | varchar(255) | RFC 5545 rule if recurring (optional) |
#### `appointments`
| field | type | notes |
|------------|--------------------------|----------------------------------------------|
| id | UUID (PK) | |
| patient_id | UUID (FKโpatients.id) | |
| doctor_id | UUID (FKโdoctors.id) | |
| start_time | timestamptz | |
| end_time | timestamptz | |
| status | enum | `PENDING` `CONFIRMED` `CANCELLED` `COMPLETED`|
| notes | text | nullable |
| created_at | timestamptz | default now() |
#### `notifications` (optional)
| field | type | notes |
|---------|-----------------------|-------------------------------|
| id | UUID (PK) | |
| user_id | UUID (FKโusers.id) | |
| channel | enum | `EMAIL` `SMS` `PUSH` |
| type | varchar(50) | e.g., `APPT_CONFIRMED` |
| payload | jsonb | |
| status | enum | `QUEUED` `SENT` `FAILED` |
| sent_at | timestamptz | nullable |
---
## ๐ API Docs
- **Prod Swagger:** `https://medicalbooking-api.koyeb.app/swagger-ui`
- **OpenAPI JSON:** `https://medicalbooking-api.koyeb.app/v3/api-docs`
> ๐งช Local Swagger links are omitted because this project is cloud-first and the frontend targets the cloud API.
---
## โ๏ธ Deployment (Koyeb)
- **Web:** `healthcare-booking-frontend` โ https://medicalbooking.koyeb.app/
- **API:** `healthcare-booking-api` โ https://medicalbooking-api.koyeb.app/
- **Database:** Postgres v17 โ `ep-cold-scene-a2ffs6hj.eu-central-1.pg.koyeb.app`
> ๐ Make sure secrets (DB URL/creds, JWT secret, etc.) are stored in Koyeb and **not** committed.
---
## ๐๏ธ Project Structure (Hub)
```
.
โโ docs/
โ โโ architecture.png
โ โโ erd.png
โ โโ demo.mov # optional (original)
โ โโ demo.mp4 # recommended for inline playback
โ โโ screens/
โ โโ landing.png
โ โโ booking.png
โ โโ calendar.png
โ โโ admin.png
โโ README.md
```
---
## ๐ Security Notes
- Never commit secrets or `.env` files
- Use a strong `JWT` secret in production; rotate periodically
- HTTPS/TLS handled by Koyeb (use the HTTPS URLs)
---
## โ FAQ
- **Why isnโt there a local โdocker compose upโ here?**
The app is **cloud-first** and the frontend points to the **cloud API**. You can use the live demo without any local setup.
- **Can I still run locally later?**
Yes โ if you add local envs and point the frontend to a local API; thatโs outside the scope of this README since the current code targets the cloud API.