Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- import tweepy, time, sys
- argfile = str(sys.argv[1])
- #enter the corresponding information from your Twitter application:
- CONSUMER_KEY = ''#keep the quotes, replace this with your consumer key
- CONSUMER_SECRET = ''#keep the quotes, replace this with your consumer secret key
- ACCESS_KEY = '2992120279-'#keep the quotes, replace this with your access token
- ACCESS_SECRET = ''#keep the quotes, replace this with your access token secret
- auth = tweepy.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET)
- auth.set_access_token(ACCESS_KEY, ACCESS_SECRET)
- api = tweepy.API(auth)
- filename=open(argfile,'r')
- f=filename.readlines()
- filename.close()
- for line in f:
- api.update_status(line)
- time.sleep(1800)#Tweet every 30 minutes
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement