Skip to content

koskelainen/task_manager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 

Repository files navigation

Task Manager (Microservices)

Stack

  • Python/Java/Scala
  • Postgres
  • API Gateway
  • File server
  • Docker & Docker-Compose

Requirements

  • Installed Docker
  • Installed depend libs

CLI Tools

  • make help to see all available instructions
  • make run to build & run project
  • make db-init to init db for services

Build & Run Project

  • Run make run in terminal window
  • If you are running project locally for the first time, open new window and run make run && make db-init

TODO like ⭐⭐⭐

  • Logging & Tracing

Endpoints

POST /user/sign-up

Create New User

Example Input:

{
  "first_name": "Kirk",
  "last_name": "Brian",
  "username": "brian-k",
  "password": "mypassword1"
}

Example Response:

{
  "id": 1
}

GET /user/token

Generate JWT Token

Example Input:

{
  "username": "brian-k",
  "password": "mypassword1"
}

Example Response:

{
  "access_token": "8vZ2F0ZXdheTo4MDgwI<...>"
}

GET /user/profile

Return User Info

HTTP Headers:

Authorization: Bearer <access_token>

Example Response:

{
  "id": 1,
  "first_name": "Kirk",
  "last_name": "Brian",
  "username": "brian-k",
  "password": "mypassword1"
}

POST /tasks

Create New Task

HTTP Headers:

Authorization: Bearer <access_token>

Example Input:

{
  "title": "Task 1"
}

Example Response:

{
  "id": 1
}

GET /tasks

Get All Tasks

HTTP Headers:

Authorization: Bearer <access_token>

Example Response:

{
  "tasks": [
    {
      "id": 1,
      "title": "Task 1",
      "created_at": "2022-10-03T016:19:46.674946Z",
      "user_id": 1
    }
  ]
}

GET /tasks/1

Get Task By Id

HTTP Headers:

Authorization: Bearer <access_token>

Example Response:

{
  "id": 1,
  "title": "Task 1",
  "created_at": "2022-10-03T016:19:46.674946Z",
  "user_id": 1
}

About

Task Manager

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published