How to use the twitterapi.oauthtwitter function in TwitterAPI

To help you get started, we’ve selected a few TwitterAPI examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github CollabQ / CollabQ / common / twitter.py View on Github external
def get_access_request():
  logging.info("Access Token")
  token = memcache.client.get('request_token')
  memcache.client.delete('request_token')

  request_token = oauth.OAuthToken.from_string(token)
  twitter       = oauthtwitter.OAuthApi(settings.TWITTER_CONSUMER_KEY,
                                        settings.TWITTER_CONSUMER_SECRET,
                                        request_token)
  logging.info("Access Token")
  access_token = twitter.getAccessToken()

  return access_token
github CollabQ / CollabQ / common / twitter.py View on Github external
def get_api(access_token):
  twitter = oauthtwitter.OAuthApi(settings.TWITTER_CONSUMER_KEY,
                                       settings.TWITTER_CONSUMER_SECRET,
                                       access_token)
  return twitter