aboutsummaryrefslogtreecommitdiff
path: root/discord/http.py
diff options
context:
space:
mode:
Diffstat (limited to 'discord/http.py')
-rw-r--r--discord/http.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/discord/http.py b/discord/http.py
index ba531a91..d7e90b88 100644
--- a/discord/http.py
+++ b/discord/http.py
@@ -278,6 +278,18 @@ class HTTPClient:
return self.get(url, params=params, bucket=_func_())
+ def pin_message(self, channel_id, message_id):
+ url = '{0.CHANNELS}/{1}/pins/{2}'.format(self, channel_id, message_id)
+ return self.put(url, bucket=_func_())
+
+ def unpin_message(self, channel_id, message_id):
+ url = '{0.CHANNELS}/{1}/pins/{2}'.format(self, channel_id, message_id)
+ return self.delete(url, bucket=_func_())
+
+ def pins_from(self, channel_id):
+ url = '{0.CHANNELS}/{1}/pins'.format(self, channel_id)
+ return self.get(url, bucket=_func_())
+
# Member management
def kick(self, user_id, guild_id):