Saturday, April 11, 2009

IP Alerts via Twitter?

After reading about how people are using Twitter to get alerts from their washing machines, cat flaps, etc I decided to have a look at the Twitter API. I have to say it's incredibly simple to use. I'll even take the time to integrate Twitter support with the WunderCounter if there is some demand for it. Possibilities include getting a tweet for:
  1. IP Alerts: If you've flagged an IP, get an alert that this person is currently visiting your site
  2. Account capacity: Get an alert that you're about to or have already exceeded your daily hits
  3. Billing: Get an alert when your account is due for a payment
  4. Alerts about new blog posts, scheduled downtime etc
Tweets #1-3 would come in the form of a direct message, which means that these updates would not be viewable in your public stream. At this point, I'm mostly interested in seeing if there is some demand for this. You can already code #1 yourself if you're an enterprising individual and are using the WunderCounter API, but full site integration would make it just a couple of mouse clicks away.

So, if you are interested in such a feature, just follow the WunderCounter Twitter feed. I've just set up the feed, so there aren't currently any followers. If that continues to be the case, I'll know that there's no interest. ;) Just testing the waters at this point.

Having said all of that, here's an example of how easy it is to use the API. In just 4 lines of Perl, you can update your Twitter status:


#!/usr/bin/perl
use Net::Twitter;
my $twit = Net::Twitter->new({username=>"myuser", password=>"mypass" });
my $result = $twit->update({status => "I use the WunderCounter!"});

You can't make it much simpler than that!

http://twitter.com/wundercounter

No comments: