Skip to content

Tag: discord.js

Discord.Intents(32767) vs [Intents.FLAGS.GUILDS]?

Do you know why the “message sent” is displayed only with the first solution? And not with this? (That is the example code on the discord.js documentation.) The bot is ready in both solutions, but I don’t get why only in the first one when I send a message in the server the bot detects it, m…

Remove 1 element from Embed object DiscordJS

I have been trying to code a bot that copies 1 embed from 1 channel to another channel. But what I want it to do before posting it to the other channel, I want it to remove 1 element from the embed object. How I have it currently: As you can see i straight use message.embeds[0]. So i don’t even

How do I fix CLIENT_MISSING_INTENTS error?

I started learning about discord.js, but now I am facing this issue. I tried some googling, but I couldn’t manage to fix it. This is the error I am getting: Answer You need to specify the events which you want your bot to receive using gateway intents. Instead of const client = new Discord.Client(); Use…

discord.js Editing a message and sleeping

So I am very new to discord.js and wanted to know how I can edit a message and then sleep and then edit the message again so it doesn’t cause extremely fast edits. I found this code and couldn’t figure out what to do Answer As suggested by LercDsgn in the comments, you can use setTimeout to edit t…