oauth2.py 文件源码

python
阅读 34 收藏 0 点赞 0 评论 0

项目:plugin.audio.spotify 作者: marcelveldt 项目源码 文件源码
def get_authorize_url(self, state=None):
        """ Gets the URL to use to authorize this app
        """
        payload = {'client_id': self.client_id,
                   'response_type': 'code',
                   'redirect_uri': self.redirect_uri}
        if self.scope:
            payload['scope'] = self.scope
        if state is None:
            state = self.state
        if state is not None:
            payload['state'] = state

        urlparams = urllibparse.urlencode(payload)

        return "%s?%s" % (self.OAUTH_AUTHORIZE_URL, urlparams)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号