option

abstract fun option(declaredName: String, optionName: String = declaredName.toDiscordString(), block: SlashCommandOptionBuilder.() -> Unit = {})(source)

Declares an input option, supported types and modifiers are in ParameterResolver, additional types can be added by implementing SlashParameterResolver.

Parameters

declaredName

Name of the declared parameter which receives the value

optionName

Name of the option on Discord, transforms the declared name uppercase characters with underscore + lowercase by default