Interface ISlashCommandOptionInfo
Contains all the information about a slash command option.
Namespace: Color_Chan.Discord.Commands.Models.Info
Assembly: Color-Chan.Discord.Commands.dll
Syntax
public interface ISlashCommandOptionInfo
Properties
| Improve this Doc View SourceAcknowledge
Whether or not the command should be automatically acknowledge to prevent the token from turning inactive after 3 seconds.
Declaration
bool Acknowledge { get; }
Property Value
Type | Description |
---|---|
Boolean |
Autocomplete
Enable autocomplete interactions for this option.
Declaration
bool? Autocomplete { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<Boolean> |
ChanelTypes
If the option is a channel type, the channels shown will be restricted to these types.
Declaration
IEnumerable<DiscordChannelType> ChanelTypes { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<DiscordChannelType> |
Choices
A list of System.Collections.Generic.KeyValuePair`2 where each key is a choice name, and the value is the raw value of the choice.
Declaration
IEnumerable<KeyValuePair<string, object>> Choices { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<String, Object>> |
CommandMethod
The System.Reflection.MethodInfo containing the method of the sub command.
Declaration
MethodInfo CommandMethod { get; set; }
Property Value
Type | Description |
---|---|
System.Reflection.MethodInfo |
Remarks
null when the option is not a sub command.
CommandOptions
The options for the slash command.
Declaration
List<ISlashCommandOptionInfo> CommandOptions { get; set; }
Property Value
Type | Description |
---|---|
List<ISlashCommandOptionInfo> |
Remarks
null when the option is not a sub command, or when the sub command doesn't have any options.
Description
The description of the option.
Declaration
string Description { get; set; }
Property Value
Type | Description |
---|---|
String |
Guilds
A System.Collections.Generic.IEnumerable<T> of SlashCommandGuildAttribute containing the IDs of the guilds that will get access to this slash command.
Declaration
IEnumerable<SlashCommandGuildAttribute> Guilds { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<SlashCommandGuildAttribute> |
Remarks
null when the option is not a sub command, or when it is a sub command but the command is global.
IsRequired
Whether or not the option is required.
Declaration
bool? IsRequired { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<Boolean> |
MaxValue
If the option is an INTEGER or NUMBER type, the maximum value permitted.
Declaration
int? MaxValue { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<Int32> |
MinValue
If the option is an INTEGER or NUMBER type, the minimum value permitted.
Declaration
int? MinValue { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<Int32> |
Name
The name of the option..
Declaration
string Name { get; set; }
Property Value
Type | Description |
---|---|
String |
ParentModule
The command module containing the CommandMethod.
Declaration
TypeInfo ParentModule { get; set; }
Property Value
Type | Description |
---|---|
System.Reflection.TypeInfo |
Remarks
null when the option is not a sub command.
Requirements
A System.Collections.Generic.IEnumerable<T> of InteractionRequirementAttributes containing all the requirements to execute the command.
Declaration
IEnumerable<InteractionRequirementAttribute> Requirements { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<InteractionRequirementAttribute> |
Remarks
null when the option is not a sub command, or when the sub command doesn't have any requirements.
Type
The type of the parameter.
Declaration
DiscordApplicationCommandOptionType Type { get; set; }
Property Value
Type | Description |
---|---|
DiscordApplicationCommandOptionType |