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

Adding old messages to the cache and making them listen for events like messageReactionAdd

Is this possible? I tried to add manually channel.messages.cache.set(id, message) but it didn't work.

The problem with shards

The bot was launched two days ago, it was on the host, it worked 24/7, in a single instance, but yesterday something happened and the bot suddenly died, and when it started, there were errors, although there were no incomplete sessions, etc. Other bots don't have such problems. I use the bot to synchronize users in the tg channel and the discord server. ```js Error: Not enough sessions remaining to spawn 1 shards; only 0 remaining; resets at 2025-02-23T21:04:34.120Z...

Embeds

Hi, I used discord.js a lot time ago, can somebody explain me how put embed in 14.18.0?

createMessageComponentCollector not a function

Hello, I searched this server for my issue and found some similar ones. However, the answer usually seems to be what I'm already doing (awaiting a reply first and calling the create on the reply). ``` message = await interaction.reply({ embeds: [pageEmbed], components: [row], withResponse: true }); const filter = i => ['prev', 'next'].includes(i.customId) && i.user.id === interaction.user.id && i.message.id === message.id;...

Failure to create channel

For some reason, I tried a lot of ways to create a channel when they click the button but it doesn't work every time. ```const { Events, EmbedBuilder, ActionRowBuilder, ButtonBuilder, ButtonStyle, ChannelType, PermissionsBitField } = require('discord.js'); module.exports = { name: Events.InteractionCreate,...

Regex error when setting name of subcommand integer option

Hey. I'm trying to set the name of a subcommand option, yet I get this weird regex error from doing so that I haven't quite figured out yet. Any thoughts? See comments for error. Related code snippet: ``` const data = new SlashCommandBuilder()...

Auth Webhooks

Discord recently added the ability to get webhook notifications when a user authorizes your app. Does djs support this in any way, or should I set it up manually via express?

Embed message problem and no ping

The Problem is that i cant ping in the following code and some parameters as footer and author wont get set after modal was submitted
No description

App in user account and guilds

A Discord user has added a bot to their account and is using it inappropriately. How can I remove the bot from this user's account? Another question: is it possible to check which users have added the bot like we do with guilds?...

'maxComponents' and 'max'

What's the difference between maxComponents and max in MessageComponentCollectorOptions?

Slash command unknown interaction without reload

I have been building a discord bot with slash commands, it is frustrating that everytime I restart my server, the discord page requires refresh/reload too to have the latest slash command May I know what is the fix to it, have been trying to reset slash commands and clear cache too, but none is working ```typescript...
No description

How to connect Discord Gateway API on the NodeJS backend

I want to listen my entitlement create, update and delete events on my backend nodejs app and then save the details in my own database.

Help with ticket bot

Need someone who programs in js. I have a problem with the ticket panel and select menu. I would like the tickets after selecting the appropriate category from the select menu to create on the appropriate channel.

My event doest responds

Hello, my event for a translated message doesnt responds, please help
No description

Cannot updateMessage after deferMessageUpdate (@discordjs/[email protected])

Hello, I'm running the following chain of interaction responses: ```ts...

Limit to command option to autocomplete

I want uses to only be able to use the command when they have used a correct option. I give correct optios with auto complete. Is this possible? And if so, how?

Error 10062 [Uknown Interaction]

So, i have this bot which we use in our server to manage the criminal roleplay. we wanted to create a isolated economy systems whit crypto, so the first step needed was to make a command to request the bitcoin on a person/ his mafia, via a payment, made on the other economy bot, which is owned by another manager and can't share his DB with mine. So the user has to make the payment, insert the amount of cash he payed and the photo proof of the payment. ...

question

is there a way i can like make lyrics into my status (like automatically play)

Sending a welcome DM to users that have added/authorized my bot

Finding a bot in Discord interface could be a bit challenging. Is there a way to send a welcome DM to user's who just added/authorized my bot?