From 415ca9a7748f77ffcb1000eca2a703cd856a576a Mon Sep 17 00:00:00 2001 From: rooni Date: Mon, 18 Sep 2017 19:31:20 +0200 Subject: [PATCH] Add webhook.url --- discord/webhook.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/discord/webhook.py b/discord/webhook.py index 4d88a8d50..4f849877c 100644 --- a/discord/webhook.py +++ b/discord/webhook.py @@ -359,6 +359,11 @@ class Webhook: def __repr__(self): return '' % self.id + @property + def url(self): + """Returns the webhook's url.""" + return 'https://discordapp.com/api/webhooks/{}/{}'.format(self.id, self.token) + @classmethod def partial(cls, id, token, *, adapter): """Creates a partial :class:`Webhook`.