This project is a School Management API system designed to manage school data, sort schools by proximity based on user location, and facilitate seamless testing with integrated Postman collections. The system uses Node.js, Express.js, MySQL, and Geolib for geolocation-based sorting and CRUD operations for school data management.
- Add new schools to the database.
- List schools sorted by proximity based on user latitude and longitude.
- Ensure data validation and error handling for smooth user experience.
- Integrated Postman collection for testing the APIs.
- POST /addSchool: Add a new school to the database.
- GET /listSchools: Get schools sorted by proximity from the user's location.
- Node.js
- Express.js
- MySQL
- Geolib
- Postman (for API testing)
- Clone the repository:
git clone <repo-link>
- Install dependencies:
npm install
- Configure environment variables for MySQL in
.env
file. - Run the server:
npm start
- Access the API via
http://localhost:3000
This project is licensed under the MIT License.