Skip to content
This repository has been archived by the owner on Feb 9, 2021. It is now read-only.

Command

xlyr.on edited this page Jan 16, 2021 · 18 revisions

Slash Command

constructor

new Slash.Command(data);

Object<data>

name - String<name of command>
required

description - String<description of command>
required

permissions - Array Strings<required permissions to execute command>
required

options - Array Objects<options for command>
optional

execute - Function<function to be executed>
required

usage

commandOne.js
module.exports = new Slash.Command({
  name: 'hello',
  description: 'sends a hello world message',
  permissions: ["SEND_MESSAGES"],
  execute(interaction) {
  
    interaction.sendMessage("Hello World")
    
  }
})
Clone this wiki locally