This is an example of lavaclient using discord.js v14
-
- Create an application in the Discord Developer Portal.
-
- Grab the bot token from the "Bot" tab.
-
- Click the
Use this templatebutton
- Click the
-
- Install all dependencies:
yarnornpm install
- Install all dependencies:
-
- Setup lavalink
-
- Make sure you have java 11 or above installed.
-
- Grab a jar from the Lavalink Releases Page
-
- Create an application.yml in the same folder as the Lavalink.jar
-
- Start lavalink using:
java -jar Lavalink.jar
- Start lavalink using:
-
- Rename
.env.exampleto.envand replace the value ofBOT_TOKENto the token from step 2
- Rename
-
- Run the Bot
- production:
yarn start - development:
yarn devoryarn dev --force-syncif you're modifying application commands (updating, creating, deleting, etc...)