Creating User Installed Commands
This page will guide you through the setup of User-Installed commands
Disclaimer
This page has been created on the 26th June 2024, discord.js does not officialy support User Installed commands or has a Command Builder for it yet. If this changes, we will update this page. If we didnt, please let us know in our discord server.
What are User-Installed Commands?
Users have the option to install Apps/Discord Bots on their account directly. This means, they can use commands which you have added before as user installed commands in your code in all discord servers, group chats and direct messages. If the discord server "doesnt allow" to use user installed commands in their server, the discord bot will respons with ephemeral (only interaction user visible) messages. We still recommend to set ephemeral to true to not spam channels using the commands and provide a clean discord channel.
Handler Setup
You might have to setup your handler, you can find the code here for a dynamic support of commands: https://github.com/cptcr/nexus/blob/main/src/functions/handelCommands.js
Command Building
Here is an example code of a user installed commands which is a dictionary command. The command data has to be in a object format:
Useful Links
Example of building user-installed commands by Discord (JavaScript)
Developing A User-Installable App
Prebuilt Commands
User Installed commands explained with short tutorial
Last updated