WRITE A PYTHON CODE PLEASE!!!!!! CS5600: Programming Assignment (50 points) In this assignment, you will learn and imple
Posted: Fri Jul 08, 2022 6:15 am
WRITE A PYTHON CODE PLEASE!!!!!!
CS5600: Programming Assignment (50 points) In this assignment,you will learn and implement CRUD(Create, Read, Update, Delete).These are the basic APIs to perform at most functions on webapplications. You will develop the backend web framework usingPython Flask connect to MongoDB (https://www.mongodb.com). Thereare some videos on Blackboard about Flask framework and MongoDBthat you can study before starting this assignment. To test thebackend web framework, you must use API platforms such as PostmanAPI Platform(https://www.postman.com). The CSVfile(Netflix.csv-Movie and Show on Netflix) is provided in thisassignment with the column names including: id title typedescription release_year age_certification runtime (mins.) genresproduction_countries imdb_score First, the instructor will guideyou how to generate MongoDB Database and collections using MongoDBCompass. You will import this csv file to collection netflix onMongoDB database in JSON format. The MongoDB Configuration: Host =‘localhost’ Port = 27017 Database name = database Collection name =netflix … try: mongo = pymongo.MongoClient( host = 'localhost',port = 27017, serverSelectionTimeoutMS = 1000 ) db = mongo.databasemongo.server_info() #trigger exception if cannot connect to dbexcept: print("Error -connect to db") In xxxx.py file, you mustperform the following main functions: Insert the new movie andshow. @app.route('/api', methods=['POST']) Update the movie andshow information using title. (By update title, description andimdb score) @app.route('/api/', methods=['PATCH']) Delete the movieand show information using title. @app.route('/api/',methods=['DELETE']) Retrieve all the movies and shows in [email protected]('/api', methods=['GET']) Display the movie and show’sdetail using title. @app.route('/api/', methods=['GET'])
CS5600: Programming Assignment (50 points) In this assignment,you will learn and implement CRUD(Create, Read, Update, Delete).These are the basic APIs to perform at most functions on webapplications. You will develop the backend web framework usingPython Flask connect to MongoDB (https://www.mongodb.com). Thereare some videos on Blackboard about Flask framework and MongoDBthat you can study before starting this assignment. To test thebackend web framework, you must use API platforms such as PostmanAPI Platform(https://www.postman.com). The CSVfile(Netflix.csv-Movie and Show on Netflix) is provided in thisassignment with the column names including: id title typedescription release_year age_certification runtime (mins.) genresproduction_countries imdb_score First, the instructor will guideyou how to generate MongoDB Database and collections using MongoDBCompass. You will import this csv file to collection netflix onMongoDB database in JSON format. The MongoDB Configuration: Host =‘localhost’ Port = 27017 Database name = database Collection name =netflix … try: mongo = pymongo.MongoClient( host = 'localhost',port = 27017, serverSelectionTimeoutMS = 1000 ) db = mongo.databasemongo.server_info() #trigger exception if cannot connect to dbexcept: print("Error -connect to db") In xxxx.py file, you mustperform the following main functions: Insert the new movie andshow. @app.route('/api', methods=['POST']) Update the movie andshow information using title. (By update title, description andimdb score) @app.route('/api/', methods=['PATCH']) Delete the movieand show information using title. @app.route('/api/',methods=['DELETE']) Retrieve all the movies and shows in [email protected]('/api', methods=['GET']) Display the movie and show’sdetail using title. @app.route('/api/', methods=['GET'])