Category "discord.js"

Discord js 13 button edit permission channel

When a person sends my command, a channel is created that only they have access to. Also, when creating a channel, a message is sent with the "accept" button, w

How do I check if a message DOES NOT start with the prefix?

Title mostly says it all, how do I check if a message doesn't start with the prefix so I can send a message alerting the user they didn't use the prefix?

TypeError: Cannot read properties of undefined (reading 'add')

I've been stuck on this for ages and can't figure out why the error pops up. async function verify(i) { try { var g = await client.guilds.cache.get(

Embedding issue / All messages send at once

I'm having this issue where all my embeds are together. How do I separate them? My issue is that every time I run the embeds send together, I know the issue bu

Why does my Discord bot keep repeating when it runs this command?

This is the code used, there is nothing (I think) that's causing it to repeat, matter of fact I added something so it stops repeating but it didn't do anything

Discord.js How to find all the servers a different discord user is in

I want to make a website where people can change what the bot does on their server. I'm currently using Autocode to make it (using discord.js). I also don't kno

Discord bot, deleting messages

I'm new to discord bots. I have a script that gives members a role if the join a VC, that way they can see a Text channel. I want the channel to be cleared out.

ReferenceError: Routes is not defined Discord

client.once("ready", () =>{ console.log("Bot is online"); const CLIENT_ID = client.user.id; const rest = new REST({ version: "9"

Await component doesn't send OK

I would like to do a await message and list for my setWelcome but it does not send me Ok when I select in the Select menu and I do not know if it is good for th

Discord.js get current message embed

I've been trying to make my bot's embed color update dynamically (using random color, editing HSV value). However, using msg.embeds[0] seems to give me the prev

discord.js check if user has permissions

I want a command that can only be used by people who have the ban permission current code: if(msg.member.guild.me.hasPermission('BAN_MEMBERS')) { msg.

Uncaught Error Error: Cannot find module 'express' [closed]

im trying to make a discord bot using discord.js it works but whenever i try hosting it i get (Uncaught Error Error: Cannot find module 'expre

guildMember is not defined

I was trying to make welcome message when someone gets on my server but I am trying to do so it takes embed from another file. It says guildMember is not define

hello I am getting an error that shows up in discord modal it tells Something went wrong. try again discord.js

Hello I made a mail command which would take message from modal and send it to a mentioned user but it gives this error in modal window and does not log anythin

Get interaction's reponse message object discord.js

Si I have this really simple command : let row = new Discord.MessageActionRow().addComponents(...) // The .. is too long so i'll just remove it for this questio

Discord js getting a bot's message

Well i need to do this: on a channel a bot announces "btc" price (not real) im trying to get the price and send the price to a specificed channel My code sa.on(

PM2 only auto restart between specific time?

Not sure how to make pm2 run a Javascript that restart at 23 PM 59 sec everyday then enables auto restart for 10 mins to next day's 00:09 then no-autorestart fo

message.author.id TypeError: Cannot read properties of undefined (reading 'id')

Why i didnt get message.author.id and create the channel with special permissions? const {SlashCommandBuilder} = require("@discordjs/builders") const { Client,

DiscordJS MessageManager is a circular dependency

I try to get a message by id in discord.js, but returned MessageManager is a circular dependency and I cannot access any of it's properties. console.log(cha

DiscordJS v13 send to specific channel

So I am trying to send an embed to a different channel than the command was used in as a log channel how ever I have tried a few different methods however where