A simple music bot, which plays the songs requested by user on Discord.
It uses ~
as it default prefix. So you can send a command on Discord, using the default prefix.
To play a song, type
~play <song name>
on discord, to play a song.
It has various commands like: ~play
,~pause
,~resume
,~skip
,~nowPlaying
,~disconnect
,~queue
, ~remove
.etc
You can find more about them using help command on Discord.
There are 2 ways to host in on your machine
- Host via Docker
If you have Docker on your machine, you need to pull the image and run it
docker run --env-file .env reputation22/music-bot
To run the image, it requires a .env
file, which has API secrets, like DISCORD_TOKEN
and YOUTUBE_KEY
.
- Host it Locally
To host it locally on your machine,
Install NodeJs
Clone this repository
git clone git@github.com:varun-s22/yAmB.git
Create a .env
file, on the root directory. It should look something like this
DISCORD_TOKEN = < your Discord Token >
YOUTUBE_KEY = < your Youtube API key >
You can get the DISCORD_TOKEN
, by going to Discord Developer Section, or follow the guide here
For YOUTUBE_KEY
, you can get the API key from here
After setting up the .env
file.
Run
npm install
to get the required dependencies.
Now that you've got your dependencies, run the app.js
file by
node app.js
to start the bot on your local machine.
NOTE: If you face any error, while installing the dependencies, feel free to contact me.