Skip to content

Instantly share code, notes, and snippets.

View mattccrampton's full-sized avatar
🎯
Focusing

Matt Crampton mattccrampton

🎯
Focusing
View GitHub Profile
@mattccrampton
mattccrampton / tweet.py
Last active November 4, 2017 05:39
Tweet from python using tweepy
import tweepy
def get_api(cfg):
auth = tweepy.OAuthHandler(cfg['consumer_key'], cfg['consumer_secret'])
auth.set_access_token(cfg['access_token'], cfg['access_token_secret'])
return tweepy.API(auth)
def main():
# Fill in the values noted in previous step here
cfg = {