Skip to content

Sachanime/Discord.js-Template

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Discord.js-Template

A template to create a fully customized Discord bot suited to your server.

Discord.js

How to use

  • Clone this repository and rename it with any name you want
  • Run npm install in your project directory to install dependencies

Next, you can edit your new project with an IDE like Visual Studio Code

Discord Intents

Important

You must declare Discord Itents to use different events
To use Discord Privileged Intents, you must activate it on Discord Developer Portal in your bot settings

Note

You can use a list of required intents with intentsBits, or use an integer code with intentsCode
To use intentsCode, you can use Discord Itents Calculator
Make sure the intents you declare match the events your bot listens to.

deployer.js

Use this file to deploy your slash commands

You need Node.js to execute this script (node deployer.js) and deploy commands
You need to execute only once no matter how many times you restart your Discord bot
You must execute it every time you add or edit commands

id.json

Put in this file all id or token you need, like client id, channels id, guilds id, etc...

Important

You must put in this file your bot client id and token to use it in the index.js and deployer.js

package.json and package-lock.json

package.json contains informations that you can edit, like Discord bot name, version, author, etc...

package-lock.json contains informations about Node.js package used in your project

Warning

You must not edit this file manualy
If you want update a Node.js package, you need Node.js and execute npm update <package>

But you can use this file to get informations about packages and use it in your code
You can see infosEmbed for an example

About

A template for developing a full personal Discord bot with Discord.js

Resources

License

Stars

Watchers

Forks

Contributors