> For the complete documentation index, see [llms.txt](https://tribui141108.gitbook.io/nocli-handler.js/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tribui141108.gitbook.io/nocli-handler.js/definitions/icommand.md).

# ICommand

The ICommand interface for a command | Type Interface Annotation

<table><thead><tr><th width="208">Parameter</th><th width="275.090087890625">Description</th><th>Type</th><th>Required</th></tr></thead><tbody><tr><td><code>type</code></td><td>Whether the command is slash command, legacy command, or both</td><td><a href="/nocli-handler.js/definitions/noclicommandtype.md">NoCliCommandType</a></td><td><code>true</code></td></tr><tr><td><code>delete</code></td><td>Tells the command handler whether to disable this command from interaction with the guilds</td><td><code>Boolean</code></td><td><code>false</code></td></tr><tr><td><code>init</code></td><td>Runs events inside a command</td><td><code>Function</code></td><td><code>false</code></td></tr><tr><td><code>autocomplete</code></td><td>Handles autocomplete interaction for a Slash command</td><td><code>Function</code></td><td><code>false</code></td></tr><tr><td><code>description</code></td><td>The description of the command</td><td><code>String</code></td><td><code>true</code></td></tr><tr><td><code>minArgs</code></td><td>The minimum amount of arguments for the command</td><td><code>Number</code></td><td><code>false</code></td></tr><tr><td><code>maxArgs</code></td><td>The maximum amount of arguments for the command</td><td><code>Number</code></td><td><code>false</code></td></tr><tr><td><code>correctSyntax</code></td><td>Sends a message specified in <code>correctSyntax</code> if arguments validation failed.  Hover from your text editor for annotations.</td><td><code>String</code></td><td><code>false</code></td></tr><tr><td><code>expectedArgs</code></td><td>The expected arguments that should be in place. Hover from your text editor for annotations and the important message.</td><td><code>String</code></td><td><code>false</code></td></tr><tr><td><code>expectedArgsTypes</code></td><td>Defines the Slash Command option property for expectedArgs</td><td><a href="https://discord-api-types.dev/api/discord-api-types-v10/enum/ApplicationCommandOptionType"><code>ApplicationCommandOptionType</code></a><code>[]</code></td><td><code>false</code></td></tr><tr><td><code>permissions</code></td><td>The command permissions</td><td><code>PermissionResolvable[]</code></td><td><code>false</code></td></tr><tr><td><code>testOnly</code></td><td>Whether the command is for test guilds or not</td><td><code>Boolean</code></td><td><code>false</code></td></tr><tr><td><code>guildOnly</code></td><td>Whether the command only works only in guilds</td><td><code>Boolean</code></td><td><code>false</code></td></tr><tr><td><code>ownerOnly</code></td><td>Whether the command is only allowed for bot owners</td><td><code>Boolean</code></td><td><code>false</code></td></tr><tr><td><code>deferReply</code></td><td>Tells the command handler whether to delay command reply when any value is returned from the command</td><td><code>Boolean</code></td><td><code>false</code></td></tr><tr><td><code>reply</code></td><td>Tells the command handler to tell the bot to either reply or send channel message. Hover on your editor for details</td><td><code>Boolean</code></td><td><code>false</code></td></tr><tr><td><code>cooldowns</code></td><td>The command cooldowns</td><td><a href="/nocli-handler.js/definitions/noclicommandcooldown.md">NoCliCommandCooldown</a></td><td><code>false</code></td></tr><tr><td><code>options</code></td><td>The Discord.JS arguments (only works for Slash Commands). Specify this if you are used to handle Discord.JS arguments with Slash Commands.</td><td><a href="https://discord.js.org/#/docs/discord.js/main/typedef/ApplicationCommandOptionData">ApplicationCommandOptionData</a><code>[]</code></td><td><code>false</code></td></tr><tr><td><code>callback</code></td><td>The function to execute when the command is called</td><td><a href="/nocli-handler.js/definitions/commandcallbackoptions.md">CommandCallbackOptions</a></td><td><code>true</code></td></tr><tr><td><code>aliases</code></td><td>Short-form commands</td><td><code>String[]</code></td><td><code>false</code></td></tr></tbody></table>
