Most of this bot is based off the YouTube API.
search - Returns the top 5 results from YouTube search.
play - Plays the first song in the queue, a specific song in the queue, or a song given a YouTube video URL.
example: !play
2nd example: !play https://www.youtube.com/watch?v=Ww9S7YWD-Ew
3rd example: !play 2
pause - Pauses current song
example: !pause
resume - Resumes current song
example: !resume
add - Adds a song to the queue, given a YouTube video url.
example: !add https://www.youtube.com/watch?v=Ww9S7YWD-Ew
stop - Stops the Discord bot, and makes the bot leave the channel.
example: !stop
queue - Lists the current song queue for the Discord bot
example: !queue
volume - Sets the volume of the Discord bot, out of 100. (default is 5)
example: !volume
help - Posts the commands to use this bot in the Discord chat.
example: !help
clear - Clears all messages for a channel
example: !clear
For this project you will need NodeJS 8.0.0 or newer.
Once you have node installed do the following:
Since this project uses node-opus to handle audio, you will need to install windows-build-tools
Run this command to install it: npm install --global windows-build-tools
Once that's done, clone or download this repo, open the directory with 'package.json' in it and run npm install
.
Now that the bot has all the dependencies installed, you can run:
npm run start
or if you use yarn package manager:
yarn start
If you run into any issues feel free to leave a message on this repo, or email me at malik@malikbrowne.com