Coder Social home page Coder Social logo

wokcommands-v2's Introduction

alt Discord alt GitHub Repo

alt WOKCommands

WOKCommands

WOKCommands is a Discord.JS command handler made by Worn Off Keys. The goal of this package is to make it simple and easy to get your bot off the ground without worrying about your own command handler.

Documentation

The official documentation can be found here: https://docs.wornoffkeys.com

Installation

npm install wokcommands

Support & Feature Requests

This package is looking for feedback and ideas to help cover more use cases. If you have any ideas feel free to share them within the "๐Ÿ’ก ๏ฝœ suggestions" channel in the Worn Off Keys Discord server.


wokcommands-v2's People

Contributors

alexzanderflores avatar alima566 avatar d3oxy avatar evolutionx-10 avatar kirotm avatar luxbg avatar lvorex avatar omjo-mojo avatar theoreotm avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

wokcommands-v2's Issues

Slash command creation rate limit issue

Currently, when WOK makes slash commands, it spams Create Global Application Command. This can result in a rate limit when having over five applications commands.

for (let fileData of [...defaultCommands, ...files]) {

This is in the for loop above:
this._slashCommands.create(
command.commandName,
description!,
options
);

WOK should instead use Bulk Overwrite Global Application Commands and provide all slash commands it wants the bot to have. An added benefit of this is that

if (type === "SLASH" || type === "BOTH") {
if (testOnly) {
for (const guildId of this._instance.testServers) {
this._slashCommands.delete(command.commandName, guildId);
}
} else {
this._slashCommands.delete(command.commandName);
}
}

can possibly be removed since Discord will auto-overwrite anything not provided.

Can't use deferReply and permissions at the sametime

When I use deferReply and have an permission set. Every time there is someone who doesn't have the permission it gives me this error:

Error [InteractionAlreadyReplied]: The reply to this interaction has already been sent or deferred.

Update Command Docs

Hi, I am currently using WOK V2 and while using the command property permissions I noticed that the syntax changed from a string array to a bigint array, It took me a while to figure out what was needed. Could this be added to the docs to make it clearer.

Delete slash commands

I guess there's isn't any methods for now to delete the slash commands.

Edit: On deleting the command files, the command doesn't gets deleted, I wish there was a feature like this, cause that would be helpful.

disabledDefaultCommands bug

Use disabledDefaultCommands and disable any default command (I disabled customcommand) after that start your bot, your slash commands won't register and other default commands (expect channelonly) won't register too.

Infact the prefix commands of the same slash commands work, but slash commands won't register except 1 or 2 default commands.

How to auto delete command when a command file is deleted

Hello, I'm trying to use the wokcommand module, when I delete a slash command file, the slash command remains on the server even though it can't be used anymore, how do I automatically delete the command when the file is deleted, thank you

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.