How to create a REST API with Express.js and Node.js

Kirti K
Webtips
Published in
8 min readJun 1, 2020

--

In this tutorial, we’ll be learning how to build a Rest API in Node.js and Express.js by building a simple crud user app API. The source code for the final project can be found here

Before we start please find below important technologies definitions

  1. Node — Node.js® is a JavaScript runtime built on Chrome’s V8 JavaScript engine. As an asynchronous event-driven JavaScript runtime, Node.js is designed to build scalable network applications. It compiles the JavaScript directly into the native machine code. It is a lightweight framework used for creating server-side web applications and extends JavaScript API to offer usual server-side functionalities.
    Features — It is fast, Asynchronous, Scalable, Open Source and no buffering (Node.js applications simply output the data in chunks and never buffer any data)
  2. Package.json — The package.json file in Node.js is the heart of the entire application. It is basically the manifest file that contains the metadata of the project where we define the properties of a package.
  3. Express js — Express 3.x is a light-weight web application framework to help organize your web application into an MVC architecture on the server side.Express.js is not a model-view-controller framework by itself. You need to bring your own object-relational mapping libraries such as Mongoose for MongoDB, Sequelize (http://sequelizejs.com) for SQL databases, Waterline (https://github.com/balderdashy/waterline) for many databases into the…

--

--

Kirti K
Webtips

Kind is cool & share your knowledge 👋 👋 A seasoned front-end developer with over 15 years of experience crafting immersive digital experiences.