Class DiscordApplicationCommandOptionData
Represents a discord Application Command Option Structure API model. Docs: https://discord.com/developers/docs/interactions/application-commands#application-command-object-application-command-option-structure
Implements
Inherited Members
Namespace: Color_Chan.Discord.Core.Common.API.DataModels.Application
Assembly: Color-Chan.Discord.Core.dll
Syntax
public class DiscordApplicationCommandOptionData : IEquatable<DiscordApplicationCommandOptionData>
Properties
| Improve this Doc View SourceAutocomplete
Enable autocomplete interactions for this option.
Declaration
[JsonPropertyName("autocomplete")]
public 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
[JsonPropertyName("channel_types")]
public IEnumerable<DiscordChannelType> ChanelTypes { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<DiscordChannelType> |
Choices
Choices for string and int types for the user to pick from.
Declaration
[JsonPropertyName("choices")]
public IEnumerable<DiscordApplicationCommandOptionChoiceData> Choices { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<DiscordApplicationCommandOptionChoiceData> |
Description
1-100 character description
Declaration
[JsonPropertyName("description")]
public string Description { get; set; }
Property Value
Type | Description |
---|---|
String |
IsRequired
If the parameter is required or optional--default false.
Declaration
[JsonPropertyName("required")]
public 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
[JsonPropertyName("max_value")]
public 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
[JsonPropertyName("min_value")]
public int? MinValue { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<Int32> |
Name
1-32 lowercase character name matching ^[\w-]{1,32}$.
Declaration
[JsonPropertyName("name")]
public string Name { get; set; }
Property Value
Type | Description |
---|---|
String |
SubOptions
If the option is a subcommand or subcommand group type, this nested options will be the parameters.
Declaration
[JsonPropertyName("options")]
public IEnumerable<DiscordApplicationCommandOptionData> SubOptions { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<DiscordApplicationCommandOptionData> |
Type
value of application command option type.
Declaration
[JsonPropertyName("type")]
public DiscordApplicationCommandOptionType Type { get; set; }
Property Value
Type | Description |
---|---|
DiscordApplicationCommandOptionType |