#NEWLINE# def __init__( self , consumer_key , consumer_secret , access_token = None , token_type = 'bearer' ) : #NEWLINE# #INDENT# self . request_token_url = ( ( '%s/oauth2/token' % self . base_api_url ) % 'api' ) #NEWLINE# self . invalidate_token_url = ( ( '%s/oauth2/invalidate_token' % access_token . base_api_url ) % 'api' ) #NEWLINE# self . consumer_key = consumer_key #NEWLINE# self . consumer_secret = consumer_secret #NEWLINE# self . access_token = access_token #NEWLINE# self . token_type = token_type #NEWLINE# self . session = self . get_oauth_session ( ) #NEWLINE# self . auth = HTTPBasicAuth ( self . consumer_key , self . consumer_secret )