Skip to content

MessageCommandInfo

Defined in: packages/discordjs/src/message-commands.ts:11

A command that ran from a message, as your bot’s own parser understood it.

command: string

Defined in: packages/discordjs/src/message-commands.ts:13

The command’s name as your bot defines it, after aliases are resolved (ban, not what was typed). 1–32 characters.


optional group?: string

Defined in: packages/discordjs/src/message-commands.ts:15

Subcommand group, if the command has one.


optional options?: readonly string[]

Defined in: packages/discordjs/src/message-commands.ts:19

Names of the arguments the user gave.


optional optionValues?: Readonly<Record<string, string | number | boolean>>

Defined in: packages/discordjs/src/message-commands.ts:24

Argument values. Only names listed in captureOptionValues are kept, never a value holding a Discord ID (pass a mentioned user or channel as an argument name, not a value); strings are cut to 100 characters.


optional sub?: string

Defined in: packages/discordjs/src/message-commands.ts:17

Subcommand, if the command has one.