How to add a music bot in Discord

in #howto7 years ago (edited)

cyber-2062846_1920.jpg

Discord is a text and voice communication application (VoIP application) specially designed for players. There is no cost to use it. It is freeware, and has many interesting features such as encrypted communication from server to client, DDoS protection, and availability for use on Windows, macOS, Android, iOS, Linux, and cloud systems, among others.

In this post I will show you how to easily set up a bot to create radio in your chat room in discord.

The only requirement is to have python version 3.5 or higher installed. video tutorial to install on Windows 10

Step 1 - Create an account and create a server

If we want to create a server first we must go to https://discordapp.com/login and create an account in a very simple way. We enter an email address, a username, a password and confirm the account in our email.

1.PNG

Once we have confirmed our account, we log in and click on the button with a circle and a + sign inside, and then we will indicate the region in which our server is located and we will give it a name.

2.PNG

3.PNG

4.PNG

Step 2 - Create a bot account

In order to use a bot in discord we have to create an account for him.

Go to https://discordapp.com/developers/applications/me and click on New application.

Afterwards, we give a name to our bot and put an icon on it.

5.PNG

Now, we click on create and a successful creation screen will appear.
6.PNG

Within the same screen, click on create bot user and if the name is not already registered, the creation will be successful.

7.PNG

Step 3 - add the bot to the server

Since we have created the bot account it is time to add it to our server. To do this, we will go to our app and copy the client ID.

10.PNG

We will then copy and paste the following URL into our browser

https://discordapp.com/oauth2/authorize?&client_id=<CLIENT ID>&scope=bot&permissions=0

Replacing the CLIENT ID part with the Client ID of our app.

Then we will be asked to select which server to add our bot to. We choose the right one and then we give the authorization.

8.PNG

To verify that the bot has been successfully added, we log in to our server and see it added on the right side.

9.PNG

Step 4 - bring our bot to life

At this point, our bot inside the server appears offline. It's time to get it up and running with the necessary programs and settings. To do this, we will download the following open source repository to our computer.

https://github.com/Just-Some-Bots/MusicBot

Click on the green button "download".

We unzip the file and in our Musicbot-master folder we open the config subfolder to copy and paste the example_options. ini file. This copy will be renamed as option. ini.

23.PNG

Using a code editor, this can be notepad, we open the file we renamed.

11.PNG

In the Credentials section, in Token we'll put our bot's one. To copy and paste it we open the following URL:

https://discordapp.com/developers/applications/me

We click on the application we had created and in the App bot user section, click on reveal token and copy that string to later paste it into Credentials -> Token in our file.

13.PNG

14.PNG

Finally, before giving life to our bot, we will set the ID of the person who controls the bot. We go to our server, click on user settings in the lower left hand corner, and in appearance, we will activate the developer mode.

15.PNG

Then we return to our server and on the right side, right click on our user, and then click on Copy ID. This ID, which has just been copied, will be pasted into the part of our file called Permissions.

17.PNG

Now we go back to our Music-bot master folder and without entering any subfolders we will find the file
runbot. bat, which we'll double-click to launch our bot, i. e. to bring it to life!

25.PNG

It may take a while to start, but if we follow the instructions correctly, we'll get an output on the command line like this:

19.PNG

And on our server the bot will already appear online.

20.PNG

Step 5 - Using the bot

On our server we have voice channels, to which by clicking on them we can add ourselves. If we want our bot to transmit the music on one of our channels, first we have to click, and then in general conversation or some other channel write the following command.

!summon

20.PNG

The bot should now appear on the voice channel where we are.

21.PNG

By default, in our Music-bot master folder, config, there is a .txt file called autoplaylist in which we can add youtube links of the songs that we want to play in automatic. Then as we bring our bot to life, we'll hear these songs first.

If we want to add them right away, we clean that file and leave it blank. And on our server in some conversation channel, we added the following command:

!play <song link>

replacing song link with the link of the song we want to put.

22.PNG

Commands to use the bot

In order to explore more functionalities to use this bot, you can visit this site and use the commands that interest you.

https://github.com/Just-Some-Bots/MusicBot/wiki/Commands

I hope this post help you if you want to start sharing music in your discord server!

Let me know your thoughts in the comments section.

coollogo_com-149121399.png

Sort:  

work very well
I love it and love to follow you
vest plz follow me @mudatnad and give me want value from esteem.t
thank you

Wooow, that is damn cool. Great and detailed post. Thanks for your work

nice music

When I saw the title , I was like "what's the point of making a article about using ayana or other predone bot" now that I read it, I have to say "Thanks you !"

good job...thanks for share...
leave a message and an impression ... do not you hold a love to someone because it will kill you ... drifting in solitude for too long ... and difficult to love others .... move on steemian love .. greated @ academix87
https://steemit.com/dsound/@academix87/hidden-love-cinta-terpendam-created-bye-academix87-voc-arr-de-anthony

@fintechresearch Awesome posts sir... I thoroughly concur along with you. Adore it..

Coin Marketplace

STEEM 0.16
TRX 0.13
JST 0.027
BTC 59200.90
ETH 2601.74
USDT 1.00
SBD 2.41