Skip to content

Instantly share code, notes, and snippets.

@sajalshres
Created December 8, 2024 04:37
Show Gist options
  • Save sajalshres/f90c2e45847880271fecea6a9b61360c to your computer and use it in GitHub Desktop.
Save sajalshres/f90c2e45847880271fecea6a9b61360c to your computer and use it in GitHub Desktop.
simple-task-management-system

Task Management

Goals:

  • Manage tasks:
    • CRUD - Create Read Update Delete
    • User can authenticate to the API
    • Each Task can have files related to it which is uploaded to S3 Bucket
    • Each task can also have a reminder or due date that can be triggered through SQS/SNS

Sample API: taskly.raunak.com/api

Technical Stack:

  • AWS Lambda
  • API Gateway
  • DynamoDB
  • S3 Bucket
  • SQS Queue
  • Cognito for authentication
  • SNS

Data Design

Users Object

Attributes:

  • ID
  • First Name
  • Last Name
  • Email
  • Gender
  • DOB
  • Height
  • Weight
  • Address
{
    "id": 1,
    "firstName": "Raunak",
    "lastName": "Rajbhandari",
    "email": "[email protected]",
    "gender": "Male",
    "dob": "09/09/1989",
    "height": "6ft",
    "weight": "162lbs",
    "address": "Gainesville, VA"
}

Task Object

Attribute:

  • ID
  • User ID
  • Name
  • Description
  • Files
  • Due Date
  • Created On
  • Updated On
## Single task
{
    "id": 1,
    "userID": 1,
    "name": "Finish Final Project",
    "description": "AWS Project",
    "files": null,
    "dueDate": "12/09/2024",
    "createOn": "11/01/2024:101010PM",
    "updatedOn": "11/05/2024:101010PM",
}
## Multiple  task
[
    {
        "id": 1,
        "userID": 1,
        "name": "Finish Final Project",
        "description": "AWS Project",
        "files": null,
        "dueDate": "12/09/2024",
        "createOn": "11/01/2024:101010PM",
        "updatedOn": "11/05/2024:101010PM",
    },
    {
        "id": 2,
        "userID": 1,
        "name": "Call mom",
        "description": "reminder to pickup",
        "files": null,
        "dueDate": "12/09/2024",
        "createOn": "11/01/2024:101010PM",
        "updatedOn": "11/05/2024:101010PM",
    }
]

Implementation

Endpoints

Impelemantation Strategy:

  • First create an initial lambda function and return a dummy data
  • Create DYNAMO DB and add data
  • Update lambda function to connect to DynamoDB and return the data
  • Update the lambda function to CRUD data in DynamoDB
  • Create API gateway and configure lambda function
  • Configure lambda function to implement uploading to s3 bucket
  • Impelemnt SQS and SNS to send notification to user
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment