A custom discord bot that can play music in your server
If you are looking for a music bot for your Discord server then go ahead and invite it from here. Visit the website musx.me for more details about the bot. Heroku has been used for hosting the bot online.
NOTE: I had to shut down my bot because it was consuming my Heroku dynos, but you can still use this code to host your own bot.
Basic commands:
ping
help
author
Music commands:
play [song name/ song Youtube URL]
pause
resume
stop
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
You'll need Git and Node.js (which comes with npm) installed on your computer. Apart from this you will need to have a discord account and a server where you are admin. If you don't have any such server then you can simply create a new one for yourself. Finally you will need a discord bot to which you can link this code. You can create one for yourself from the Discord Developer Console.
node@v16.6.0 or higher
npm@8.5.0 or higher
git@2.25.1 or higher
From your command line, first clone and then configure the neccessary files and start the server.
# Clone this repository
$ git clone https://github.com/Shashwat545/Musx.git
# Go into the repository
$ cd Musx
# Install dependencies
$ npm install
# Rename .env_sample to .env and put your discord bot token inside it
#After that we start the server
$ node index.js
- discord.js
- discord-player
- ffmpeg
- ytdl-core
- SpinKit for bot website preloader
- ms
- dotenv for loading bot token as an environment variable
This project is licensed under the GPL-3.0 License - see the LICENSE.md file for details
If you want to contribute and make this much better for users, please have a look at the structure of the project and style of code to understand the working of the bot properly.
If you can help me with these. Please don't hesitate to open a pull request.
- Add a search command for song, after which user can select which one to play
- Add a skip command to skip the currently playing song in queue
If you created something awesome and want to contribute then feel free to open a pull request.
Designed & Developed with ❤️ by Shashwat Singh