ODSlashCommandUniversalOption interface
We are still working the API Reference! This page might be incomplete or doesn't contain all details!
Overview
A universal template for a slash command option.
Why universal? Both existing slash commands & unregistered templates can be converted to this type.
Properties
autocomplete type ➜ null|boolean
Is autocomplete enabled in this option?
channelTypes type ➜ readonly (discord-api-types.ChannelType[])
A list of allowed channel types for this option (only when type is channel)
choices array ➜ api.ODSlashCommandUniversalOptionChoice[]
Choices for this option (only when type is string)
description string ➜ string
The description of this option.
descriptionLocalizations type ➜ readonly (api.ODSlashCommandUniversalTranslation[])
All localized descriptions of this option.
maxLength type ➜ null|number
The maximum length required for this option (only when type is string)
maxValue type ➜ null|number
The maximum amount required for this option (only when type is number or integer)
minLength type ➜ null|number
The minimum length required for this option (only when type is string)
minValue type ➜ null|number
The minimum amount required for this option (only when type is number or integer)
name string ➜ string
The name of this option.
nameLocalizations type ➜ readonly (api.ODSlashCommandUniversalTranslation[])
All localized names of this option.
options type ➜ readonly (api.ODSlashCommandUniversalOption[])
A list of sub-options for this option (only when type is subCommand or subCommandGroup)
required boolean ➜ boolean
Is this option required?
type type ➜ discord-api-types.ApplicationCommandOptionType
The type of this option.