Last active
November 3, 2017 05:51
-
-
Save pinfort/9554d81f4415c1741f666e6b06200d27 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import tweepy | |
class Tweet(object): | |
""" | |
use tweepy | |
""" | |
def __init__(self): | |
consumer_key = os.environ.get("TWITTER_CONSUMER_KEY") | |
consumer_secret = os.environ.get("TWITTER_CONSUMER_SECRET") | |
access_token = os.environ.get("TWITTER_ACCESS_TOKEN") | |
access_secret = os.environ.get("TWITTER_ACCESS_SECRET") | |
auth = tweepy.OAuthHandler(consumer_key, consumer_secret) | |
auth.set_access_token(access_token, access_secret) | |
self.api = tweepy.API(auth) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment