# maryaylla/caresync_proj architecture

> Architecture diagram of the GitHub repository maryaylla/caresync_proj, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-15). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/maryaylla/caresync_proj
- Repository: https://github.com/maryaylla/caresync_proj

## Overview

CareSync is a Laravel personal-health application. Users register or sign in, then use the authenticated dashboard and feature routes to manage appointments, doctors, medication treatments, check-ups, and hydration. Treatment-dose updates calculate completion and schedule the next dose; the dashboard summarizes upcoming health events and water progress. The graph follows documented routes and sampled controller/model references; unsampled features are included only where the README or source index supports them.

Main entry points: [`caresync/routes/web.php`](https://github.com/maryaylla/caresync_proj/blob/main/caresync/routes/web.php) (Web routes), [`caresync/app/Http/Controllers/DashboardController.php`](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/DashboardController.php) (Dashboard), [`caresync/app/Http/Controllers/AppointmentController.php`](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/AppointmentController.php) (Appointments), [`caresync/app/Http/Controllers/MedicationController.php`](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/MedicationController.php) (Treatment engine)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Web entry"]
  node_routes["Web routes<br/>[web.php]"]
end

subgraph group_identity["Identity"]
  node_auth["Authentication<br/>[AuthController.php]"]
end

subgraph group_care["Care management"]
  node_appointments["Appointments"]
  node_doctors["Doctor directory"]
  node_medications["Treatment engine"]
  node_medicines["Medicine catalog"]
  node_special_dates["Check-ups"]
  node_celebrations["Celebration notices"]
  node_celebration_mail["Celebration email"]
end

subgraph group_overview["Health overview"]
  node_dashboard["Dashboard"]
  node_dashboard_view["Dashboard display"]
  node_water_input["Water logging<br/>[web.php]"]
end

subgraph group_domain["Domain records"]
  node_user_record[("User account<br/>[User.php]")]
  node_appointment_record[("Appointment records<br/>[Appointment.php]")]
  node_doctor_record[("Doctor records<br/>[Doctor.php]")]
  node_medication_record[("Treatment records<br/>[Medication.php]")]
  node_medicine_record[("Medicine records<br/>[Medicine.php]")]
  node_special_date_record[("Event records<br/>[SpecialDate.php]")]
  node_water_record[("Water logs<br/>[WaterLog.php]")]
end

node_user(("Health user"))

node_user -->|"uses"| node_routes
node_routes -->|"routes requests"| node_auth
node_routes -->|"routes requests"| node_dashboard
node_routes -->|"routes requests"| node_appointments
node_routes -->|"routes requests"| node_doctors
node_routes -->|"routes requests"| node_medications
node_routes -->|"routes requests"| node_medicines
node_routes -->|"routes requests"| node_special_dates
node_auth -->|"creates account"| node_user_record
node_dashboard -->|"reads upcoming"| node_appointment_record
node_dashboard -->|"reads next dose"| node_medication_record
node_dashboard -->|"reads check-ups"| node_special_date_record
node_dashboard -->|"sums daily intake"| node_water_record
node_dashboard -->|"renders"| node_dashboard_view
node_water_input -->|"records intake"| node_water_record
node_appointments -->|"creates and updates"| node_appointment_record
node_appointments -->|"lists doctors"| node_doctor_record
node_doctors -->|"manages records"| node_doctor_record
node_medications -->|"updates doses"| node_medication_record
node_medications -->|"loads catalog"| node_medicine_record
node_medicines -->|"manages catalog"| node_medicine_record
node_special_dates -->|"manages events"| node_special_date_record
node_celebrations -.->|"sends message"| node_celebration_mail

click node_routes "https://github.com/maryaylla/caresync_proj/blob/main/caresync/routes/web.php"
click node_auth "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/AuthController.php"
click node_user_record "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/User.php"
click node_dashboard "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/DashboardController.php"
click node_appointments "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/AppointmentController.php"
click node_doctors "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/DoctorController.php"
click node_medications "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/MedicationController.php"
click node_medicines "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/MedicineController.php"
click node_special_dates "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/SpecialDateController.php"
click node_appointment_record "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/Appointment.php"
click node_doctor_record "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/Doctor.php"
click node_medication_record "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/Medication.php"
click node_medicine_record "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/Medicine.php"
click node_special_date_record "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/SpecialDate.php"
click node_water_record "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/WaterLog.php"
click node_dashboard_view "https://github.com/maryaylla/caresync_proj/blob/main/caresync/resources/views/dashboard.blade.php"
click node_water_input "https://github.com/maryaylla/caresync_proj/blob/main/caresync/routes/web.php"
click node_celebrations "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Console/Commands/SendCelebrations.php"
click node_celebration_mail "https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Mail/CelebrationMessage.php"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_routes,node_user toneBlue
class node_auth toneAmber
class node_appointments,node_doctors,node_medications,node_medicines,node_special_dates,node_celebrations,node_celebration_mail toneMint
class node_dashboard,node_dashboard_view,node_water_input toneRose
class node_user_record,node_appointment_record,node_doctor_record,node_medication_record,node_medicine_record,node_special_date_record,node_water_record toneIndigo
```

## Components

### Web entry

- [Web routes](https://github.com/maryaylla/caresync_proj/blob/main/caresync/routes/web.php): `caresync/routes/web.php`

### Identity

- [Authentication](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/AuthController.php): `caresync/app/Http/Controllers/AuthController.php`

### Care management

- [Appointments](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/AppointmentController.php): `caresync/app/Http/Controllers/AppointmentController.php`
- [Doctor directory](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/DoctorController.php): `caresync/app/Http/Controllers/DoctorController.php`
- [Treatment engine](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/MedicationController.php): `caresync/app/Http/Controllers/MedicationController.php`
- [Medicine catalog](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/MedicineController.php): `caresync/app/Http/Controllers/MedicineController.php`
- [Check-ups](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/SpecialDateController.php): `caresync/app/Http/Controllers/SpecialDateController.php`
- [Celebration notices](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Console/Commands/SendCelebrations.php): `caresync/app/Console/Commands/SendCelebrations.php`
- [Celebration email](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Mail/CelebrationMessage.php): `caresync/app/Mail/CelebrationMessage.php`

### Health overview

- [Dashboard](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Http/Controllers/DashboardController.php): `caresync/app/Http/Controllers/DashboardController.php`
- [Dashboard display](https://github.com/maryaylla/caresync_proj/blob/main/caresync/resources/views/dashboard.blade.php): `caresync/resources/views/dashboard.blade.php`
- [Water logging](https://github.com/maryaylla/caresync_proj/blob/main/caresync/routes/web.php): `caresync/routes/web.php`

### Domain records

- [User account](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/User.php): `caresync/app/Models/User.php`
- [Appointment records](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/Appointment.php): `caresync/app/Models/Appointment.php`
- [Doctor records](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/Doctor.php): `caresync/app/Models/Doctor.php`
- [Treatment records](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/Medication.php): `caresync/app/Models/Medication.php`
- [Medicine records](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/Medicine.php): `caresync/app/Models/Medicine.php`
- [Event records](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/SpecialDate.php): `caresync/app/Models/SpecialDate.php`
- [Water logs](https://github.com/maryaylla/caresync_proj/blob/main/caresync/app/Models/WaterLog.php): `caresync/app/Models/WaterLog.php`

### Other components

- **Health user**

## Connections

- Health user → Web routes: uses (evidence: `caresync/routes/web.php`)
- Web routes → Authentication: routes requests (evidence: `caresync/routes/web.php`)
- Web routes → Dashboard: routes requests (evidence: `caresync/routes/web.php`)
- Web routes → Appointments: routes requests (evidence: `caresync/routes/web.php`)
- Web routes → Doctor directory: routes requests (evidence: `caresync/routes/web.php`)
- Web routes → Treatment engine: routes requests (evidence: `caresync/routes/web.php`)
- Web routes → Medicine catalog: routes requests (evidence: `caresync/routes/web.php`)
- Web routes → Check-ups: routes requests (evidence: `caresync/routes/web.php`)
- Authentication → User account: creates account (evidence: `caresync/app/Http/Controllers/AuthController.php`)
- Dashboard → Appointment records: reads upcoming (evidence: `caresync/app/Http/Controllers/DashboardController.php`)
- Dashboard → Treatment records: reads next dose (evidence: `caresync/app/Http/Controllers/DashboardController.php`)
- Dashboard → Event records: reads check-ups (evidence: `caresync/app/Http/Controllers/DashboardController.php`)
- Dashboard → Water logs: sums daily intake (evidence: `caresync/app/Http/Controllers/DashboardController.php`)
- Dashboard → Dashboard display: renders (evidence: `caresync/app/Http/Controllers/DashboardController.php`)
- Water logging → Water logs: records intake (evidence: `caresync/routes/web.php`)
- Appointments → Appointment records: creates and updates (evidence: `caresync/app/Http/Controllers/AppointmentController.php`)
- Appointments → Doctor records: lists doctors (evidence: `caresync/app/Http/Controllers/AppointmentController.php`)
- Doctor directory → Doctor records: manages records (evidence: `caresync/app/Http/Controllers/DoctorController.php`)
- Treatment engine → Treatment records: updates doses (evidence: `caresync/app/Http/Controllers/MedicationController.php`)
- Treatment engine → Medicine records: loads catalog (evidence: `caresync/app/Http/Controllers/MedicationController.php`)
- Medicine catalog → Medicine records: manages catalog (evidence: `caresync/app/Http/Controllers/MedicineController.php`)
- Check-ups → Event records: manages events (evidence: `caresync/app/Http/Controllers/SpecialDateController.php`)
- Celebration notices → Celebration email: sends message
