Skip to content

Robust and feature-rich backend API for a task management application using: Node.js and PostgreSQL & Postman. The API allows users to efficiently manage their tasks, collaborate with others, and stay organized. The design prioritizes functionality, performance and scalability.

License

Notifications You must be signed in to change notification settings

theoneandonlyshadow/Task-Management-API

Repository files navigation

task-management-api

 

Task Management API

Github top language Github language count Repository size License

Please read the installation section


About   |   Features   |   Technologies   |   Requirements   |   Starting   |   License   |   Author


🎯 About

Robust and feature-rich backend API for a task management application with Node.js PostgreSQL & Postman. The API allows users to efficiently manage their tasks, collaborate with others, and stay organized. The design prioritizes functionality, performance, and scalability.

✨ Features

✔️ Set up a Node.js server to handle API requests
✔️ Assignment of Tasks to Users
✔️ Database Migrations/Seeds
✔️ RESTful CRUD Operations
✔️ Error handling and validation.
✔️ Implemented user-specific views for tasks.
✔️ Allow users to mark tasks as completed.

🚀 Technologies

The following tools were used in this project:

✅ Requirements

Before starting 🏁, you need to have Git, Node, Docker & PostgreSQL installed.

Installed NPM Packages

  • pg-pool : collection of database connections that can be reused.
  • Nodemon : nodemon is a tool that helps develop Node.js based applications by automatically restarting the node application when file changes in the directory are detected.
  • Express.js : framework that works on top of Node.js web server functionality to simplify its APIs.

Installed VS Code Extensions

  • PostgreSQL : to connect VS Code to PostgreSQL
  • GitHub : to connect GitHub account from VS Code
  • Docker : simplifed view of containers.
  • Express : Hosts current workspace with Express web server in Visual Studio Code.
  • WSL : Linux-based tools, runtimes, and utilities.

🏁 Starting

# Clone this project
$ git clone https://github.com/theoneandonlyshadow/task-management-api

# Access
$ cd task-management-api

# Install dependencies
$ npm i

# Run the project with nodemon
$ nodemon index

# The server will initialize in the http://localhost:8070

Steps to recreate project

  • Install Docker Desktop

  • Install VS Code

  • Install PostgreSQL

  • Install Postman

  • Create docker-compose.yml file.

  • Copy the same contents from this repo.

  • Open Docker Desktop and start.

  • (PowerShell) Type docker compose up

  • Project container should be visible in the Docker Desktop.

  • Open pgAdmin 4 (PostgreSQL) and create a new database called "techcorp". Dont worry about creating tables, as both users and tasks table will initalize after running index.js.

  • Open VS Code, open Command Palette and type New Query (requires PostgreSQL extension) and type in credentials.

  • (WSL) Type sudo systemctl status postgresql to see if PostgreSQL is active.

  • (WSL) Type psql -U postgres -h localhost or psql -h 127.0.0.1 -p 5432 -U postgres to connect to PostgreSQL.

  • Open Postman and review my project according to the following endpoints:

  • Common Endpoints:

  • -> /displaytables: to display the tables

  • -> /displaydb: to display databases

  • -> /authenticate/{user_id}: authenticate user to see their tasks.

  • User Endpoints:

  • -> /users/create: Create a user (POST)

  • -> /users/display: Read users (display all users) (GET)

  • -> /users/update: Update a user (PUT)

  • -> /users/delete: Delete a user (DELETE)

  • -> /users/authenticate/{user_id}: "authenticate user's user_id to see their tasks. (GET)

  • Task Endpoints

  • -> /tasks/create: Create a task (POST)

  • -> /tasks/display: Read tasks (display all tasks) (GET)

  • -> /tasks/update: Update a task (PUT)

  • -> /tasks/delete: Delete a task (DELETE)

  • -> /tasks/assigntask/{user_id}: Assign Task to a User (POST)

  • -> /tasks/markcomplete: Write "Marked Complete" to a task. "Not Complete" by default when creating a task for a user (PUT).

NOTE

If any feature is not working, please reinstall the tech and try again. If you would like a video of my screen recording about the full project, please let me know at madhavnair700@gmail.com or message me in WellFound.

📝 License

This project is under license from MIT. For more details, see the LICENSE file.

Made with 3am efforts by Madhav Nair

 

Back to top

About

Robust and feature-rich backend API for a task management application using: Node.js and PostgreSQL & Postman. The API allows users to efficiently manage their tasks, collaborate with others, and stay organized. The design prioritizes functionality, performance and scalability.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published