Before we get started, you will need a few things if you don't have them already:
- Python 3 installed.
- pip (package installer) installed.
- A Discord account.
- A Discord server with "Manager Server" permissions.
Before running the bot, ensure you have Python installed (preferably Python 3.8+). Then, install the required dependencies:
python3 -m pip install -r requirements.txt
If you don’t have a requirements.txt
file, create one and add the following content:
discord
requests
python-dotenv
To run your bot, you need a Discord Bot Token. You can obtain one by following these steps:
- Go to the Discord Developer Portal
- Click "New Application"
- Navigate to "Bot" → "Add Bot"
- Click "Reset Token" to generate a new token
- Copy the token and DO NOT share it with anyone
To keep your bot token secure, store it in a .env
file instead of hardcoding it.
- In the bot's main directory, create a file named
.env
- Open the file and add the following content:
DISCORD_TOKEN=your_bot_token_here
Example (.env
file):
DISCORD_TOKEN=your_bot_token_here
Once everything is set up, start your bot with:
python3 bot.py
- If your bot isn’t responding to slash commands, re-add it to your server with the correct permissions via the OAuth2 URL Generator.
Your bot should now be up and running!
Feel free to submit issues or pull requests.
This project is licensed under the MIT License.