Nostrum.Api.modify_guild_member
You're seeing just the function
modify_guild_member
, go back to Nostrum.Api module for more information.
Specs
modify_guild_member( Nostrum.Struct.Guild.id(), Nostrum.Struct.User.id(), options() ) :: error() | {:ok}
Modifies a guild member's attributes.
This endpoint fires the Nostrum.Consumer.guild_member_update/0
event.
It situationally requires the MANAGE_NICKNAMES
, MANAGE_ROLES
,
MUTE_MEMBERS
, DEAFEN_MEMBERS
, and MOVE_MEMBERS
permissions.
If successful, returns {:ok}
. Otherwise, returns a Nostrum.Api.error/0
.
Options
:nick
(string) - value to set users nickname to:roles
(list ofNostrum.Snowflake.t/0
) - array of role ids the member is assigned:mute
(boolean) - if the user is muted:deaf
(boolean) - if the user is deafened:channel_id
(Nostrum.Snowflake.t/0
) - id of channel to move user to (if they are connected to voice)
Examples
Nostrum.Api.modify_guild_member(41771983423143937, 637162356451, nick: "Nostrum")
{:ok}