SlashCommandInteractionManager

The slash command interaction manager.

Constructor

new SlashCommandInteractionManager(client, interactionManager)

The constructor of the slash command interaction manager class.

Parameters:
NameTypeDescription
clientClient

The client

interactionManagerInteractionManager

The interaction manager

Members

cache :Collection.<String, SlashCommand>

The cache with all slash commands

Type:

client :Client

The client

Type:
  • Client

manager :InteractionManager

The interaction manager

Methods

deploy(slashCommand) → {Promise.<(Boolean|DisGroupDevError)>}

Deploys one specific slash command

Parameters:
NameTypeDescription
slashCommandSlashCommand

The slash command to deploy

Returns:
Type: 
Promise.<(Boolean|DisGroupDevError)>

deployAll() → {Promise.<(Boolean|DisGroupDevError)>}

Deploys all slash commands

Returns:
Type: 
Promise.<(Boolean|DisGroupDevError)>

load(path) → {Promise.<(Boolean|DisGroupDevError)>}

Loads one specific slash command

Parameters:
NameTypeDescription
pathString

The path to the slash command

Returns:
Type: 
Promise.<(Boolean|DisGroupDevError)>

loadAll() → {Promise.<(Boolean|DisGroupDevError)>}

Loads all slash commands

Returns:
Type: 
Promise.<(Boolean|DisGroupDevError)>

reload(name) → {Promise.<(Boolean|DisGroupDevError)>}

Reloads one specific slash command

Parameters:
NameTypeDescription
nameString

The name of the slash command

Returns:
Type: 
Promise.<(Boolean|DisGroupDevError)>

reloadAll() → {Promise.<(Boolean|DisGroupDevError)>}

Reloads all slash commands

Returns:
Type: 
Promise.<(Boolean|DisGroupDevError)>

unload(name) → {Promise.<(Boolean|DisGroupDevError)>}

Unloads one specific slash command

Parameters:
NameTypeDescription
nameString

The name of the slash command

Returns:
Type: 
Promise.<(Boolean|DisGroupDevError)>

unloadAll() → {Promise.<(Boolean|DisGroupDevError)>}

Unloads all slash commands

Returns:
Type: 
Promise.<(Boolean|DisGroupDevError)>