This project is a REST CRUD API created using flask and mongodb.
Clone the project
git clone https://github.com/Abbashozefa/flask-rest-crud.git
Go to the project directory
cd flask-rest-crud
Install dependencies
pip install requirements.txt
Start the server
flask run
Pull Image
docker pull abbashozefa/flask-crud:flask-api
Run Image
docker run -p 5000:5000 abbashozefa/flask-crud
The API has the following endpoints:
- GET /users - Returns a list of all users.
- GET /users/id - Returns the user with the specified ID.
- POST /users - Creates a new user with the specified data.
- PUT /users/id - Updates the user with the specified ID with the new data.
- DELETE /users/id - Deletes the user with the specified ID.
Use POSTMAN to test the endpoints