Welcome to the College API! This API showcases a collection of undergraduate engineering colleges in India that are approved by the All India Council for Technical Education (AICTE) along with their respective states.
To use this API locally or deploy it, follow these steps:
- Node.js (14.x recommended)
- MongoDB (Make sure you have a running MongoDB instance)
-
Fork and clone this repository to your local machine.
-
Open a terminal and navigate to the
backend
directory:
cd backend
- Install the required dependencies:
npm install
- Create a
.env
file in thebackend
directory:
MONGODB_URL=your_mongodb_url_here
Replace your_mongodb_url_here with the actual MongoDB connection URL.
- Start the backend server
npm start
The server will be accessible at http://localhost:8000.
- To view the list of colleges, open a web browser or use a tool like Postman and navigate to:
http://localhost:8000/api/colleges
-
Use the /api/colleges endpoint to get a list of all colleges.
-
Use the /api/states endpoint to get a list of all states.
-
You can filter colleges based on states by appending ?state=state_name to the /api/colleges endpoint.
- Fork this repository.
- Create a new branch for your feature:
git checkout -b feature/your-feature-name
- Commit and push your changes to your branch.
- Create a pull request to merge your changes into the main repository.