An array of aliases
Whether or not this command can be called by a user when DM-ing the bot
The category this command is part of
The amount of time in seconds of the command's cooldown
The map containing the customized responses
The description of the piece
Whether or not this piece is disabled
The flags provided by the user when running the command
The name of the piece
Whether or not this command can only be run in a nsfw channel
Whether or not this command can only be run by a bot owner
The pool this piece is part of
The raw (unprocessed) command arguments
The permissions the bot requires to run the command
The permissions the user is required to have to run the command
The usage string for the command
The usage delimiter
Customize the message thrown when an argument fails to parse
A function that runs at the bot startup once
A function that reloads the file
Generated using TypeDoc
Creating commands
Commands are arguably the most important thing a Discord bot can have.
Note: commands have flags which you can access by running this.flags (the flags are a Map!)
To get started with commands, just add a file in your
commands
folder and use the following example for JavaScript:or the following for TypeScript: