#NEWLINE# def create_permission_url( self , scope , redirect_uri = None ) : #NEWLINE# #INDENT# query_params = dict ( client_id = self . api_key , scope = ',' . join ( scope ) ) #NEWLINE# if redirect_uri : #NEWLINE# #INDENT# query_params [ 'redirect_uri' ] = redirect_uri #NEWLINE# #UNINDENT# return ( '%s/oauth/authorize?%s' % ( self . site , urllib . parse . urlencode ( query_params ) ) )