Skip to content

Radulepy/NestJS-Simple-Backend

Repository files navigation

Nest Logo

A progressive Node.js framework for building efficient and scalable server-side applications.

NPM Version NPM Version CircleCI

Description

Nest framework TypeScript Backend API example. Test API calls on this simple backend example using NodeJS.

Installation

$ npm install

Running the app

# development
$ npm run start

# watch mode
$ npm run start:dev

# production mode
$ npm run start:prod

API endpoints

  • localhost:3000/products GET: get all available products
  • localhost:3000/products/{id} GET: get product by ID available products
  • localhost:3000/products POST: add a new product with JSON object in Body: {title: string, description: string, price: number}
  • localhost:3000/products/{id} DELETE: delete product by ID
  • localhost:3000/products/{id} PATCH: update product, with JSON object in Body (any): {title: string, description: string, price: number}

Test

# unit tests
$ npm run test

# e2e tests
$ npm run test:e2e

# test coverage
$ npm run test:cov

About

Simple NestJS API Backend example

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published