A free and open source Discord bot for moderation purposes. Click here to see the screenshots.
- Strong automoderation system with tools like anti-spam and anti-raid (Click here to see the full list)
- Useful moderation tools and utilities
- Secure
- Fun commands
- Active development & support
You can request an invite for SudoBot here, it's completely free. Alternatively, you can create your own Discord API application and then host SudoBot.
It's not recommended to build and use the code from main
branch, because we're migrating from v4 to v5 with big changes. Some commands/features may not be available or complete, or the bot may not work at all. Therefore use a stable release.
- NodeJS version 16 or higher
- MongoDB version 5.0 or higher (Go to MongoDB Atlas for a free MongoDB cluster)
- A Discord API application token with proper setup
- Cat and dog API Token (for fetching cat and dog images using
cat
anddog
commands, the tokens can be obtained at thecatapi.com and thedogapi.com) - Pixabay API Token (can be obtained here)
- A Discord Webhook URL for sending error reports
- A JWT Secret for the API services (if you don't have an API secret, you can run
openssl rand -base64 10
to generate a random base64 string and use it as secret)
- Download the latest release or clone the repo by running:
git clone https://github.com/onesoft-sudo/sudobot
- Go inside the project directory, and run the following command:
npm install -D
- Open up the
config/config.json
file and change at least the following:
{
"global": {
"id": "set your home guild id",
"owners": ["set owner user ids here"],
...
},
"guild id here": {
"prefix": "-",
"mod_role": "the mod role, users having it will be able to use the bot",
"gen_role": "general role id, which all users have",
"mute_role": "the muted role id",
"admin": "the admin role id. users having it will be immune to sudobot.",
...
}
}
Note: ...
means other options that exist in the config, you can edit them to customize the settings, but not required.
Alternatively, you can try the new
setup.js
installer script [BETA] by runningnode setup.js
. It will ask you some questions about the configuration.
-
Copy the
.env.example
file to.env
and open it, edit the information (such as bot token. MongoDB URI, etc) as needed. -
Build the project:
npm run build
- Deploy slash commands globally:
node deploy-commands.js
- Start the bot:
npm start
And if everything was configured correctly, you should not see an error and the bot should say Logged in as [tag]!
.
Then you can run the following command in Discord to make sure everything is working:
-about
That should show the bot information. Congratulations! You've successfully set up your own instance of SudoBot!
Thanks to all the contributors!
- Email: rakinar2@onesoftnet.eu.org
- Discord Servers: Silly Cats Server, OneSoftNet Server
- Download Emojis: https://www.onesoftnet.eu.org/downloads/sudo/emojis/
Copyright © 2022-2023 OSN and all the contributors of SudoBot.