A CRUD and REST api with mongodb atlas.
First import all the python dependencies in your virtual environment or globally by the following command
pip install -r requirements.txt
Now you can run the api server by running the run.py file
python -m run
The root has some information about the api
GET /
will show the following output
GET /movies/
will list all movies
GET /movies/<movieId>
will return the movie with the given id
POST /createMovie/
will create the movie record with given information in the body and returns the movie
POST /movies/<movieId>
updates the information of the given movie and returns the updated movie
DELETE /movies/<moviesId>
deletes the movie record with the given id and returns success
If in any of the requests, if the movieId doesn't exist then this will be returned