Can a bot react to a user joining a voice channel without being there?

Hey guys, I want to notify certain users when any other user joins any voice channel on a server, can I do that without bot being joined to any of those voice channels and just hanging on the server? I tried using
client.on(Events.VoiceStateUpdate, async (oldState, newState) => {
console.log({ oldState, newState });
// rest of the code
client.on(Events.VoiceStateUpdate, async (oldState, newState) => {
console.log({ oldState, newState });
// rest of the code
but it does nothing when I join a voice channel discord.js version: [email protected] node version: v18.17.0
1 Reply
d.js toolkit
d.js toolkit6mo 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! - Marked as resolved by OP
Want results from more Discord servers?
Add your server