A Discord bot for task management with inspirational quotes and reminders. Built to run on Replit with persistent storage using Replit's database.
- Task Management: Add, delete, edit, and list tasks
- Inspirational Quotes: Get random inspirational quotes from ZenQuotes API
- Reminders: Set timed reminders with notifications
- Bot Control: Toggle bot responses on/off
- Persistent Storage: Tasks are saved using Replit's database
Command | Description | Usage |
---|---|---|
!hello |
Say 'Hi' to the bot | !hello |
!inspire |
Get an inspirational quote | !inspire |
!new |
Add a new task | !new Buy groceries |
!tasks |
List all current tasks | !tasks |
!del |
Delete a task by number | !del 1 |
!edit |
Edit a specific task | !edit 1 Updated task description |
!remind |
Set a reminder (in hours) | !remind 2 Take a break |
!responding |
Toggle bot responses | !responding true or !responding false |
!commands |
Show all available commands | !commands |
- A Discord Bot Token
- A Replit account
- Go to the Discord Developer Portal
- Click "New Application" and give it a name
- Go to the "Bot" section and click "Add Bot"
- Copy the bot token (keep it secret!)
- Under "Privileged Gateway Intents", enable "Message Content Intent"
- In the Discord Developer Portal, go to "OAuth2" > "URL Generator"
- Select "bot" under Scopes
- Select "Send Messages" and "Read Message History" under Bot Permissions
- Use the generated URL to invite the bot to your server
- Fork/Import this repository to Replit
- In your Replit project, go to the "Secrets" tab (lock icon)
- Add a new secret:
- Key:
TOKEN
- Value: Your Discord bot token
- Key:
- Install the required dependencies by running:
pip install discord.py requests
- Create a
keep_alive.py
file (for 24/7 hosting):from flask import Flask from threading import Thread app = Flask('') @app.route('/') def home(): return "Bot is alive!" def run(): app.run(host='0.0.0.0', port=8080) def keep_alive(): t = Thread(target=run) t.start()
- Run the bot by clicking the "Run" button
- Copy your Replit project URL
- Use a service like UptimeRobot to ping your bot every 5 minutes
- This prevents Replit from putting your bot to sleep
# Add some tasks
!new Complete project documentation
!new Review pull requests
!new Prepare for meeting
# View all tasks
!tasks
# Edit a task
!edit 2 Review and merge pull requests
# Set a reminder
!remind 1 Stand-up meeting in 1 hour
# Delete a completed task
!del 1
# Get motivation
!inspire
discord-task-bot/
├── main.py # Main bot code
├── keep_alive.py # Web server for 24/7 hosting
├── README.md # This file
└── LICENSE # MIT License
discord.py
- Discord API wrapperrequests
- HTTP library for API callsreplit
- Replit database integrationflask
- Web server for keep-alive functionality
This project is licensed under the MIT License - see the LICENSE file for details.