A multi-purpose discord bot, with an expansive selection of commands.
Note
The instance of this bot, that I host, is not available in any servers beyond the support server and a friend's. This is because it has very limited functionality at the moment.
| Command | Description |
|---|---|
| /watchlist {show/remove/add} {streamer_name} | Allows for the managing of the Twitch streamer list for to LIVE alerts - the streamer name is only needed when adding or removing and must be as is shown in their link e.g. https://twitch.tv/{streamer_name}. |
| /setlivechannel {channel} | Allows for the changing of the channel the bot sends notifications in. The channel must be input using discord's in-built channel handling e.g. #{channel} |
| /setlivemessage {message} {@Role} | Allows for the creation of custom messages for stream notifications. The role must be added using the discord in-built role handling e.g. @{role} |
| Command | Description |
|---|---|
| /alert | pings a member of the servers staff team to the channel it is used in, annonymously for non-staff members |
| Command | Description |
|---|---|
| /help | Displays the help menu - contains a list of commands. |
| /runtime | Shows how long the bot has been online. |
| /shutdown {reason} | Shuts the bot down displaying a message to the bot log. |
| /suggestion {suggestion} | This command allows for the user to send a suggestion for update to the bot. (it is suggested that you keep the channel id for this the same as usual if you are deploying it on your own - so that suggestions might reach me and be added) |
| Command | Description |
|---|---|
| !play {song name} | plays the selected song as long as the user is in a voice chat |
| !skip | skips current song |
| !queue | displays the current song queue |
| !stop | stops the bot from playing |
| !pause | pauses the current song |
| !resume | resumes the current song when paused |
| Requirement | Version |
|---|---|
| discord.py | >v2.5.0 |
| requests | >v2.31.0 |
| typing | >v3.7.4.3 |
Having a twitch developer account with 2FA enabled.
Having a discord developer account with 2FA enabled.
- Go to the Discord Developer Portal and
login. - Click on
New Applicationin the upper-right hand side of your screen, under your profile picture. - Name your application, accept the Discord Developer Terms of Service and Developer Policy and click
Create. - Now navigate to
OAuth2in the sidebar and scroll toOAuth2 URL Generator. - Select
botas your scope and then set your bot's permissions, copy the Generated Url and save it in a safe place. - Next navigate to
Boton the sidebar and scroll toPrivileged Gateway Intentsand checkPresence Intent,Server Member IntentandMessage Content Intent - Save all your changes as they come.
Caution
Never share your discord bot token, it can be used to control your bot!!!
-
Ensure you have Python
v3.11or greater installed and ensure that the following are installed:- discord.py
- requests
- asyncio
- typing
- ffmpeg
- yt_dlp
-
In the root directory create a
.envfile. inside the.envfile you will have a constant calledELYSIUM_TOKEN. Grab your Bot Token from the Discord Developer Portal and put it into your.envfile like so:.env ELYSIAN_TOKEN="KUFHSDIUHKUh-UHLIUkudshliughj89w3eyr" -
Edit the
main.pyfile's constants, you'll need to change thepublic_logandprivate_logto the discord channel ids in which you want bot info such as, turning on and off to be displayed.Set the
dev_idto the discord user id of yourself or the person managing the bot.Finally, change
twcord_useridto the discord user id of the person that will have control over the bot's twitch notification commands.When your done it should look like so:
# Constants # public_log = 1234227629557547029 # Change to you public bot log channel ID private_log = 1234227628924207283 # Change to you private bot log channel ID dev_id = 876876129368150018 # If you are hosting this bot, change this to your Discord UserID twcord_userid = ( 972663150455451689 # The ID of the person handling the bot's Twitch notifications. )
Note
Check out this guide by Partymann2000.
- Go to the Twitch Developer Portal and
login. - Click on
Your Console, should be located in the top-right in the navbar. - Navigate to
Applicationsand clickRegister your application. - Name your application (Cannot contain the work Twitch).
- Set the
OAuth Redirect URLfield tohttps://localhost/. - Set the
Catagoryto Other and complete the Captcha and clickCreate. - Now click on
Manageon your application. - Grab you
clientIDandclientSecretand put them in yourconfig.jsonfile.
Caution
Never share your ClientID or ClientSecret!!!
config.json
{
"twitch": {
"client_id": "clientID",
"client_secret": "clientSecret",
"access_token": "xxx",
"channel_id": 6523487523834,
"expire_date": 1669483138,
"watchlist": [
"streamer1",
"streamer2",
"streamer3"
]
}
}- Don't forget to rename
config_template.jsontoconfig.jsononce its been populated. - Set the
channel_idto the discord channel you want the bot to send the message in - Populate your
watchlistwith the streamers you want to recieve notifications for.
To get support for the Elysium discord bot, feel free to :
- Open an issue on Github
- Join the discord server
- Or to visit my website
This repository is listed under the MIT License
To contribute to this project please read our contributing guidelines