Skip to content

Calendar-API-Backend is a backend built with Node.js, Express and MongoDB, following an architecture based on MCV pattern.

Notifications You must be signed in to change notification settings

Lean-98/Calendar_MERN-Backend

Repository files navigation

📅Calendar-App MERN | API-Backend

Calendar-API-Backend is a backend built with Node.js, Express and MongoDB, following an architecture based on the Model-Controller-View (MCV) pattern. This API uses tools such as bcrypt.js for password encryption, JWT for user authentication and Cors for managing requests between different sources. This backend provides a solid and secure foundation for the Calendar-App application, enabling efficient event and user management. With its MCV-based structure, it offers a clear separation of concerns and optimal scalability. Furthermore, being built with MERN technologies, it ensures a seamless integration with the frontend and a cohesive user experience.

Tech Stack

Node.js, Express, MongoDB Compass, Mongoose, Luxon, bcrypt.js, JWT.io, Cors Architecture: MVC

Installation

Install my-project with npm

  npm install my-project
  cd my-project

Run Locally

Clone the project

  git clone https://link-to-project

Go to the project directory

  cd my-project

Install dependencies

  npm install

Start the server

  npm run dev

Deployment

To deploy this project run

  npm run start

API Reference

Create Event

  POST /api/events
Parameter Type Description
title string Required. Title event
start Date Required. Event Start Date
end Date Required. Event end date

Get all Events for a user

  GET /api/events
Parameter Type Description
x-token string Required. JWT of the logged user

Get event for update

  PUT /api/events${_id}
Parameter Type Description
_id string Required. Id of event to uptate
title string Required. Title event
start Date Required. Event Start Date
end Date Required. Event end date

Get event for delete

  DEL /api/events${_id}
Parameter Type Description
_id string Required. Id of event to delete

Environment Variables

To run this project, you will need to add the following environment variables to your .env file

PORT

DB_CNN

SECRET_JWT_SEED

Authors

About

Calendar-API-Backend is a backend built with Node.js, Express and MongoDB, following an architecture based on MCV pattern.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published