Building RESTful Web APIs with Node.js, Express, MongoDB and TypeScript
latest

Contents:

  • Introductions
  • Setting Up Project
  • Implement Routing and CRUD
  • Using Controller and Model
  • Connect Web APIs to MongoDB
  • Security for our Web APIs
Building RESTful Web APIs with Node.js, Express, MongoDB and TypeScript
  • Docs »
  • Building RESTful Web APIs with Node.js, Express, MongoDB and TypeScript
  • Edit on GitHub

Building RESTful Web APIs with Node.js, Express, MongoDB and TypeScript¶

This is a simple API that saves contact information of people.

There are two versions of this project.

V1.0.0: you can run the server directly after cloning this version. It will create a simple RESTful API over HTTP.

V2.0.0: this is a more secure and control API project. You need to read the post on how to secure RESTful API application first. After that, you can run the project.

_images/cover.png

(Image from OctoPerf)

Contents:

  • Introductions
    • Who is this book for?
    • How to read this book?
  • Setting Up Project
    • Before we get started
    • MongoDB preparation
    • Step 1: Initiate a Node project
    • Step 2: Install all the dependencies
    • Step 3: Configure the TypeScript configuration file (tsconfig.json)
    • Step 4: edit the running scripts in package.json
    • Step 5: getting started with the base configuration
  • Implement Routing and CRUD
    • Step 1: Create TS file for routing
    • Step 2: Building CRUD for the Web APIs
  • Using Controller and Model
    • Create Model for your data
    • Create your first Controller
  • Connect Web APIs to MongoDB
    • 1. Create your first contact
    • 2. Get all contacts
    • 3. Get contact by Id
    • 4. Update an existing contact
    • 5. Delete a contact
  • Security for our Web APIs
    • Method 1: The first and foremost is that you should always use HTTPS over HTTP
    • Method 2: Using secret key for authentication
    • Method 3: Secure your MongoDB

Indices and tables¶

  • Index
  • Module Index
  • Search Page
Next

© Copyright 2019, Dale Nguyen Revision 375a3939.

Built with Sphinx using a theme provided by Read the Docs.
Read the Docs v: latest
Versions
latest
stable
Downloads
pdf
html
epub
On Read the Docs
Project Home
Builds

Free document hosting provided by Read the Docs.