Radio stations

NPM Version

Warning

Please note that this library is provided with the assumption that you are the legal owner or operator of a radio station or have the proper authorization to use it. We do not assume any responsibility for any misuse of this library, including but not limited to violations of copyright laws. Users are solely responsible for ensuring that their use of the library complies with all applicable laws and regulations, including intellectual property rights.

Important

It is inportant to note that this requires Node version 18 or above

Needed permissions:

VoiceStates, message

Assuming you done all the steps here. You are ready to get started with your fresh new bot.

Link the library

Assuming the library is in BB-DBotBits:

JavaScript
const { discordRadio } = require('./node_modules/bb-dbotbits/discordRadio.js');

Using radio stations

To use the radio station first include the library then call it using 3 arguments:

Arguments
wakeword strealUrl stationimage
Example
discordRadio('stationName', 'https://yoururlstream.mp3', 'stationsImage');

We will use Heart as an example (Please do not use this as we have no assosiation with Heart radio at all. This is for demo purposes ONLY):

Heart example
const { discordRadio } = require('./node_modules/bb-dbotbits/discordRadio.js');

discordRadio('heart',
'https://icecast.thisisdax.com/HeartLondonMP3',
'https://www.globalplayer.com/assets/track-placeholders/heart.jpg');

or for better readability you could layout like this

Readable layout
discordRadio('heartlondon',
'https://icecast.thisisdax.com/HeartLondonMP3',
'https://www.globalplayer.com/assets/track-placeholders/heart.jpg');

Once you have completed all the steps. In our example the command to call the bot into a voice channel is /heart

Reminder
discordRadio('heartlondon' ....);

Next up: Spam Rate