Install tweepy via PyPI:
easy_install tweepy
Example usage with identi.ca:
import tweepy
username, password = "identi.ca_username", "identi.ca_password"
auth = tweepy.BasicAuthHandler(username, password)
api = tweepy.API(auth, host = 'identi.ca', api_root = '/api', secure = True)
api.verify_credentials()
if not api.verify_credentials():
print 'Unable to log in Identica!'
import sys; sys.exit(1)
else:
print 'Correctly logged in Identica!'
api.update_status('Updating using basic authentication via Tweepy!')
Resources
tweepy
- Website: http://tweepy.github.com/
- Git Repository: https://github.com/tweepy/tweepy
- Google Groups: http://groups.google.com/group/tweepy
- IRC Channel: freenode.net #tweepy
Here is how to build your own command line tool to twitter new messages: http://talkfast.org/2010/05/31/twitter-from-the-command-line-in-python-using-oauth.