How to query members of a voice channel
Hello,
i would like to query all the members of a certain voice channel.
But unfortunately i only get an empty list of members.
I had the same thing with channels, before i added the "View Channel/Message" Permission on the Discord Developer Site".
I query the channels by:
i filter the channel list for voiceChannels beforehand:
And i check for members by:
or
But i always get an empty collection.
I have searched quite some time on google but were only able to find results like "You need Members Intent"
Do i really? Its a complete overkill, cause i just wanna read the members and their id and nothing more.
I hope you can help me with your expierince.
Because this question is super explicit, i hope you can help me even though this might be discord api related :peepoLoveMonbrey:
Thank you guys! Have a good day
Details:
Node version: v20.6.1
discordjs: 14.14.1 (i cant change the label afterwards no?)
i would like to query all the members of a certain voice channel.
But unfortunately i only get an empty list of members.
I had the same thing with channels, before i added the "View Channel/Message" Permission on the Discord Developer Site".
I query the channels by:
i filter the channel list for voiceChannels beforehand:
const voiceChannels = channels.filter(channel => channel.type === ChannelType.GuildVoice)And i check for members by:
voiceChannels.first()?.members.sizeor
voiceChannels.first()?.members.has("someID")But i always get an empty collection.
I have searched quite some time on google but were only able to find results like "You need Members Intent"
Do i really? Its a complete overkill, cause i just wanna read the members and their id and nothing more.
I hope you can help me with your expierince.
Because this question is super explicit, i hope you can help me even though this might be discord api related :peepoLoveMonbrey:
Thank you guys! Have a good day
Details:
Node version: v20.6.1
discordjs: 14.14.1 (i cant change the label afterwards no?)