Giter Site home page Giter Site logo

sophan-developer / generic-discord-music-bot Goto Github PK

View Code? Open in Web Editor NEW

This project forked from seraphinush/generic-discord-music-bot

0.0 0.0 0.0 155 KB

Discord music bot developed using discord.js library

License: MIT License

JavaScript 100.00%

generic-discord-music-bot's Introduction

generic-discord-music-bot

Discord music bot developed using discord.js library

Website

Prerequisite

  • Discord server
  • MongoDB cluster
  • Node.js, used v14.0.0, @discordjs/opus requires Node.js 12.0.0 or newer

Setup

Create .env file in base folder Input Discord bot command prefix in .env file Input Discord Bot Token in .env file Input MongoDB URI in .env file

Example :

PREFIX = .
DISCORD_TOKEN = DISCORD.BOT.TOKEN-AT-DISCORDS-DEVELOPER-PORTAL
ATLAS_URI = mongodb+srv://admin:<PASSWORD>@<CLUSTER_NAME>.eikyh.mongodb.net/<DB_NAME>?retryWrites=true&w=majority

Note : Make sure to whitelist your IP of bot instance in MongoDB Install dependencies

npm install

Run application

node index.js

Usage

- join, on : join voice channel
- leave, off : leave voice channel
- play, p <URL | search term> : play music or add music to queue
- playnext <URL | search term> : play music or add music to the top of queue
- stop : stop music
- pause : pause music
- resume : resume music
- skip : skip to next music in queue if queue exists
- remove, rm <Number> : remove music in queue at index if queue exists
- clear : clear music in queue
- repeat <none | one | all> : disable repeat music | repeat current music | repeat all music in order of queue
- shuffle : shuffle music in queue if queue exists
- volume <Number> : adjust volume of voice activity between 0 and 100. does not adjust the user-designated volume of the client itself
- save : save current song list to an online database
- load : load song list from an online database to queue. automatically plays if there is no voice activity

Permissions used

Text Permissions ::
SEND_MESSAGES
MANAGE_MESSAGES
ADD_REACTIONS

Voice Permissions ::
VIEW_CHANNEL
CONNECT
SPEAK
USE_VAD

Limitations

  • Currently only supports Youtube search or URL

Built with

  • discord.js
  • @discordjs/opus
  • dotenv
  • ffmpeg-static
  • mongoose
  • node-ytdl-core
  • yt-search

License

Copyright 2021 - present Seraphinus Hong

Released under the MIT License

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.