-1
How do I play audio from a url with Discord.js v13.
I used this code and it didn’t work.
const connection = joinVoiceChannel({
channelId: voiceChannel.id,
guildId: message.guild.id,
adapterCreator: message.guild.voiceAdapterCreator,
})
const player = createAudioPlayer()
connection.subscribe(player)
const resource = createAudioResource(`http://www.site/audio.mp3`)
player.play(resource)