Netflix Backend

This is the backend for the Netflix Clone project. Using this API, you can create, read, update and delete movies and series. You can also create, read, update and delete users. The API is built with Node.js, Express.js and MongoDB.

App Repository

https://github.com/rayrama/netflix-clone

Tech Stack

Dashboard: React, TailwindCSS

API: Node, Express, MongoDB

You can check the package.json files for more information in each folder.

Folder Structure

.
├── README.md (This page)
├── api # API
|  ├── controllers # Controllers for all logic crud operations
|  |  ├── AuthController # Controller for login and register
|  |  ├── EpisodeController # Controller for episode crud operations
|  |  ├── ListController # Controller for list crud operations
|  |  ├── MovieController # Controller for movie crud operations
|  |  ├── TVShowController # Controller for series or tvshow crud operations
|  |  ├── UserController # Controller for user crud operations
|  ├── models # Models for all schemas
|  ├── routes # Routes for all crud operations
├── dashboard # Client
|  ├── public # Public
|  ├── src # Source
|  |  ├── components # Components
|  |  ├── pages # Pages

Installation

For the api folder:
cd api && yarn

For the dashboard folder:
cd dashboard && yarn

Before running the app, you need to create a .env file in the api folder with the following variables:

MONGO_URL=your_mongo_url
SECRET_KEY=your_secret

For MONGO_URL, you can use a local mongo database or a cloud database like MongoDB Atlas. Register here to get a free account.

For SECRET_KEY, you can use any string you want. I recommend you to use a random string generator like this or this.

Running the app

You shold run the api firstly and then the dashboard.

For the api folder:
yarn start

For the dashboard folder:
yarn start

API Documentation

You can check the API documentation here.

OR

Download this file and import it to Postman to get the API collection.