Getting User Guild Avatar/Banner
Hi I'd like to know how can i get the user's avatar and banner in the current guild
Currently I get the user info from
5 Replies
- 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!Latest discord.js version
Despite sounding similar there is a distinct difference between users and members in Discord:
• User: global Discord user data (global avatar, username, tag, id)
• GuildMember: user data associated to a guild (guild, nickname, roles, voice, guild avatar, etc.)
• Conversion: User ➞ GuildMember | GuildMember ➞ User
Your code make no sense. Your
currentUser
will be either true
or undefined
oh yeah sorry
let currentUser = message.mentions.users.first()
how can i get the guild icon for the user?
I got that part over with, now I'm trying to get the banner
whats the method for the GuildMember bannerURL ?
nah, i dont think there is a guildmember banner yet ??
alrightt thanks a lott!! for anyones reference later on: