ZerioDev / Music-bot

A complete code to download for a cool Discord music bot !
https://discord.gg/5cGSYV8ZZj
GNU General Public License v3.0
892 stars 1.09k forks source link
discord discord-bot discord-js ffmpeg music nodejs

Music-bot

A complete code to download for a music bot 🎧

Looking for a code for a music bot? This fully open-source code is made for your project!

If you need help with this project, to get support faster you can join the help server by just clicking here.

If you don't have any development knowledge, it is recommended to join the Discord support server to get help.

⚡ Configuration

Important!!! In order to work you need to rename .env.example to .env

Open the configuration file located in the main folder config.js.

const process = require('process');
module.exports = {
    app: {
        token: process.env.DISCORD_TOKEN || 'xxx',
        playing: 'by the Community ❤️',
        global: true,
        guild: process.env.GUILD_ID || 'xxx',
        extraMessages: false,
        loopMessage: false,
        lang: 'en',
        enableEmojis: false,
    },

    emojis:{
        'back': '⏪',
        'skip': '⏩',
        'ResumePause': '⏯️',
        'savetrack': '💾',
        'volumeUp': '🔊',
        'volumeDown': '🔉',
        'loop': '🔁',
    },

    opt: {
        DJ: {
            enabled: false,
            roleName: '',
            commands: []
        },
        Translate_Timeout: 10000,
        maxVol: 100,
        spotifyBridge: true,
        volume: 75,
        leaveOnEmpty: true,
        leaveOnEmptyCooldown: 30000,
        leaveOnEnd: true,
        leaveOnEndCooldown: 30000,
        discordPlayer: {
            ytdlOptions: {
                quality: 'highestaudio',
                highWaterMark: 1 << 25
            }
        }
    }
};

Basic configuration

DJ mode configuration

Advanced configuration (only change if you know what you are doing)

📑 Installation

To use the project correctly you will need some tools.

WARNING: You MUST use Node.js version v18.20.2, otherwise, you will encounter major compatibility issues.

FFmpeg to process audio ( make sure to download the latest version availble )

Node JS (v18.20.2) for environment

yarn for package management

Without forgetting of course the code editor, we recommend visual studio code

Now in your terminal run the following commands assuming you are in the same directory as the project.

yarn install (or npm install not recommended as it might not work)

node . (or node main.js)

and Done, your bot should be running!

Realized with ❤️ by the Community.

Please do not withdraw the license and keep the credits on this project.

To have full access to the project and to be able to withdraw the credits a small donation is accepted.

❗supported languages:

Code Language Code Language Code Language
af Afrikaans bn Bengali da Danish
sq Albanian bg Bulgarian nl Dutch
ar Arabic ca Catalan en English
hy Armenian hr Croatian et Estonian
eu Basque cs Czech fi Finnish
be Belarusian cy Welsh fr French
bs Bosnian de German ga Irish
ja Japanese jv Javanese ka Georgian
kn Kannada kk Kazakh km Khmer
ko Korean ku Kurdish ky Kyrgyz
la Latin lb Luxembourgish lo Lao
lt Lithuanian lv Latvian mg Malagasy
mi Maori mk Macedonian ml Malayalam
mn Mongolian mr Marathi ms Malay
mt Maltese my Burmese ne Nepali
no Norwegian ny Chichewa pa Punjabi
pl Polish ps Pashto pt Portuguese
ro Romanian ru Russian sd Sindhi
si Sinhalese sk Slovak sl Slovenian
sm Samoan sn Shona so Somali
sq Albanian sr Serbian st Sesotho
su Sundanese sv Swedish sw Swahili
ta Tamil te Telugu th Thai
tr Turkish uk Ukrainian ur Urdu
vi Vietnamese xh Xhosa yi Yiddish
zu Zulu id Indonesian

📝 ToDo