Dragon Bot is a Slack bot designed to provide fun and useful commands. It's built with Python using the Slack Bolt framework.
Type / in your Slack workspace to see available commands:
| Command | Description |
|---|---|
/ping |
Gets the response time of the bot |
/about |
Info about the bot |
/credits |
Credits for the bot |
/help |
Shows all available commands |
/joke |
Get a random joke (optional: neutral, chuck, all) |
/fool |
Get a random April Fools' video |
/quote |
Get a quote (daily or random) |
/rock-paper-scissors |
Play rock paper scissors |
/dadjoke |
Get a random dad joke |
/dog-picture |
Get a random dog picture |
/cat-picture |
Get a random cat picture |
/xkcd-fetch |
Fetch a specific XKCD comic by ID |
/xkcd-random |
Fetch a random XKCD comic |
/xkcd-latest |
Fetch the latest XKCD comic |
/ask-ai |
Ask AI a question |
/ask-ai-personality |
Ask AI with a random personality |
/generate-image |
Generate an image using AI |
git clone https://github.com/DragonSenseiGuy/dragon-bot
cd dragon-botuv sync- Go to api.slack.com/apps and create a new app
- Enable Socket Mode and generate an App-Level Token with
connections:writescope - Add Bot Token Scopes under OAuth & Permissions:
chat:writecommandsfiles:write
- Create slash commands (see table below)
- Install the app to your workspace
| Command | Short Description | Usage Hint |
|---|---|---|
/ping |
Gets the response time of the bot | |
/about |
Info about the bot | |
/credits |
Credits for the bot | |
/help |
Shows all available commands | |
/joke |
Get a random joke | [neutral|chuck|all] |
/fool |
Get a random April Fools' video | |
/quote |
Get a quote | [daily|random] |
/rock-paper-scissors |
Play rock paper scissors | Rock|Paper|Scissors |
/dadjoke |
Get a random dad joke | |
/dog-picture |
Get a random dog picture | |
/cat-picture |
Get a random cat picture | |
/xkcd-fetch |
Fetch a specific XKCD comic | <comic_id> |
/xkcd-random |
Fetch a random XKCD comic | |
/xkcd-latest |
Fetch the latest XKCD comic | |
/ask-ai |
Ask AI a question | <your question> |
/ask-ai-personality |
Ask AI with a random personality | <your question> |
/generate-image |
Generate an image using AI | <prompt> |
Note: Leave "Request URL" blank when using Socket Mode.
SLACK_BOT_TOKEN=xoxb-your-bot-token
SLACK_APP_TOKEN=xapp-your-app-level-token
AI_API_KEY=your-ai-api-key-here
| Variable | Description | Required |
|---|---|---|
SLACK_BOT_TOKEN |
Bot User OAuth Token (starts with xoxb-) |
Yes |
SLACK_APP_TOKEN |
App-Level Token for Socket Mode (starts with xapp-) |
Yes |
AI_API_KEY |
API key for Hack Club AI proxy | No |
uv run app.pyOr use the provided scripts:
./run.sh # Start in background
./stop.sh # Stop the bot- Verify
SLACK_BOT_TOKENstarts withxoxb- - Verify
SLACK_APP_TOKENstarts withxapp-
- Ensure Socket Mode is enabled
- Reinstall the app to your workspace after adding commands
- Add the required scope under OAuth & Permissions
- Reinstall the app after adding scopes
Contributions are welcome! Feel free to open an issue or submit a pull request.