ApplicationCommandOptionData
typedef · Source
An option for an application command or subcommand. In addition to the listed properties, when used as a parameter, API style snake_case properties can be used for compatibility with generators like @discordjs/builders. Note that providing a value for the camelCase counterpart for any snake_case property will discard the provided snake_case property. Type: Object
Properties
type
The type of the option
name
The name of the option
nameLocalizations
The name localizations for the option
description
The description of the option
descriptionLocalizations
The description localizations for the option
autocomplete
Whether the option is an autocomplete option
required
Whether the option is required
choices
The choices of the option for the user to pick from
options
Additional options if this option is a subcommand (group)
channelTypes
When the option type is channel, the allowed types of channels that can be selected
minValue
The minimum value for an INTEGER or NUMBER option
maxValue
The maximum value for an INTEGER or NUMBER option
minLength
The minimum length for a STRING option (maximum of 6000)
maxLength
The maximum length for a STRING option (maximum of 6000)