Skip to content

trohat/backend_api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Basic backend API for simple movie database

This API is created in Node.js with the help of Express. The database used is MongoDB with mongoose.

This API is used as a base for Node.js articles on ITnetwork.

Database is created on localhost (this will be configurable in the future) and requires active installation of MongoDB.

This API is able to use four basic HTTP methods (get, post, put and delete).

For validation, the Joi module as well as implicit mongoose validation is used.

To install dependencies, type npm install in the app root directory.

Endpoints:

(replace the expression in parentheses as appropriate)

GET requests:

to get all movies:

localhost:(port_number)/api/movies

or to get one particular movie:

localhost:(port_number)/api/movies/(movie_id)

POST requests:

localhost:(port_number)/api/movies

PUT requests:

localhost:(port_number)/api/movies/(movie_id)

DELETE requests:

localhost:(port_number)/api/movies/(movie_id)

About

Simple backend API

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors