firatkocabay / alternative-movie-api

This is the alternative movie API

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

alternative-movie-api

This is the alternative movie API

Movies

Route HTTP Verb POST body Description
/api/movies GET Empty List all movies.
/api/movies POST {'title':'A Movie', 'category':'Science', 'country':'Turkey', year:2013, director:"id", imdb_score: 9.5 } Create a new movie.
/api/movies/:movie_id GET Empty Get a movie.
/api/movies/:movie_id PUT {'name':'normal', 'surname':'user'} Update a movie with new info.
/api/movies/:movie_id DELETE Empty Delete a movie.
/api/movies/top10 GET Empty Get the top 10 movies.
/api/movies/between/:start_year/:end_year GET Empty Movies between two dates.

Directors

Route HTTP Verb POST body Description
/api/directors GET Empty List all directors.
/api/directors POST { name: 'normal', surname:'user', bio:'hey there' } Create a new director.
/api/directors/:director_id GET Empty Get a director.
/api/directors/:director_id PUT {'name':'normal', 'surname':'user', 'bio': 'hi everyone'} Update a director with new info.
/api/directors/:director_id DELETE Empty Delete a director.
/api/directors/:director_id/best10movie GET Empty The director's top 10 films.

Index

Route HTTP Verb POST body Description
/register POST { username: 'foo', password:'1234' } Create a new user.
/authenticate POST { username: 'foo', password:'1234' } Generate a token.

Demo

Live demo on Heroku

About

This is the alternative movie API

License:Apache License 2.0


Languages

Language:JavaScript 97.6%Language:Pug 1.8%Language:CSS 0.6%