The Patient Record System is a Spring Boot application that provides a comprehensive solution for managing patient records, medical histories, and appointments. This project aims to streamline the process of creating, updating, retrieving, and deleting patient information.
- Java Development Kit (JDK) 8 or later
- MySQL Server
- Clone the repository:
git clone https://github.com/your-username/patient-record-system.git
- Navigate to the project directory:
cd patient-record-system
- Configure the MySQL database connection in the
application.properties
file - Build the project:
./mvnw clean install
- Run the application:
./mvnw spring-boot:run
-
Patient Profile Management
-
Create, retrieve, and delete patient details (name, email, contact number, date of birth)
-
Patients cannot update their medical history details directly.
-
Medical History Management
- Add, retrieve, and delete medical history entries for patients.
- List all medical records for a specific patient.
- Medical history includes details such as history ID, patient ID, disease name, treatment details, and date of diagnosis.
-
Appointment Management
- Retrieve all appointments
- List all appointments for a specific patient
- Update and delete appointments
-
Authentication and Authorization
- JSON Web Token (JWT) based authentication
- Generate and validate JWT tokens for authorized access
- Secure API endpoints with token-based authentication
-
Exception Handling
- Global exception handling mechanism
- Custom exceptions for specific scenarios (e.g., PatientNotFound, AppointmentNotFound, MedicalHistoryInvalid)
- Consistent error responses with detailed messages and resolutions.
GET /patients
- Get all patientsGET /patients/{id}
- Get a patient by IDPOST /patients
- Add a new patientDELETE /patients/{id}
- Delete a patient by ID
GET /history
- Get all medical historiesGET /history/{patientId}
- Get all medical histories for a specific patientPUT /history
- Add a new medical history entryDELETE /history/{id}
- Delete a medical history entry by ID
GET /appointments
- Get all appointmentsGET /appointments/{patientId}
- Get all appointments for a specific patientPUT /appointments
- Update an appointmentDELETE /appointments/{id}
- Delete an appointment by ID
Contributions are welcome! Please follow the contribution guidelines for more information.
This project is licensed under the MIT License.