Moaaz Mustafa

← All Projects

Medicio

An AI-powered integrated healthcare navigation platform that connects patients with doctors, hospitals, pharmacies, and diagnostic labs through a single unified web interface.

PlannedJun 2026 — Present

Technologies

React
Next.js
TypeScript
Tailwind CSS
CSS3
Node.js
PostgreSQL
Docker
GitHub Actions
VS Code
Framer Motion
Git
Prisma
Node Package Manager
ESLint
Pretier
HeroUI
REST API
Claude
Express
Github
Stripe

Categories

Web ApplicationFull Stack

Overview

Medicio is a full-stack web application designed to solve a real problem in Pakistan's healthcare system — patients do not know which doctor to visit, which medicine is safe to take, or which lab can run their tests. Medicio brings all of this together in one place using Artificial Intelligence.

Key Features

  • AI Symptom Checker — Patient enters symptoms and receives a list of possible conditions, a risk level (Low / Medium / High), and a recommended specialist type. Every result includes a mandatory medical disclaimer.
  • Doctor & Hospital Recommendation — AI maps symptoms to a medical specialization and surfaces registered doctors and hospitals from the live database.
  • AI Medicine Suggestion — Suggests only OTC (non-prescription) medicines that are currently in stock at registered pharmacies. Prescription medicines are filtered out at both the prompt and API level.
  • AI Lab Test Recommendation — Suggests relevant diagnostic tests based on symptoms and shows which registered labs offer them with pricing and turnaround time.
  • Doctor Profile Pages — Each doctor has a dedicated page showing their bio, hospital affiliation, license number, and a specialization-aware AI chat assistant.
  • Patient Medical Records — Full timeline of all AI results, prescriptions notes, and lab reports saved per patient.
  • Admin CMS — Role-secured dashboard for managing Doctors, Hospitals, Specializations, Pharmacies, Medicines, Labs, and Lab Tests.

Architecture

  • Frontend: Next.js 14 App Router with React Server Components and Tailwind CSS for a responsive, mobile-friendly UI.
  • Backend: Next.js API Routes organized by domain — /api/auth, /api/ai, /api/admin, /api/records, /api/pharmacies, /api/labs.
  • Database: PostgreSQL with Prisma ORM. 12 entities including User, Patient, Doctor, Hospital, DoctorHospital (many-to-many), Specialization, MedicalRecord, Pharmacy, Medicine, Lab, LabTest, and Appointment.
  • AI Layer: Modular AI service class wrapping an LLM API. Each feature uses structured JSON-output prompts with Zod schema validation and safety guardrails.
  • Auth: JWT-based authentication with three roles — Admin, Doctor, Patient — enforced via RBAC middleware on all protected routes.

AI Safety Rules

  • AI never states a definitive diagnosis.
  • Every AI output includes a disclaimer: 'This is not a medical diagnosis. Always consult a qualified doctor.'
  • Prescription medicines are blocked at both the prompt level and the API response filter.
  • All AI responses are validated against a strict Zod schema before storage or display.

Deployment

  • Application hosted on Vercel.
  • PostgreSQL database hosted on Supabase.