Skip to content

Web app that fetches from The Movie Database API, where users can search for movies, write reviews, make lists, add movies to their lists and share them on social media.

Notifications You must be signed in to change notification settings

DenisIrkhin/09-movie-lists

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

movie-lists

Description

decode final project (Denis, Konrad, Jonathan)

Docs

Goodle doc

Github repository

Backend

Server port: 5050

Libraries

express, MongoClient, MongoDB by mLab,

Cookies

Session id generator to a digit from 10mln to 99,999mln

Name: __sid__ Value: 77003076 Expired: never

Endpoints

tests

get /tests

url: http://localhost:5050/tests method: get body: none

response:

{
    "success": true,
    "tests": [
        {
            "_id": "5c5f76a8bfc646349070c2d4",
            "name": "Forrest",
            "surname": "Gump"
        },
        {
            "_id": "5c66f9311621e129c25ccbfa",
            "name": "Buzz",
            "surname": "Lightyear"
        }
    ]
}
post /tests/add

url: http://localhost:5050/tests/add method: post body:

{
  "name": "Buzz",
  "surname": "Lightyear"
}

response:

{
    "success": true,
    "message": "test added",
    "doc": {
        "n": 1,
        "opTime": {
            "ts": "6658289882600833025",
            "t": 1
        },
        "electionId": "7fffffff0000000000000001",
        "ok": 1,
        "operationTime": "6658289882600833025",
        "$clusterTime": {
            "clusterTime": "6658289882600833025",
            "signature": {
                "hash": "lz4i5xB7ArylNevlRM0zqArcs8s=",
                "keyId": "6656070557034872833"
            }
        }
    }
}

users

get /users

url: http://localhost:5050/users method: get body: none

response:

{
    "success": true,
    "users": [
        {
            "_id": "5c670254552be03f4005fcd2",
            "email": "[email protected]",
            "password": "123"
        }
    ]
}

post /users/signup

url: http://localhost:5050/users/signup method: post body:

{
  "email": "[email protected]",
  "password": "123"
}

response:

Cookie: sid:

{
    "success": true,
    "message": "user added",
    "doc": {
        "n": 1,
        "opTime": {
            "ts": "6658320518602555393",
            "t": 1
        },
        "electionId": "7fffffff0000000000000001",
        "ok": 1,
        "operationTime": "6658320518602555393",
        "$clusterTime": {
            "clusterTime": "6658320518602555393",
            "signature": {
                "hash": "1nTYbjTK4zksxBzm/UmoeO9wlEs=",
                "keyId": "6656070557034872833"
            }
        }
    }
}
post /users/login

url: http://localhost:5050/users/login method: post body:

{
  "email": "[email protected]",
  "password": "123"
}

response:

Cookie: sid:

{
    "success": true,
    "message": "Logged in successfully"
}

lists

Frontend

Dev Client port: 3080

About

Web app that fetches from The Movie Database API, where users can search for movies, write reviews, make lists, add movies to their lists and share them on social media.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •