Skip to content


Subversion checkout URL

You can clone with
Download ZIP


Callback URL #7

wants to merge 1 commit into from

2 participants


I'd like to propose the ability to submit callback URL's. I banged this up in a few mins but it's pretty ugly. The change is in oauth2/ but should bubble up so that it's easier for the integrating app to specify.


+1 Would be really nice to get this in there.


Also the attached pull request is not (and is probably not intended to be) a valid solution. It simply hardcodes the callback http://localhost:8080/haha.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Oct 10, 2011
  1. @parthasundaram

    Support callback URL

    parthasundaram authored
This page is out of date. Refresh to see the latest.
Showing with 7 additions and 3 deletions.
  1. +7 −3 liclient/oauth2/
10 liclient/oauth2/
@@ -414,10 +414,11 @@ def from_consumer_and_token(cls, consumer, token=None,
'oauth_nonce': cls.make_nonce(),
'oauth_version': cls.version,
parameters = defaults
if token:
parameters['oauth_token'] = token.key
if token.verifier:
@@ -587,6 +588,7 @@ def request(self, uri, method="GET", body=None, headers=None,
redirections=httplib2.DEFAULT_MAX_REDIRECTS, connection_type=None):
DEFAULT_CONTENT_TYPE = 'application/x-www-form-urlencoded'
if not isinstance(headers, dict):
headers = {}
@@ -595,7 +597,9 @@ def request(self, uri, method="GET", body=None, headers=None,
if body and method == "POST" and not is_multipart:
parameters = dict(parse_qsl(body))
- parameters = None
+ parameters = {}
+ parameters['oauth_callback'] = "http://localhost:8080/haha"
req = Request.from_consumer_and_token(self.consumer, token=self.token,
http_method=method, http_url=uri, parameters=parameters)
@@ -699,4 +703,4 @@ def signing_base(self, request, consumer, token):
def sign(self, request, consumer, token):
key, raw = self.signing_base(request, consumer, token)
- return raw
+ return raw
Something went wrong with that request. Please try again.