Torrent Status via Twitter

I’ve been wanting to use twitter to interact with my uTorrent downloads for a while. I already have a system set up that tweets me when a download has finished, but I wanted more functionality, ideally the ability to add torrents and get the overall status of my downloads.

Thankfully uTorrent have created a nice little api that lets you do pretty much everything you would want, I used this uTorrent Python library, that lets you interact with the uTorrent api. I then made a simple c# win forms app (needs changing into a command line app really) that would make various calls to the Python library. Initially the only functionality is the current status of downloads, but now I have the basics in place I can add features fairly easily.

At the moment the application reads my latest tweets, I have already created some code todo this for my Home Automation System, and then when a tweet matches the ‘status’ command, I fire off the call to the api to get the status of every download in my client. The returned list is then parsed, and any active downloads are extracted and returned to the main method. This then processes the returned strings and replies back to my original tweet with the status of my downloads.

The next step is to add the ability to add new torrent files straight from a tweet, this should be fairly straightforward, the tweet would contain the location of the .torrent file, the system would then make the call to the uTorrent api with the location of the file to be downloaded.

Leave a Reply

Your email address will not be published. Required fields are marked *

*