Creating a Web API using Nodejs and Express.
Nodejs
NPM
MongoDB
/MongoAtlas
- your preferred code editor
- a REST client like Postman
- Fork and clone the repository.
- Create a new branch:
git checkout -b <firstName-lastName>
. - Run
npm install
to download dependencies. - Take a look at
.env-example
, you will need to create and setup your.env
file accordingly. - Run the server using
npm run server
.
Take time to plan out what data you will need, which structures will manage that data, and what functionalities you may need to update that same structures. You can use pen and paper for this, also a tool like draw.io can help you a lot. It is essential that you follow best practices and produce clean and professional results.
Initialize the project with npm init
. Improve it using express
and nodemon
.
Cloudinary is the market leader in providing a comprehensive cloud-based image and video management platform. Follow this link to configure cloudinary in your project.
Use mongoose
to setup the schemas.To control the requests coming from the client, create appropriate responses: GET
, POST
, PUT
, DELETE
endpoints.
API - http://api-olymp-cinema.herokuapp.com/ Client - https://olymp-cinema.vercel.app/