discord.js - Imagine an app

DIA

discord.js - Imagine an app

Support server for discord.js, a Node.js module to interact with Discord's apps API.

Join

djs-questions

djs-voice

Error [ApplicationCommandPermissionsTokenMissing]: Editing application command permissions requires

```js await guild.commands.permissions.add({ command : '1277387223595089932', permissions: [ {...

The application did not respond.

When I use the command it says "The application did not respond", I get no errors. ```js const { Client , Message, MessageEmbed, CommandInteraction, MessageActionRow, MessageButton } = require('discord.js')...

Sharding retrieve guild data

- Discordjs 14.9.0 - Node 20.10.0 Can someone explain me why when I try to retrieve members data cache, the result is undefined ?...
No description

Reaction collector for every message in every channel

Hi, I'd like users to be able to react to any message in a guild with a specific emojji and have my bot react on that interaction. Is this possible and does anyone have any example of this sort of implementation?

Why is AttachmentBuilder not included in @discordjs/builders?

Wondering why this is the case, or how I can build a message JSON with an attachment using only builders and not discord.js.

Status Probleme

Hello, for some time the status to put on my bot does not appear anymore because I had put information etc and it does not appear while on other bots it appears here is the code (but I have my index.js which does something to make its start in the ready.js file so that its put the status and before it put it and more of all) **const path = require('path'); const fs = require('fs'); module.exports = (client) => {...

Application doesn't respond

I have a problem, every time I make an interaction, whether it's a command or pressing a button it responds to me with: Application doesn't respond. I share with you my 3 reference codes, the config.js and the other files I personally checked and everything is correct, but in those I can't understand where the problem is https://sourceb.in/xp8vrRu91W...

Is there a way to get a log of added or removed roles for a member?

I have used this code for a long time to achieve this until suddenly I encountered an error when a member is not in the cache. When the guildMemberUpdate event occurs, it logs that all roles the member already had have been added again. ```js export default async (client, oldMember, newMember) => { // Get roles of the oldMember from the cache (not ideal but necessary if no other option)...

How can i edit the embed of a message?

Im trying to make a /ratrace command which returns a embed with the racers,and i want to actually edit them so that they move and stuff,i have tried searching ways to editing an embed but i havent found any. (also startrace() function is gonna be for editing the message.)
No description

Is it possible to add metadata to a message?

I'm trying to identify responses that my bot gives as a result of one specific (/) command. I don't want to differentiate messages by checking their format. I tried looking for flags, embeds, even using nonce (really shady), but every attempt failed.
Attached are images of my code, I need to do something like this, but using some kind of metadata or any other parameter that allows me to get this "emoji" data....
No description

check for here , everyone mention

How i can check if user mentioned everyone or here

Problem with rights and logical code separation

In general, the problem I have is that I have a main directory ├── buttonHandlers\ ├────── yesBanAction.js ├────── banAction.js ├────── cancelBanAction.js...

registering commands

I'm a new developer to the discord.js community and I'm working on a bot named anchor, I'm trying to make a "registerCommands.js" to go in my handlers folder, I've tried everything i can but can get it to register to use the command in discord

Deploy-commands not working

I don't really understand here, it doesn't seem to me to be in ratelimit with the api and the deploy commands but when I want to deploy my commands - it stays frozen, it lasts a very long time ? :/ the red error is not important, all good...
No description

get channels

app.post('/channels', async (req, res) => { const accessToken = req.body.accessToken; const guildId = req.body.guildId; try { const response = await axios.get(https://discord.com/api/guilds/${guildId}/channels, {...

guildMemberAvailable

why this event not fire with me
Helium.on("guildMemberAvailable",(member) => {
console.log(member.displayName)
});
Helium.on("guildMemberAvailable",(member) => {
console.log(member.displayName)
});
...

Timeout command

I am trying to get my timeout command to work but I keep getting > ERROR [22:21:32] Error while executing timeout command: Cannot read properties of undefined (reading 'getUser') and when I get that away it does show everything properly but the command does not get the user timeout I am not sure if its the Rest API or something else any help with me very much helpful ```js...

Fetching custom emoji from my discord application's emojis

How can I fetch an emoji from discord's newest emoji section?
No description

Can't run the guide lightly modified bot

[WARNING] The command at /home/dainis/bot/commands/utility/info.js is missing a required "data" or "execute" property.
Ready! Logged in as xxxxxxxxxx
[WARNING] The command at /home/dainis/bot/commands/utility/info.js is missing a required "data" or "execute" property.
Ready! Logged in as xxxxxxxxxx
...