Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

248
Vistas
Discord.js v13 bot won't join voice channels

Been troubleshooting this for multiple hours now. Issue is that I don't get any error logs from this as the code runs "fine". The bot just doesn't join a voice channel. I have copied the code almost 1:1 from a YouTube tutorial where it worked, and I have tried the official Discord guides as well, and both have the same results.

Here's my code:

const discordVoice = require('@discordjs/voice');

const player = discordVoice.createAudioPlayer();
const resource = discordVoice.createAudioResource(`/sounds/happy/${happySoundsRandom}`);
                    
const connection = discordVoice.joinVoiceChannel({
  channelId: channel.id,
  guildId: message.guild.id,
  adapterCreator: message.guild.voiceAdapterCreator,
});
                        
player.play(resource);
connection.subscribe(player);

console.log("Bot sent to voice")

When I run that by sending a message, I do get that console.log but no results on Discord side. I have readded the bot as an administrator, and made 100% sure the bot has voice channel permissions.

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

You have to use message.member.voice.channel.id instead of your channel.id

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda