# CommandInterface

#### CommandInterface\<T = unknown> -> Interface

* **name**: string;

* **aliases**?: string\[];&#x20;

* **help**?: [CommandHelp](/afkhandler/commandhelp.md);&#x20;

* **hidden**?: boolean | null;

* **guilds**?: [Arrayed](/afkhandler/utils.md)<[Snowflake](https://discord.js.org/#/docs/main/stable/typedef/Snowflake)>;&#x20;

* **guildsMsg**?: [DJSSend](/afkhandler/utils.md);

* **nsfw**?: boolean;&#x20;

* **nsfwMsg**?: [DJSSend](/afkhandler/utils.md);

* **dev**?: boolean;&#x20;

* **devMsg**?**:** [DJSSend](/afkhandler/utils.md);

* **permissions**?: [Arrayed](/afkhandler/utils.md)<[Snowflake](https://discord.js.org/#/docs/main/stable/typedef/Snowflake)>;&#x20;

* **permissionsMsg**?: [DJSSend](/afkhandler/utils.md);

* **locked**?: boolean;&#x20;

* **lockedMsg**?: [DJSSend](/afkhandler/utils.md);

* **cooldown**?: string | number;&#x20;

* **cooldownMsg**?: (remaining?: string) => [Awaited](/afkhandler/utils.md)<[DJSSend](/afkhandler/utils.md)>;

* **args**?: { **max**?: number; **min**?: number; };

* **argsMsg**?: [DJSSend](/afkhandler/utils.md);

* **botPermissions**: [Arrayed](/afkhandler/utils.md)<[Snowflake](https://discord.js.org/#/docs/main/stable/typedef/Snowflake)>;

* **botPermissionsMsg**: [DJSSend](/afkhandler/utils.md);

* **callback**?: Callback\<T>;&#x20;

* **run**?: Callback\<T>;&#x20;

* **execute**?: Callback\<T>;&#x20;

* **fire**?: Callback\<T>;&#x20;

* **emit**?: Callback\<T>;&#x20;

* **name**: command name;

* **aliases**: command aliases;&#x20;

* **help**: helping information;&#x20;

* **hidden**: when true it makes the command completely invisible, when null it makes the command partially invisible;

* **guilds**: guilds where the command can be executed;&#x20;

* **guildsMsg**: message sent when a command isn't executed in the correct guild;

* **nsfw**: nsfw command;&#x20;

* **nsfwMsg**: message that appears when a command is nsfw and is executed in q non nsfw channel;

* **dev**: developer command;&#x20;

* **devMsg:** message sent when a developer command isn't used by a developer;

* **permissions**: permissions that a GuildMember requires to execute the command;&#x20;

* **permissionsMsg**: message sent when a member without any permission setted on permissions property;

* **locked**: if the command is currently locked;&#x20;

* **lockedMsg**: message sent when a locked command is executed;

* **cooldown**: cooldown;&#x20;

* **cooldownMsg**: message sent when a user is on cooldown (function where the 1st parameter is the remaining time, returned value is what will be sent);

* **args.min:** minimum arguments&#x20;

* **args.max**: maximum arguments

* **argsMsg**: message sent when the user message doesn't satisfy the given arguments;

* **botPermissions**: permissions that the bot requires to execute a command;

* **botPermissionsMsg**: message sent when the bot doesn't have every permission specified in botPermissions property;

* **callback**: function fired when a command is executed;&#x20;

* **run**: function fired when a command is executed;

* **execute**: function fired when a command is executed

* **fire**: function fired when a command is executed;

* **emit**: function fired when a command is executed;


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://away-from-keyboard.gitbook.io/afkhandler/commandinterface.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
