Class SlashCommandBuilder
- Namespace
- NetCord.Services.ApplicationCommands
- Assembly
- NetCord.Services.dll
public class SlashCommandBuilder : ApplicationCommandBuilder
- Inheritance
-
SlashCommandBuilder
- Inherited Members
-
Constructors
SlashCommandBuilder(string, string, Delegate)
public SlashCommandBuilder(string name, string description, Delegate handler)
Parameters
name
string
description
string
handler
Delegate
Properties
Description
public string Description { get; }
Property Value
- string
Handler
public Delegate Handler { get; }
Property Value
- Delegate
Methods
AddContexts(params IEnumerable<InteractionContextType>)
public SlashCommandBuilder AddContexts(params IEnumerable<InteractionContextType> contexts)
Parameters
contexts
IEnumerable<InteractionContextType>
Returns
- SlashCommandBuilder
AddIntegrationTypes(params IEnumerable<ApplicationIntegrationType>)
public SlashCommandBuilder AddIntegrationTypes(params IEnumerable<ApplicationIntegrationType> integrationTypes)
Parameters
integrationTypes
IEnumerable<ApplicationIntegrationType>
Returns
- SlashCommandBuilder
WithContexts(IEnumerable<InteractionContextType>?)
public SlashCommandBuilder WithContexts(IEnumerable<InteractionContextType>? contexts)
Parameters
contexts
IEnumerable<InteractionContextType>
Returns
- SlashCommandBuilder
WithDefaultGuildPermissions(Permissions?)
public SlashCommandBuilder WithDefaultGuildPermissions(Permissions? defaultGuildPermissions)
Parameters
defaultGuildPermissions
Permissions?
Returns
- SlashCommandBuilder
WithIntegrationTypes(IEnumerable<ApplicationIntegrationType>?)
public SlashCommandBuilder WithIntegrationTypes(IEnumerable<ApplicationIntegrationType>? integrationTypes)
Parameters
integrationTypes
IEnumerable<ApplicationIntegrationType>
Returns
- SlashCommandBuilder
WithNsfw(bool)
public SlashCommandBuilder WithNsfw(bool nsfw = true)
Parameters
nsfw
bool
Returns
- SlashCommandBuilder
WithRegister(bool)
public SlashCommandBuilder WithRegister(bool register = true)
Parameters
register
bool
Returns
- SlashCommandBuilder