Skip to content

Sepehr-Aghdasi/taskly-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

121 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

NestJS Logo

Taskly Bot ๐Ÿค–

A Telegram bot built with NestJS to help you manage tasks, track focus time, and receive smart reminders.


๐Ÿš€ Overview

Taskly Bot is a productivity-focused Telegram bot that helps users:

  • Manage daily tasks
  • Track working sessions
  • Receive focus / break / half-time notifications
  • View daily activity reports
  • Control reminders through user settings

The bot is built with a modular NestJS structure and uses config-driven scheduling for time-based notifications.


โœจ Features

๐Ÿ“ Task Management

  • Add, edit, and delete tasks
  • Start and end task sessions
  • Prevent multiple active tasks at the same time
  • Friendly inline/clickable buttons for all interactions

โฑ Time Tracking

  • Track working sessions per task
  • Automatically calculate duration
  • Automatically forceโ€‘closes sessions at the end of the day

๐Ÿ“Š Reports

  • Daily task report
  • Session breakdown per task
  • Total working time per day

๐Ÿ”” Smart Notifications

  • Daily reminders
  • Focus / Break / Half-time alerts (configurable)
  • User-controlled settings (on/off)

โš™๏ธ User Settings

  • Enable / disable reminders
  • Enable / disable focus alerts
  • Set preferred language (Persian ๐Ÿ‡ฎ๐Ÿ‡ท or English ๐Ÿ‡ฌ๐Ÿ‡ง)
  • Language changes reflected instantly thanks to internal caching
  • Designed for future extensibility

๐ŸŒ Multilingual Support

  • Full Persian & English translations
  • Automatic loading + caching of user language
  • New default behavior:
    • Existing users default to Persian
    • New users default to English

๐Ÿง  Focus & Time Blocks

Taskly supports automatic time-block notifications such as:

  • ๐ŸŽฏ Focus Time
  • โ˜• Break Time
  • ๐Ÿฝ๏ธ Half Time

Defined using a JSON configuration file and scheduled automatically.

Example:

[
  {
    "type": "Focus",
    "startTime": "08:00:00",
    "endTime": "09:00:00"
  },
  {
    "type": "Break",
    "startTime": "09:00:00",
    "endTime": "09:15:00"
  }
]

๐Ÿ›  Tech Stack

  • NestJS
  • Telegram Bot API
  • Prisma ORM
  • PostgreSQL
  • node-cron
  • TypeScript

๐Ÿงช Installation & Setup

1๏ธโƒฃ Clone the repository

git clone https://github.com/Sepehr-Aghdasi/taskly-bot.git
cd taskly-bot

2๏ธโƒฃ Install dependencies

npm install

3๏ธโƒฃ Environment variables

Create a .env file:

DATABASE_URL=postgresql://user:password@localhost:5432/taskly
TELEGRAM_TOKEN=your_telegram_bot_token

4๏ธโƒฃ Database setup

npx prisma generate
npx prisma migrate dev --name init

Optional: GUI to view database content

npx prisma studio

โ–ถ๏ธ Running the Bot

npm run start:dev

Production

npm run build
npm run start:prod

๐Ÿค– Bot Behavior

  • /start initializes the user
  • Button-based interactions for:
    • Task creation
    • Task list
    • Daily report
    • Settings
  • All interactions are handled through inline keyboard buttons

๐Ÿ“Ž Project Links


๐Ÿค Contributing

Pull requests are welcome. Please keep commits clean and focused.

Built with โค๏ธ using NestJS

About

Telegram bot to track tasks ๐Ÿš€

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors