Table of Contents
- HealthSync Frontend Installation Guide
- HealthSync Backend Installation Guide
- API Endpoints
- Troubleshooting
This guide will help you install and run the frontend of the HealthSync project.
Before beginning, ensure you have the following installed on your machine:
-
Clone the repository (if you haven't already):
git clone https://github.com/your-repo/HealthSync.git cd HealthSync/Frontend/HealthSync
-
Install dependencies using
bun
:bun install
To start the development server, run:
bun run vite
This will start the Vite development server, and you can view the application in your browser.
This guide will help you install and run the backend of the HealthSync project.
Before beginning, ensure you have the following installed on your machine:
-
Clone the repository (if you haven't already):
git clone https://github.com/your-repo/HealthSync.git cd HealthSync/Backend
-
Install dependencies using
pip
:pip install -r requirements.txt
To start the development server, run:
python main.py
This will start the FastAPI server, and you can access the API at http://localhost:8000
.
This section explains the available endpoints in the application.
- GET
/
: Returns a simple message indicating the server is up.
- POST
/counts/
: Update hospital resource counts by creating a JSON file containing resource data.- Request Body:
Counts
model - Response: Success
- Request Body:
- GET
/graph
: Returns graph data from the server in JSON format.
- POST
/walkin/
: Handles walk-in patients by creating a JSON file containing patient data.- Request Body:
Patient
model - Response: Status success
- Request Body:
The application uses Pydantic models to validate and parse incoming requests.
class Patient(BaseModel):
description: str
Example:
{
"description": "John Doe suffering from COVID-19"
}
class Counts(BaseModel):
total_doctors: int
available_doctors: int
patients_being_treated: int
patients_in_waiting_room: int
beds_available: int
total_equipment: int
Example:
{
"total_doctors": 5,
"available_doctors": 3,
"patients_being_treated": 10
}
If you encounter any issues during installation or while running the development server, please refer to: