{"id":35268948,"url":"https://github.com/denko5/afyacare","last_synced_at":"2026-04-11T06:41:59.724Z","repository":{"id":328465787,"uuid":"1115650939","full_name":"denko5/afyacare","owner":"denko5","description":"A comprehensive hospital management system for Kenyan healthcare facilities. Features admin dashboard, doctor portal, patient booking, real-time notifications, and appointment management. Built with Laravel 11 and MySQL.","archived":false,"fork":false,"pushed_at":"2025-12-13T09:35:52.000Z","size":172,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-12-14T23:55:20.586Z","etag":null,"topics":["appointment-booking","backend","bootstrap","frontend","healthcare","hospital-management-system","laravel","laravel-11","medical-system","mysql","patient-management-system","php","web-application"],"latest_commit_sha":null,"homepage":"","language":"Blade","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/denko5.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-12-13T09:18:37.000Z","updated_at":"2025-12-13T09:42:57.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/denko5/afyacare","commit_stats":null,"previous_names":["denko5/afyacare"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/denko5/afyacare","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denko5%2Fafyacare","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denko5%2Fafyacare/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denko5%2Fafyacare/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denko5%2Fafyacare/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/denko5","download_url":"https://codeload.github.com/denko5/afyacare/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denko5%2Fafyacare/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31671629,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-10T17:19:37.612Z","status":"online","status_checked_at":"2026-04-11T02:00:05.776Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["appointment-booking","backend","bootstrap","frontend","healthcare","hospital-management-system","laravel","laravel-11","medical-system","mysql","patient-management-system","php","web-application"],"created_at":"2025-12-30T11:49:28.369Z","updated_at":"2026-04-11T06:41:59.715Z","avatar_url":"https://github.com/denko5.png","language":"Blade","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AfyaCare Hospital Management System\n\nA comprehensive web-based hospital management system designed to streamline healthcare operations in Kenya. The system facilitates efficient management of appointments, doctors, departments, and patient interactions while providing real-time notifications and analytics.\n\n## About\n\nAfyaCare is a modern hospital management solution built to address the challenges faced by healthcare facilities in managing patient appointments and medical staff coordination. The system provides three distinct user interfaces tailored to the needs of administrators, doctors, and patients, ensuring smooth workflow and enhanced patient care delivery.\n\nThe platform enables hospitals to digitize their appointment booking process, manage doctor schedules, track patient visits, and maintain organized department structures. By providing real-time notifications and comprehensive dashboards, AfyaCare helps reduce administrative overhead while improving patient experience and operational efficiency.\n\n## Key Features\n\n### Administrator Module\n- Complete hospital dashboard with analytics and statistics\n- Doctor profile management (add, edit, remove doctors)\n- Department management and organization\n- Appointment oversight and monitoring\n- Real-time system metrics and reporting\n- User access control and management\n\n### Doctor Module\n- Personal dashboard with appointment overview\n- View all scheduled appointments with patient details\n- Confirm or decline appointment requests\n- Provide reasons for declined appointments with alternative date suggestions\n- Mark appointments as completed\n- Add medical notes and observations to patient records\n- Direct patient contact capabilities (call/email)\n- Filter appointments by status (pending, confirmed, completed)\n\n### Patient Module\n- User-friendly appointment booking interface\n- Browse available doctors by department and specialization\n- View doctor profiles including qualifications and consultation fees\n- Track appointment history and status\n- Real-time notification system for appointment updates\n- Dashboard showing upcoming and completed appointments\n- Notification center with read/unread status management\n\n### Notification System\n- Automated notifications for appointment confirmations\n- Alerts for appointment declinations with doctor's reasoning\n- Notifications for completed appointments\n- Suggested alternative dates from doctors\n- Mark notifications as read/unread\n- Delete old notifications\n- Unread notification counter in navigation\n\n## Technical Specifications\n\n### Built With\n- Laravel 11 - PHP web application framework\n- PHP 8.2 - Server-side scripting language\n- MySQL - Relational database management system\n- Bootstrap 5 - Frontend CSS framework\n- JavaScript - Client-side interactivity\n- Blade - Laravel templating engine\n\n### System Requirements\n- PHP \u003e= 8.2\n- Composer\n- MySQL \u003e= 5.7 or MariaDB \u003e= 10.3\n- Apache or Nginx web server\n- Node.js and NPM (for asset compilation)\n\n## Installation Instructions\n\n### 1. Clone the Repository\n```bash\ngit clone https://github.com/YOUR-USERNAME/afyacare.git\ncd afyacare\n```\n\n### 2. Install Dependencies\n```bash\ncomposer install\n```\n\n### 3. Environment Configuration\n```bash\ncp .env.example .env\n```\n\nEdit the `.env` file and configure your database connection:\n```\nDB_CONNECTION=mysql\nDB_HOST=127.0.0.1\nDB_PORT=3306\nDB_DATABASE=afyacare_db\nDB_USERNAME=your_username\nDB_PASSWORD=your_password\n```\n\n### 4. Generate Application Key\n```bash\nphp artisan key:generate\n```\n\n### 5. Run Database Migrations\n```bash\nphp artisan migrate\n```\n\n### 6. Seed Initial Data (Optional)\n```bash\nphp artisan db:seed\n```\n\n### 7. Create Storage Link\n```bash\nphp artisan storage:link\n```\n\n### 8. Start Development Server\n```bash\nphp artisan serve\n```\n\nThe application will be available at `http://127.0.0.1:8000`\n\n## Database Structure\n\n### Main Tables\n- users: User authentication and profile information\n- patients: Patient-specific data\n- doctors: Doctor profiles and specializations\n- departments: Hospital departments\n- appointments: Appointment bookings and details\n- notifications: User notification management\n\n### Relationships\n- One user can be one patient, doctor, or admin\n- Doctors belong to departments\n- Appointments link patients to doctors\n- Notifications belong to users\n\n## Default Login Credentials\n\nAfter installation, you can create test accounts or use seeded data:\n\n**Administrator**\n- Email: admin@afyacare.co.ke\n- Password: admin123\n\n**Doctor**\n- Email: doctor@afyacare.co.ke\n- Password: doctor123\n\n**Patient**\n- Email: patient@afyacare.co.ke\n- Password: patient123\n\nNote: Change these credentials in production environment.\n\n## User Roles and Permissions\n\n### Admin\n- Full system access\n- Manage doctors and departments\n- View all appointments\n- System configuration\n- User management\n\n### Doctor\n- View assigned appointments\n- Confirm/decline appointments\n- Add medical notes\n- Update appointment status\n- View patient contact information\n\n### Patient\n- Book appointments\n- View appointment history\n- Receive notifications\n- View doctor profiles\n- Update personal information\n\n## Workflow\n\n### Appointment Booking Process\n1. Patient registers/logs into the system\n2. Patient browses available doctors by department\n3. Patient selects a doctor and books an appointment\n4. Appointment status set to \"pending\"\n5. Doctor receives notification of new appointment\n6. Doctor reviews and confirms or declines appointment\n7. Patient receives notification of doctor's decision\n8. If declined, doctor can suggest alternative dates\n9. Confirmed appointments appear in both doctor and patient dashboards\n10. After consultation, doctor marks appointment as completed\n11. Patient receives completion notification\n\n## Security Features\n\n- Password hashing using bcrypt\n- CSRF protection on all forms\n- Role-based access control\n- Session management\n- SQL injection prevention through Eloquent ORM\n- XSS protection via Blade templating\n- Secure authentication system\n\n## Future Enhancements\n\nPotential features for future development:\n- Medical records management\n- Prescription management\n- Billing and invoicing system\n- SMS notifications via Africa's Talking API\n- Email notifications\n- Online payment integration (M-Pesa)\n- Patient medical history tracking\n- Doctor schedule management\n- Video consultation capabilities\n- Report generation and export\n- Multi-language support (English, Swahili)\n\n## Project Structure\n```\nafyacare/\n├── app/\n│   ├── Http/\n│   │   ├── Controllers/\n│   │   │   ├── Admin/\n│   │   │   ├── Doctor/\n│   │   │   └── Patient/\n│   │   └── Middleware/\n│   └── Models/\n├── database/\n│   ├── migrations/\n│   └── seeders/\n├── resources/\n│   └── views/\n│       ├── admin/\n│       ├── doctor/\n│       ├── patient/\n│       └── layouts/\n├── routes/\n│   └── web.php\n└── public/\n```\n\n## Contributing\n\nThis project is currently maintained for academic purposes. For suggestions or improvements, please contact the project owner.\n\n## Troubleshooting\n\n### Common Issues\n\n**Issue: \"Class not found\" errors**\nSolution: Run `composer dump-autoload`\n\n**Issue: \"No application encryption key has been specified\"**\nSolution: Run `php artisan key:generate`\n\n**Issue: Database connection errors**\nSolution: Verify database credentials in `.env` file and ensure MySQL service is running\n\n**Issue: 404 errors on routes**\nSolution: Run `php artisan route:clear` and `php artisan cache:clear`\n\n**Issue: Permission denied on storage**\nSolution: Set proper permissions `chmod -R 775 storage bootstrap/cache`\n\n## System Architecture\n\nThe system follows the MVC (Model-View-Controller) architecture pattern:\n- Models: Represent database tables and business logic\n- Views: Blade templates for user interface\n- Controllers: Handle HTTP requests and application logic\n\nAuthentication and authorization are managed through Laravel's built-in authentication system with custom role-based middleware.\n\n## API Documentation\n\nCurrently, the system uses web routes. RESTful API endpoints can be added for mobile application integration in future versions.\n\n## Testing\n\nRun the test suite:\n```bash\nphp artisan test\n```\n\n## Deployment\n\n### Production Deployment Checklist\n1. Set `APP_ENV=production` in `.env`\n2. Set `APP_DEBUG=false` in `.env`\n3. Configure production database\n4. Run `php artisan config:cache`\n5. Run `php artisan route:cache`\n6. Run `php artisan view:cache`\n7. Set up proper file permissions\n8. Configure web server (Apache/Nginx)\n9. Set up SSL certificate\n10. Configure backup strategy\n\n### Recommended Hosting\n- VPS: DigitalOcean, Linode, Vultr\n- Shared Hosting: Compatible with cPanel hosting\n- Cloud: AWS, Google Cloud, Azure\n- Platform: Railway, Render, Heroku alternatives\n\n## License\n\nThis project is licensed for educational and academic use only. Commercial use requires explicit permission from the author.\n\n## Support and Contact\n\nFor technical support, feature requests, or bug reports:\n- GitHub Issues: https://github.com/YOUR-USERNAME/afyacare/issues\n- Email: support@afyacare.co.ke\n\n## Acknowledgments\n\nBuilt as a demonstration of modern web application development using Laravel framework, following best practices for healthcare management systems.\n\n## Version History\n\n### Version 1.0.0 (Initial Release)\n- Basic user authentication system\n- Admin, Doctor, and Patient modules\n- Appointment management\n- Department management\n- Notification system\n- Responsive design\n\n## Technical Documentation\n\nFor detailed technical documentation, including database schema, API endpoints, and architecture diagrams, please refer to the `/docs` directory (to be added).\n\n## Screenshots\n\nScreenshots and demo videos available upon request.\n\n## Disclaimer\n\nThis system is designed for educational purposes and demonstration. For production use in healthcare settings, ensure compliance with local healthcare regulations and data protection laws (such as HIPAA, GDPR, or Kenya Data Protection Act).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdenko5%2Fafyacare","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdenko5%2Fafyacare","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdenko5%2Fafyacare/lists"}