Table of Contents

Method UseCommands

Namespace
DSharpPlus.Commands
Assembly
DSharpPlus.Commands.dll

UseCommands(DiscordClientBuilder, Action<IServiceProvider, CommandsExtension>, CommandsConfiguration?)

Registers the extension with the DiscordClientBuilder.

public static DiscordClientBuilder UseCommands(this DiscordClientBuilder builder, Action<IServiceProvider, CommandsExtension> setup, CommandsConfiguration? configuration = null)

Parameters

builder DiscordClientBuilder

The client builder to register the extension with.

setup Action<IServiceProvider, CommandsExtension>

Any setup code you want to run on the extension, such as registering commands and converters.

configuration CommandsConfiguration

The configuration to use for the extension.

Returns

DiscordClientBuilder