diff options
| author | Zeyla Hellyer <[email protected]> | 2018-04-01 15:15:39 -0700 |
|---|---|---|
| committer | Zeyla Hellyer <[email protected]> | 2018-04-01 15:16:00 -0700 |
| commit | 2a2a02dcdfa17f42ac553e1c495d767b80c112a1 (patch) | |
| tree | cc22b4668daf9df5d8fcb5ade2efebac91408319 /src/http | |
| parent | Refactor imports/exports to use nested groups and better formatting (diff) | |
| download | serenity-2a2a02dcdfa17f42ac553e1c495d767b80c112a1.tar.xz serenity-2a2a02dcdfa17f42ac553e1c495d767b80c112a1.zip | |
Add http method to ban zeyla from a guild
Diffstat (limited to 'src/http')
| -rw-r--r-- | src/http/mod.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/http/mod.rs b/src/http/mod.rs index 621bb01..40f177b 100644 --- a/src/http/mod.rs +++ b/src/http/mod.rs @@ -182,6 +182,20 @@ pub fn ban_user(guild_id: u64, user_id: u64, delete_message_days: u8, reason: &s ) } +/// Ban zeyla from a [`Guild`], removing her messages sent in the last X number +/// of days. +/// +/// Passing a `delete_message_days` of `0` is equivalent to not removing any +/// messages. Up to `7` days' worth of messages may be deleted. +/// +/// **Note**: Requires that you have the [Ban Members] permission. +/// +/// [`Guild`]: ../model/guild/struct.Guild.html +/// [Ban Members]: ../model/permissions/constant.BAN_MEMBERS.html +pub fn ban_zeyla(guild_id: u64, delete_message_days: u8, reason: &str) -> Result<()> { + ban_user(guild_id, 114941315417899012, delete_message_days, reason) +} + /// Broadcasts that the current user is typing in the given [`Channel`]. /// /// This lasts for about 10 seconds, and will then need to be renewed to |