djs-questions

9202 threads · Page 162 of 185

messageDelete's deleter 10 messages
patent root is it possible to get the deleter of a message using the messageDelete event?
Issue with creating channels 6 messages
vapid anchor Hey I have an issue with mass creating voice channels in a discord server with this command
Property 'send' does not exist on type 'TextChannel' 29 messages
undone shadow Using typescript v4.8.4, discordjs v14.7.1 and node v16.9.0 With the following code: ```const channel = this.discordCl...
TypeError: Cannot read properties of undefined (reading 'id') 20 messages
rose bloom I have a bot that shows the server population of our game server as it's discord status. Was working fine for months and...
Shouldn't setTimeout delete the schema? 3 messages
modern oyster I tried making a rename command with a cooldown of 5 minutes but the setTimeout function doesn't seem to work, I'm not s...
High memory consumption using shards 6 messages
stiff nova Hi all, our bot crossed the 10K guilds and we are seeing very big memory issues while using the Discord.js library with ...
How to create a regular (not slash) command? 2 messages
mint timber Hello. I am a beginner discord bot developer, I made my choice on discord.js. I recently read the official documentation...
bot not online 27 messages
scarlet marten im making my first bot but it doesnt go online, tutorial i follow https://youtu.be/Gqurhm2QxA0
Guild member update event triggers on delete 4 messages
white bolt Hi! I've been looking for someone that got with a similar problem in forums like stack overflow, reading the docs and FA...
error with discord.js when reading .env variables 6 messages
patent root new to js and discord.js; pls be kind if im just being dumb https://stackoverflow.com/questions/75354286/error-with-disc...
slash command in an embed 5 messages
inner meadow I found this in the slash help of mee6 how can i put a link to a slash command in an embed thanks for your response
how do i make it so my bot doesnt ping everyone but can ping users 13 messages
gloomy haven i dunno how
error 8 messages
true spruce i keep getting this error and im not sure what to do
What is APIInteractionGuildMember 8 messages
eager siren Im trying to check if the member of my /command has admin permissions. When hovering over interaction.member typescript ...
Why do i get this error 2 messages
eager siren Im trying to deploy my commands but I get this error ```DiscordAPIError[20012]: You are not authorized to perform this a...
Event handler help 9 messages
errant furnace I'm trying to set up an event handler. The bot comes online and is able to execute ready.js...however it doesnt respond....
AllowedMentions still does not send through a user ping. 3 messages
amber needle Using latest. Sending interaction with the following code, and intr.editReply does nothing. ```js await InteractionU...
Determine strings of only single-byte numbers 3 messages
sly furnace What "if" statement should I write to determine "if a particular string contains only half-width numbers"?
Process.env error 101 messages
magic bolt Index.js ```require('dotenv').config() const { Client, IntentsBitField } = require('discord.js'); const client = new Cli...
Help with non-slash commands 18 messages
solid stag I know slash commands are better, please just humour me on this one. I'm trying to update an old bot that was made a l...
Potential library bug, hopefully not present in 14.7? 3 messages
zenith steppe I'm currently trying to do something with channel perms on v14 and got this issue :­­ `//Chan.permissionOver...
Connection Timeout Error 11 messages
gentle vector ```js ConnectTimeoutError: Connect Timeout Error at onConnectTimeout (C:\kryp\chizue\node_modules\undici\lib\core\co...
Not being able to use a StringOption in a reply 15 messages
crisp valley I am trying to create an 8ball command and I'm trying to figure out how to put the user's string in the reply message. A...
Can't fetch owner on guild join 2 messages
oblique shell I'm trying to fetch the guild owner and send them a message when my bot joins, but my bot is giving me errors: The synta...
Getting objects from client cache after sharding 21 messages
graceful lodge So I am about to shard my bot... its not yet public but I want to make it shard compatible from the beginning. My questi...
Error when permissions missing 6 messages
gloomy glen I'm trying to make a kick command, and I was testing the "missing permissions" response from the bot, but I get this err...
APIError: Field "type" is required to determine the model type. 4 messages
surreal snow My modal: ```js const modal = new ModalBuilder() .setCustomId('mn-' + userId + '-' + testId) .setTitle('...') ...
GatewayIntentBits is not defined 22 messages
spare urchin idk why this is happening
page number is NaN on page system 5 messages
winged basin So i am making a page system to scroll thorugh a persons inventory, but when pressing the buttons to go right, full righ...
Error with ping a role. 4 messages
humble narwhal The code is correct, i use ``<@&ROLEID>``, but it pings the role and does not mention it. I checked the actual role, and...
Clean code without nesting on('collect' 16 messages
lucid parrot I'm trying to get 5 sequential infos from the user but the only way to do that was nesting a lot of callbacks. Is there ...
What is wait code 2 messages
atomic hull Please reply
Bot Setup NEED HELP 23 messages
shy tundra Hello
Best practices with awaitInteraction 3 messages
pulsar escarp I have a menu that opens upon running a command where the user can choose different actions. Would the best practice be ...
Can't get interaction.followUp to work 11 messages
blazing karma Hello, I spent hours on trying to get my code to work. Since interaction.reply can only be used once, I tried using int...
Random Image Sender Bot (An Idea) 24 messages
formal fable yo wsg guys so this is my question, do yall have any idea on how to make a bot that sends random images from a local fil...
How to display a role's hex color? 5 messages
fervent hollow Hello, I am using discord.js v13.10.2 and am trying to display a role's *hex* color in an embed field. I have tried: ``...
Help with setting roles 14 messages
graceful oasis Hey guys,I want to give the player that started the command a specific role and I also want to get the role id from the ...
Interaction.reply showing all values from an array 2 messages
blazing karma Hi all, I need help with making a slash command that will show everything from an array. This is fragment of my array: ...
Create a second modal 4 messages
void heath Hi. So I thought about a command that when you run it, it creates a modal. After its submitted, it should create another...
How can i attach an mp3 file to a message? 4 messages
wicked linden How can i attach an mp3 file to a message?
I launched my bot 36 messages
hexed plinth And suddenly i got it's some error could you help me
Set intents after initializing the client 38 messages
potent sphinx Hey, I am working on a bot and I need to update the clients' intents and partials AFTER I instantiate the client object....
MongoDB problem 7 messages
thorn glen So I'm making a level function. The 4 files attached are all linked (except the index.js, but it might show something th...
client to get channel by id inside of a slash command 12 messages
edgy mortar how to use client to get channel by id inside of a slash command
How to get the channel that the interaction was called on, and send a message there 26 messages
thorn glen I think this is pretty straightforward? I will elaborate if needed
How to clear certain slash commands 6 messages
thorn glen So, i ported my bot over from discord.py to discord.js. On the discord.py version, there were more commands. I was wonde...
Sub-Commands Error 21 messages
proven lintel I tried implementing a sub-command for the first time based on documentation from: https://discordjs.guide/slash-command...
BitFieldInvalid Error 14 messages
crimson stream Everytime I try to use the command 'node .' for my Discord.js bot I receive this error.
stop an interaction 5 messages
inner meadow I have this code when i try to return the interaction when i catch an error for the code to not crash but the following ...