lavamusic
Lavamusic is a Discord music bot that uses Discord.js, Shoukaku, and TypeScript.
Invite Lavamusic
Β·
Report Bug & Request Feature
π₯ Unique Features
- Developed using Typescript and Discord.js v14
- Advanced Music System
- Customizable Prefix
- Powerful Search Engine
- 12 + Music Filters
- Hybrid Command Handling (Slash and Normal Commands)
- Highly Configurable
- User-friendly and Easy to Use
- 24/7 Music Playback
- Playlist commands
- Setup music channel
πΆ Support Sources
π Default Sources:
π Plugin Sources: (Require: LavaLink v4.0.x)
Note: You need to install the plugins to use these sources
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
- (Required Plugin)
To set up a Lavalink server on Windows, Linux, or Replit, Click Here.
Need Help with plugins? Join our Discord Server and ask for help in the #support
channel.
π§ Requirements
Before starting with the installation, you need to have the following:
Optional
- Optional (For MongoDB database)
-
Optional (For PostgreSQL database)
- Optional (For Docker Installation)
- Optional (For Docker Installation)
π Installation from source
- Clone the Lavamusic repository:
git clone https://github.com/appujet/lavamusic.git
- change the directory to Lavamusic
cd lavamusic
- Install the required packages:
npm i
- Set up your environment variables:
Create a .env
file in the root directory of your project with the following variables:
or you can use the .env.example file
TOKEN="." # Your bot token
PREFIX= "!" # Your prefix
OWNER_IDS=["959276033683628122","859640640640640640"] # Your discord id, you can add multiple ids
GUILD_ID= "859640640640640640" # Your server Id if you want to use the for single server
PRODUCTION="true" # true for production
SEARCH_ENGINE= "ytsearch" # ytsearch, scsearch or ytmsearch
MAX_PLAYLIST_SIZE= "100" # Max playlist size
MAX_QUEUE_SIZE= "100" # Max queue size
BOT_STATUS= "online" # Your bot status
BOT_ACTIVITY= "Lavamusic" # Your bot activity
LAVALINK_URL="lavalink:2333" # Your lavalink url
LAVALINK_AUTH="youshallnotpass" # Your lavalink password
LAVALINK_NAME="Blacky" # Your lavalink name
LAVALINK_SECURE= "false" # true for secure lavalink
KEEP_ALIVE= "false" # true for keep alive in https://replit.com
LOG_CHANNEL_ID=""
BOT_ACTIVITY_TYPE=0 # Activity type is a number from 0 to 5 see more here https://discord.com/developers/docs/topics/gateway-events#activity-object-activity-types
CLIENT_ID="." # This is your bot's client ID. If this value is left blank, bots cannot be invited using /invite or /about commands.
Prisma Setup
- generate the prisma client
npx prisma generate
- Run the migrations
npx prisma migrate dev --name init
- Run the bot:
npm start
if your prisma client is not generated then follow the below steps Prisma Setup
- Invite the bot to your server:
Generate an invite link for your bot and invite it to your server using the Discord Developer Portal or using permissions calculator: https://discordapi.com/permissions.html
π Installation using Docker Compose
This section assumes you have Docker and Docker Compose installed and running correctly.
Download the docker-compose.yml file in a seperate folder like lavamusic.
Edit docker-compose.yml and make sure to set the following variables:
your .env file should look like this or you can use the .env.example file
TOKEN="." # Your bot token and remember, don't show everyone your bot token
PREFIX="!" # Your prefix
OWNER_IDS=["859640640640640640","859640640640640640"] # Your discord id, you can add multiple ids
GUILD_ID="859640640640640640" # Your server ID (if you want to use it for a single server)
PRODUCTION="true" # "true" for production
For more information how to fill all the variables go to this page. You do not need to edit anything like the LAVA_LINK_URL, LAVA_LINK_AUTH, LAVA_LINK_NAME, LAVA_LINK_SECURE, DATABASE_URL, and the ports unless you know what youβre doing.
After saving your changes you can open a terminal and go to the same location as the docker-compose.yml file. Then run the following:
docker-compose up -d
The above command will start all your services and your bot should be up and running!
To update, you only have to type the following:
docker-compose up --force-recreate --build -d
image prune -f
You can automate this by using Watchtower. The following should be sufficient:
docker run --detach \
--name watchtower \
--volume /var/run/docker.sock:/var/run/docker.sock \
--restart on-failure \
containrrr/watchtower --cleanup
Do note that the bot will restart itself to update to the latest!
π Useful Links
π Tutorial
A Tutorial has been uploaded on YouTube, Watch it by clicking here
π Contributing
Thank you for your interest in contributing to Lavamusic! Here are some guidelines to follow when contributing:
- Fork the repository and create a new branch for your feature or bug fix.
- Write clean and concise code that follows the established coding style.
- Create detailed and thorough documentation for any new features or changes.
- Write and run tests for your code.
- Submit a pull request with your changes.
Your contribution will be reviewed by the project maintainers, and any necessary feedback or changes will be discussed with you. We appreciate your help in making Lavamusic better!
π License
Distributed under the GPL-3.0 license. See for more information.
β Donate
Do you like this project? Support it by donating
π₯ Contributors
Thanks goes to these wonderful people :