NOTE: to copy this readme structure simply click on Raw on the top right of this gist. There you have the content in the basic Markdown syntax used in readme files. Then paste it on a README.md file in your repository and fill the information. Always do this directly from VS code, not from github. DON'T ADD THIS NOTE TO YOUR README. Also make sure to remove any notes from this template.
NOTE - Describe your project in one/two lines.
NOTE - List here all functionalities you wish to add to your proyect later or that you are currently working on
NOTE - List here all technologies used in the project like HTML, CSS, Javascript, Express, React, axios, React Context etc.
User model
{
username: {type: String, required: true, unique: true},
email: {type: String, required: true, unique: true},
password: {type: String, required: true},
favs: [{type: Schema.Types.ObjectId,ref:'Game'}]
}Game model
{
title: {type: String, required: true},
type: {type: String, required: true},
image: {type: String, required: true},
apiId {type: Number, required: true},
status {type: String, enum: ["wishlist", "playing", "finished"]
creator: {type: Schema.Types.ObjectId,ref:'User'},
}| HTTP Method | URL | Request Body | Success status | Error Status | Description |
|---|---|---|---|---|---|
| POST | /auth/signup |
{name, email, password} | 201 | 400 | Registers the user in the Database |
| POST | /auth/login |
{username, password} | 200 | 400 | Validates credentials, creates and sends Token |
| GET | /auth/verify |
200 | 401 | Verifies the user Token | |
| GET | `/post/ | 200 | 400 | Show only general posts , | |
| GET | /post/all/:type |
200 | 400 | Show post by type when auth, | |
| GET | `/post/:userId | 200 | 400 | Show only general posts | |
| POST | /post/:userId |
{author, title, type, content} | 201 | 400 | Creates a new Post Document |
| DELETE | /post/:gameId |
200 | 401 | Deletes Post |