Method RequestTwoFactorAsync
- Assembly
- DisCatSharp.Extensions.TwoFactorCommands.dll
RequestTwoFactorAsync(BaseContext)
Asks the user via modal input for the two factor code.
This uses DisCatSharp.Interactivity.
To be used as first action for application commands.
public static Task<TwoFactorResponse> RequestTwoFactorAsync(this BaseContext ctx)
Parameters
ctx
BaseContextThe base context.
Returns
RequestTwoFactorAsync(ComponentInteractionCreateEventArgs, DiscordClient)
Asks the user via modal input for the two factor code.
This uses DisCatSharp.Interactivity.
To be used as first action for button.
public static Task<TwoFactorResponse> RequestTwoFactorAsync(this ComponentInteractionCreateEventArgs evt, DiscordClient client)
Parameters
evt
ComponentInteractionCreateEventArgsThe interaction context.
client
DiscordClientThe discord client to use.