2.3 KiB
2.3 KiB
Thoughtful Discord Bot
This project is a Discord bot that integrates with your Thoughtful instance, allowing users to create, list, and delete ideas directly from Discord using slash commands and simple text commands.
✨ Features
- Setup: Configure your Thoughtful instance URL and API key using
/setup. - Create Ideas: Use
.thought Title; Descriptionin any channel to create a new idea. - List Ideas: Use
/listto view all your ideas. - Delete Ideas: Use
/deletewith autocomplete to remove an idea by title. - Logout: Use
/logoutto remove your stored credentials.
🚀 Quick Deployment
You can deploy this bot easily using Docker Compose. Follow these steps:
1. Clone the Repository
git clone https://github.com/yourusername/thoughtful-dcbob.git
cd thoughtful-dcbob
Or, if updating an existing deployment:
git pull
2. Set Up Environment Variables
Create a .env file in the project root with your Discord bot token:
DISCORD_BOT_TOKEN=your_discord_bot_token_here
# Optional: Set Kuma monitoring variables:
# KUMA_PUSH_URL=https://your-uptime-kuma-instance.com/api/push/
# KUMA_PUSH_INTERVAL=60
3. Run with Docker Compose
A sample docker-compose.yml is provided. Start the bot with:
docker compose up -d
This will build and run the bot in the background.
🤖 Usage
- Invite your bot to your Discord server.
- Run
/setupto configure your Thoughtful instance (URL and API key). - Create ideas by typing
.thought Title; Descriptionin any channel. - List ideas with
/list. - Delete ideas with
/delete(autocomplete helps you find the right idea). - Logout with
/logout.
🔧 Configuration Storage
User configuration (instance URL and API key) is stored in users.json in the project directory. This file is managed automatically by the bot.
⚠️ Intents ⚠️
The bot requires the following Discord intents:
- Message Content Intent
🤔 Troubleshooting
- Make sure your Discord bot token is correct and set in the environment.
- Ensure your Thoughtful instance is reachable from the bot.
- For any issues, check the logs with:
docker compose logs
Contributing
Pull requests and issues are welcome!
Enjoy using Thoughtful Discord Bot!