All you need is python and Tweepy libary, and create a twitter "app"
Remember to set the permissions to read/write in the twitter app.
Install tweepy (linux).
Code: Select all
pip install tweepy
Code: Select all
import tweepy
import sys
# Update Twitter with Sabnzbd downloads
try:
(scriptname,directory,orgnzbname,jobname,reportnumber,category,group,postprocstatus,url) = sys.argv
except:
try:
#getting clean jobname from sabnznd
jobname = sys.argv[3]
except:
print "No commandline parameters found"
sys.exit(1)
CONSUMER_KEY = 'past consumer key'
CONSUMER_SECRET = 'past consumer secret'
ACCESS_TOKEN_KEY= 'past access token'
ACCESS_TOKEN_SECRET= 'past access token secret'
auth = tweepy.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET)
auth.secure = True
auth.set_access_token(ACCESS_TOKEN_KEY, ACCESS_TOKEN_SECRET)
api = tweepy.API(auth)
api.update_status(status="Sabnzbd: Download Finished: "+jobname)
Edit the last line if you would like to post something els
How to import the library in Windows i sadly do not know:/