MessageCommandRun
Defined in: packages/discordjs/src/message-commands.ts:28
How a message command went.
Extends
Section titled “Extends”Properties
Section titled “Properties”command
Section titled “command”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.
Inherited from
Section titled “Inherited from”durationMs?
Section titled “durationMs?”
optionaldurationMs?:number
Defined in: packages/discordjs/src/message-commands.ts:30
How long the handler took, in milliseconds.
error?
Section titled “error?”
optionalerror?:unknown
Defined in: packages/discordjs/src/message-commands.ts:32
What the handler threw, if anything. Only its class name and Discord error code are recorded.
failed?
Section titled “failed?”
optionalfailed?:boolean
Defined in: packages/discordjs/src/message-commands.ts:34
The command failed, but your bot caught the error itself. Implied when error is set.
group?
Section titled “group?”
optionalgroup?:string
Defined in: packages/discordjs/src/message-commands.ts:15
Subcommand group, if the command has one.
Inherited from
Section titled “Inherited from”options?
Section titled “options?”
optionaloptions?: readonlystring[]
Defined in: packages/discordjs/src/message-commands.ts:19
Names of the arguments the user gave.
Inherited from
Section titled “Inherited from”optionValues?
Section titled “optionValues?”
optionaloptionValues?: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.
Inherited from
Section titled “Inherited from”MessageCommandInfo.optionValues
optionalsub?:string
Defined in: packages/discordjs/src/message-commands.ts:17
Subcommand, if the command has one.