Table of Contents

Class ChoiceProviderAttribute

Namespace
DSharpPlus.SlashCommands
Assembly
DSharpPlus.SlashCommands.dll

Sets a IChoiceProvider for a command options. ChoiceProviders can be used to provide DiscordApplicationCommandOptionChoice from external sources such as a database.

[AttributeUsage(AttributeTargets.Parameter, AllowMultiple = true)]
public sealed class ChoiceProviderAttribute : Attribute
Inheritance
ChoiceProviderAttribute

Constructors

ChoiceProviderAttribute(Type)

Adds a choice provider to this command.

Properties

ProviderType

The type of the provider.