Base URL
All API requests should be made to:Available Endpoints
The MediGuide API provides the following endpoint categories:User Authentication
Signup, login, and password recovery endpoints
Medical Records
Store and retrieve patient health data
Response Format
All API responses are returned in JSON format.Successful Response
Error Response
HTTP Status Codes
The API uses standard HTTP status codes:| Status Code | Description |
|---|---|
200 | Success - Request completed successfully |
201 | Created - Resource created successfully |
400 | Bad Request - Invalid input or missing required fields |
401 | Unauthorized - Invalid credentials or expired token |
404 | Not Found - Resource not found |
500 | Internal Server Error - Server encountered an error |
Error Handling
All errors follow a consistent format with descriptive messages:Validation Errors (400)
Authentication Errors (401)
Not Found Errors (404)
Server Errors (500)
Core Endpoints
User Management
POST /api/users/signup- Register a new userPOST /api/users/login- Authenticate userPOST /api/users/forgot-password- Request password reset codePOST /api/users/verify-reset-code- Verify reset codePOST /api/users/reset-password- Reset user passwordPOST /api/users- Alternative user registration endpoint
Medical Records
POST /api/medical-info- Create a new medical recordGET /api/medical-info/latest- Get latest medical record for a user
Health Check
GET /api/health- Check API and database connectivity
