skeddles
DIAdiscord.js - Imagine an app
•Created by skeddles on 6/18/2024 in #djs-questions
Why is my number of emoji inaccurate?
9 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 1/23/2024 in #djs-questions
Command Wont Go Away
For some reason my command was listed twice in the command list.
So I deleted the command from my bot, then restarted it.
Now one of them was deleted, but the other is still there.
How can I delete the command?
6 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 1/21/2024 in #djs-questions
Why isn't messageCreate getting triggered?
the on ready is getting logged, but when i send messages, there's no response. why not?
8 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 11/8/2023 in #djs-questions
Why does my entire app crash when client.login fails?
try {
client.login(process.env.DISCORD_BOT_TOKEN);
} catch (err) {
console.error('failed to login to discordfailed to login to discord', err);
reject(err);
}
trying to login to discord through my website. If the client.login fails (because discord reset my token for the 10th time), then the entire website crashes. I'm trying to catch the error, but it doesn't catch it, it just crashes the whole app. how do i avoid that?
djs 14.7.1
5 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 11/8/2023 in #djs-questions
why does this work in dev but not production
on my dev environment it works fine. then I deploy it, and it crashes the whole site because
.channels
is undefined.5 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 10/30/2023 in #djs-questions
using rest API to update server banner
I'm trying to use the REST api to update my server banner.
The problem is that it seems to work - the await rest.patch() line does not throw an error, and it returns the guild object (which I believe it so be expected upon success).
But when I look at my server, the banner is unchanged. I thought it might be cached, but I did a hard refresh on the website, and also waiting 12 hours.
What am I doing wrong?
6 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 9/18/2023 in #djs-questions
Response: 500 Internal Server Error when bot tries to post a message
Recently my bot has had issues occasionally when posting an automated message to certain threads. Is this a discord problem or a me problem?
It says 500 error, so it seems like a discord problem, but who knows.
3 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 9/6/2023 in #djs-questions
Missing Access Error
8 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 8/7/2023 in #djs-questions
delete bot messages
11 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 4/21/2023 in #djs-questions
DiscordAPIError[50035]: Invalid Form Bodydata[BASE_TYPE_REQUIRED]: This field is required
trying to show a modal
what does this mean? what field and I missing?
4 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 4/1/2023 in #djs-questions
Permission to add role?
15 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 4/1/2023 in #djs-questions
Where can I find the options for creating a thread?
this guide page https://discordjs.guide/popular-topics/threads.html#thread-related-gateway-events
has
When i look up this method: https://discord.js.org/#/docs/discord.js/14.8.0/class/GuildTextThreadManager?scrollTo=create
then click "thread create options", it brings me to this page: https://discord.js.org/#/docs/discord.js/14.8.0/typedef/ThreadCreateOptions
but this only lists "startMessage", "type", "invitable"
Where are the other options? Where am I supposed to look? What did I do wrong?
5 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 3/30/2023 in #djs-questions
how do you get access to your instantiated `discordjs.Client` from imported files?
I can't do
export client
and import my main file, because that would create a circular dependency.
how is it usually done?
should i just make client global / attach it to process
?13 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 2/28/2023 in #djs-questions
How do I check if a messages user has a specific role?
it doesn't like the last line, cant find .member (but on the docs it says messages have a member property containing the guild member?) I can do user, but it doesn't look like that lets you fetch the roles, just has the basic info.
9 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 2/24/2023 in #djs-voice
get screenshots of streams?
is it possible to get screenshots of current streams? or even better, to stream their video elsewhere?
5 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 1/30/2023 in #djs-questions
fetch video stream
can i get a video stream? either to get a screenshot of what it is or the whole video stream, to then save to a file or stream elsewhere?
2 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 11/29/2022 in #djs-voice
get volume
i cant find the place in the docs that talks about volume, ive seen code like
volume.setVolume(0.2);
but cant find setVolume.
https://discord.js.org/#/docs/voice/main/class/AudioResource?scrollTo=volume
this page talks about volume, but not any of its submethods or anything, no link4 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 11/3/2022 in #djs-voice
dynamic volume levelling
i made a bot that plays music in a VC from mp3 files. unfortunately their volumes are all over the place. has anyone made it so their bot adjusts the volume automatically so they're all the same?
3 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 11/3/2022 in #djs-questions
dynamic volume levelling
i made a bot that plays music in a VC from mp3 files. unfortunately their volumes are all over the place. has anyone made it so their bot adjusts the volume automatically so they're all the same?
4 replies
DIAdiscord.js - Imagine an app
•Created by skeddles on 10/30/2022 in #djs-questions
how should i get user data with multiple inputs
how would you format a user input where the user might need to enter some of the values multiple times (and be grouped together)?
ie a command that adds an enemy to a game, and you want to configure the list of items it will drop, where each item needs a name, and how often it should drop
ideally in a single command
6 replies