Skip to content

YanParoni/backend-portfolio

Repository files navigation

Playboxd Backend Documentation

Welcome to the Playboxd backend documentation. This document provides an overview of the API endpoints, authentication mechanisms, environment variables, and instructions on how to set up and run the project.

Table of Contents

Introduction

This is a portfolio project to showcase what I learned as a fullstack developer, is part of a larger application that includes a frontend built with Next.js. Inspired by letterboxd

Getting Started

Prerequisites

  • Node.js (version 18.0 or later)
  • MongoDB Community version (version 7.0 or later)
  • Yarn or npm

Installation

  1. Fork the repo

  2. Install dependencies:

    yarn install or npm install
    
  3. Create a .env file in the root directory and configure your environment variables as described in the Environment Variables section.

  4. Start the development server:

    yarn start or  npm run start
    
  5. Open your browser and navigate to http://localhost:3000/api to access the Swagger API documentation.

Environment Variables

The following environment variables need to be configured in your .env file:

NODE_ENV=development
DATABASE_URI=mongodb://localhost:27017/Games
GOOGLE_CLIENT_ID=your-google-client-id
GOOGLE_CLIENT_SECRET=google-client-secret
GOOGLE_CALLBACK_URL=http://localhost:3000/auth/google/callback
JWT_SECRET=any encryption
RAWG_API_KEY= can be obtained at https://rawg.io/apidocs
AWS_ACCESS_KEY_ID=aws-access-key
AWS_SECRET_ACCESS_KEY=aws-secret
AWS_REGION=us-east-2
S3_BUCKET_NAME=your bucket
FRONTEND=http://localhost:3001

API Documentation

NestJS with Swagger makes it easy to document your API. Swagger can be accessed at http://localhost:3000/api.

Currently there only user auth and game interactions modules are properly documented

Running Tests

The project includes at the moment only unit tests.

To run the unit tests: yarn test or npm run test

Deployment

This project was deployed at aws ec2, there are a couple of secrets that you will need for more information go to appleboy-ssh

Contact

Hit me at:

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages