© 2026 Hedgehog Software, LLC
@discordjs/voice
const player = createAudioPlayer({ debug: true, }); const resource = createAudioResource(`/Volumes/Files/audio/music.ogg`); const connection = joinVoiceChannel({ adapterCreator: channel.guild.voiceAdapterCreator, guildId: channel.guild.id, channelId: channel.id, }); connection.subscribe(player); connection.on("stateChange", (oldState, newState) => { if ( oldState.status === VoiceConnectionStatus.Ready && newState.status === VoiceConnectionStatus.Connecting ) { connection.configureNetworking(); } }); player.play(resource); player.unpause();
Join the Discord to ask follow-up questions and connect with the community
Support server for discord.js, a Node.js module to interact with Discord's apps API.
57,666 Members