def _build_dummy_request(key, secret, body=''):
    dummy_request = OAuthRequest()
    oauth2_request = apiclient.build_request(dummy_request.uri, key, secret,
                                             body)
    for arg, value in oauth2_request.iteritems():
        dummy_request.addArg(arg, value)
    return dummy_request
Exemple #2
0
def _build_dummy_request(key, secret, body=''):
    dummy_request = OAuthRequest()
    oauth2_request = apiclient.build_request(dummy_request.uri, key, secret,
                                             body)
    for arg, value in oauth2_request.iteritems():
        dummy_request.addArg(arg, value)
    return dummy_request
def _build_dummy_request(key, secret, method='GET'):
    dummy_request = OAuthRequest()
    oauth2_request = apiclient.build_request(dummy_request.uri, key, secret,
                                             method)
    print 'OAuth2 signed URL:\n', oauth2_request.to_url()
    for arg, value in oauth2_request.iteritems():
        dummy_request.addArg(arg, value)
    print 'Dummy URLPath:\n', dummy_request.URLPath()
    return dummy_request