예제 #1
0
 def invite_link(self):
     # https://discordapp.com/oauth2/authorize?client_id=468281173072805889&scope=bot&permissions=35840&guild_id=208895639164026880
     if self._invite_link: return self._invite_link
     permissions = Permissions()
     permissions.read_messages = True 
     permissions.send_messages = True 
     permissions.embed_links = True 
     permissions.attach_files = True 
     self._invite_link = 'https://discordapp.com/oauth2/authorize?' + urlencode({
         'client_id': self.user.id,
         'scope': 'bot',
         'permissions': permissions.value
     })
     return self.invite_link
예제 #2
0
    def invite_link(self):
        '''The invite link for the bot'''

        if self._invite_link: return self._invite_link
        permissions = Permissions()
        permissions.read_messages = True
        permissions.send_messages = True
        permissions.embed_links = True
        permissions.attach_files = True
        self._invite_link = 'https://discordapp.com/oauth2/authorize?' + urlencode(
            {
                'client_id': self.config['oauth']['client_id'],
                'scope': 'bot',
                'permissions': permissions.value
            })
        return self._invite_link