#Editing bot's nickname

1 messages · Page 1 of 1 (latest)

stone geyser
#

Hello I'm fairly new to coding discord bot and I was wondering if someone could help me figure out how to have my bot edit it's own server nickname through a slash command. Thank you!

dark field
#

ctx.Client.UpdateCurrentUserAsync()

#

@safe karma DiscordClient.UpdateCurrentUserAsync

safe karmaBOT
stone geyser
#

Thank you! But that edits the name of the bot, is there any way to edit the server nickname?

dark field
#

DiscordGuild.CurrentMember.ModifyAsync()

stone geyser
#

That's what I was trying to work with but I wasn't sure if it was the right way to go about it

dark field
#

@safe karma DiscordMember.ModifyAsync

safe karmaBOT
dark field
#

Note that you should use lambda operator for this

#

I.e ModifyAsync(x => x.Nickname = newName)