Bot not connecting to voice channel

Hey guys, so I could need a little bit of help. I wrote a Bot yesterday that should be able to connect to a voice channel. Took me a while, but I figured it out and it worked like a charm. So, when I checked Discord this morning, I saw that my bot went offline, nothing to serious. But after it started, it just kept on the "Signalling" state of the voice connection. I checked, that the Intent is set, but I can't see any other reason for this issue. Does someone know, what I can do?
2 Replies
d.js toolkit
d.js toolkit5mo ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button!
TheReal_Flo_
TheReal_Flo_OP5mo ago
Discord.js version: [email protected] Node version: v22.1.0 Voice version: 0.17.0 No stack trace, just stuck on signalling
// Create a new client instance
const client = new Client({ intents: [GatewayIntentBits.Guilds, GatewayIntentBits.GuildVoiceStates] });
// Log in to Discord with your client's token
client.login(argv.dev ? process.env.DISCORD_TOKEN_DEV : process.env.DISCORD_TOKEN);
// Create a new client instance
const client = new Client({ intents: [GatewayIntentBits.Guilds, GatewayIntentBits.GuildVoiceStates] });
// Log in to Discord with your client's token
client.login(argv.dev ? process.env.DISCORD_TOKEN_DEV : process.env.DISCORD_TOKEN);
const channel = interaction.member.voice.channel;

console.log(channel.guild);

if (!channel) return interaction.reply('You are not connected to a voice channel!'); // make sure we have a voice channel

const connection = joinVoiceChannel({
channelId: channel.id,
guildId: channel.guild.id,
adapterCreator: channel.guild.voiceAdapterCreator,
});
const channel = interaction.member.voice.channel;

console.log(channel.guild);

if (!channel) return interaction.reply('You are not connected to a voice channel!'); // make sure we have a voice channel

const connection = joinVoiceChannel({
channelId: channel.id,
guildId: channel.guild.id,
adapterCreator: channel.guild.voiceAdapterCreator,
});
I disabled my Server's Firewall completely to check, also no faulty connection, as I have about 0.8ms Ping to the Voice Region I was in Also, it's kinda strange, that the issue started both on my local machine and on my server... Could it be, that Discords starts blocking bots from using Voice chats randomly? Huh, so, can I ping the voice chat servers somehow on their relevant UDP Port to confirm myself that it's not a Firewall issue?
Want results from more Discord servers?
Add your server