Skip to content

Daniel-Shwartzman/TaskManagementBot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 

Repository files navigation

About The Project

The Task Management Bot is a serverless application designed to assist in task management. It is deployed using AWS Lambda, API Gateway for endpoint management, CloudWatch Logs for logging, and a webhook for communication.

Key features of this project:

  • Serverless architecture
  • AWS
  • Python

Built With

The project is built with Python, AWS Lambda, AWS API Gateway, AWS CloudWatch Logs:

Python AWS Lambda API Gateway CloudWatch

Getting Started

To get started, follow the steps below:

Requirements

  • Python
  • requests
  • AWS account

Installation

  1. Clone the repository:

    git clone https://github.com/Daniel-Shwartzman/TaskManagementBot.git
    cd TaskManagementBot
  2. Install the required dependencies:

    pip install -r requirements.txt

Setup

AWS Lambda

  1. Open the AWS Lambda Console:

    • Go to the AWS Lambda Console.
  2. Create a Lambda Function:

    • Click the "Create function" button.
  3. Select Author from Scratch:

    • Choose "Author from scratch."
  4. Configure the Basic Information:

  • Function Name: Enter a unique name for your function.
  • Runtime: Choose the runtime for your function (e.g., Python, Node.js).
  • Role: Choose an existing role or create a new one with basic Lambda permissions.
  1. Click "Create Function":
  • After configuring the basic information, click the "Create function" button.

AWS API Gateway

  1. Open the API Gateway Console:
  • Go to the API Gateway Console.
  1. Create a New API:
  • Click the "Create API" button.
  1. Choose "HTTP API":

  2. Configure Your API:

  • Enter a name for your API.
  • Optionally, add a description.
  • Click the "Create API" button.

Webhook

For Windows:

Invoke-RestMethod -Uri "https://api.telegram.org/bot<TOKEN>/setWebhook?url=<Your_API_Invoke_URL>" -Method Post

For Linux:

curl -X POST "https://api.telegram.org/bot<TOKEN>/setWebhook?url=<Your_API_Invoke_URL>"

Deployment Package

  1. Copy bot.py and paste it in Lambda.
  2. Config webhook
  3. Click deploy
  4. Run a test (optinal)

Notes

  1. Make sure the lambda handler is your module name.lamda_handler (ex. bot.lamda_handler)
  2. Make sure you set your API Gateway as HTTP API and POST
  3. Don't forget to config the webhook

Screenshots

Bot's conversation:

Screenshot

Architecture:

Screenshot

About

Task management bot with AWS serverless architecture

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages