Skip to content

A template for a discord bot. Just add your own commands!

Notifications You must be signed in to change notification settings

ChujiaGuo/Discord.Js-Bot-Template

Repository files navigation

Discord.js Bot Template

Written by: Chujia Guo

This project is my attempt at making a discord bot template. It can be reused to make multiple bots without starting from scratch.

Features:

  • Custom Command Ready
  • Has some basic commands such as ping and help
  • Commands have permissions.

Setup:

  • Before starting, make sure you have Node.js and Discord.js installed.
  • In order to start using the bot, create a privatekeys.json file in the root folder. (This is where the main.js file is)
  • In that file, add your token in JSON format, like so:
{
    "token":"insert-token-here"
}
  • Install dependencies by running npm install dependencies while in this folder.
  • Add your bot to the server of your choice, run node main.js in your terminal and you should be all set!

Default Commands:

Adding Commands:

  • Add custom commands in the custom_commands folder.
  • Basic Command Template:
exports.run = async (client, message, args, Discord) => {
        //Insert Code Here!
}
exports.config = {
    "name": "",
    "description":"",
    "aliases": [""]
}
  • Manually add permissions in the permissions.json file using command name to role id pairs, or by using the setup command.

About

A template for a discord bot. Just add your own commands!

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published