OptionalavatarOptionalavatarOptionalcommunicationOptionalnickOptionalpendingOptionalpermissionsOptionalpremiumOptionaluserBans a user with the given reason and options.
The reason for banning the user.
Optional parameters for the ban.
Optionaldelete_Optionaldelete_The number of seconds to delete messages for (0-604800, where 0 is no deletion).
Edits the properties of the guild member with the specified options.
This method sends a request to the Discord API to update the member's attributes identified by their user ID within the guild. The updated member data will be reflected in the current instance after the operation is successful.
The options for editing the member.
Optionalchannel_The ID of the channel to move the user to if they are connected to voice.
Optionalcommunication_The timestamp until the user is muted, or null to remove the timeout.
Optionaldeaf?: booleanWhether to deafen the user in voice channels.
Optionalflags?: numberGuild member flags to set for the member.
Optionalmute?: booleanWhether to mute the user in voice channels.
Optionalnick?: stringThe nickname to set for the user.
Optionalroles?: string[]An array of role IDs to assign to the member.
A promise that resolves to the updated Member instance.
Kicks a user from the guild with the specified reason.
This method performs a kick operation, which removes a user from the guild. It sends a request to the Discord API to update the guild member's status and then removes the member from the local cache.
The reason for kicking the user. This reason will be included in the audit log for the kick operation, which helps to track why the user was kicked. The reason should be a string and can be up to 512 characters long.
A promise that resolves when the kick operation is completed. The request method sends the API request to Discord, and the remove method updates the local cache of members.
Removes a role from a member in the guild.
This method sends a request to the Discord API to remove the specified role from the member. It ensures that the member's ID is available before proceeding with the request.
The ID of the role to be removed.
Unbans a user from the guild with the specified reason.
This method performs an unban operation, which removes a ban from a user in the guild. It sends a request to the Discord API to lift the ban and includes a reason for the action in the audit log.
The ID of the user to be unbanned. This ID uniquely identifies the user within the guild.
The reason for unbanning the user. This reason will be included in the audit log for the unban operation, which helps to track why the user was unbanned. The reason should be a string and can be up to 512 characters long.
A promise that resolves when the unban operation is completed. The request method sends the API request to Discord.
Represents a member of the guild.