def get_client(self, request=None):

        if not isinstance(request, oauth.Request):
            request = self.get_oauth_request()
        client_key = request.get_parameter('oauth_consumer_key')
        if not client_key:
            raise Exception('Missing "oauth_consumer_key" parameter in ' \
                'OAuth "Authorization" header')

        client = models.Client.get_by_key_name(client_key)
        if not client:
            raise Exception('Client "%s" not found.' % client_key)

        return client
Return the client from the OAuth parameters.
dataset/ETHPy150Open cloudera/hue/desktop/core/ext-py/python-oauth2/example/appengine_oauth.py/OAuthHandler.get_client