Skip to content

Instantly share code, notes, and snippets.

@wong2
Created April 25, 2012 12:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wong2/2489404 to your computer and use it in GitHub Desktop.
Save wong2/2489404 to your computer and use it in GitHub Desktop.
get weibo access token
from config import APP_SECRET, APP_KEY
from weibopy.auth import OAuthHandler
CALLBACK = ""
auth = OAuthHandler(APP_KEY, APP_SECRET, CALLBACK)
url = auth.get_authorization_url()
print "open this in the browser: " + url
code = raw_input("input the code: ")
auth.get_access_token(code)
# the sdk is: https://github.com/wuyuntao/weibopy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment