Finding Twitterstars

Finding and connecting with local social media 'superstars' can be a valuable short-cut for anyone trying to ramp up quickly in online social environments. These enthusiasts are knowledgeable about social media tools, are highly-connected, and understand well how to succeed in the online social environment.

But how do you find the local social media superstars? Today, many of these individuals use Twitter. The "Local Twitterstars" mini-application below takes any US geographic search area that you provide and returns a feed of the top five most followed individuals on Twitter who have been recently active in the region. Below is a more detailed explanation of how I built this mini-application. I also posted an update here.

Location (City, State):

Radius (in Miles):


This mini-application uses the Twitter Search API, the Twitter REST API, Yahoo! Pipes, and some simple HTML.

  1. The simple HTML form above constructs a server GET request through both hidden and user-populated form fields.
  2. This constructed URL queries a custom-built Yahoo! Pipe that takes the location from the URL and converts it to LAT-LONG coordinates.
  3. A Twitter search API query is then constructed by the Pipe using the LAT-LONG and radius data, returning the 100 most recent tweets in this region. Depending on your search area, this could include only very recent tweets or could span a much longer time period. Twitter has some internal smarts around matching the coordinates to include a variety of data that users put into the location field of their profile, including towns, zip codes, iPhone GPS coordinates, etc.
  4. The Pipe then takes all the tweets and constructs a series of queries to the Twitter REST API, pulling back user profile data from each user behind the tweets.
  5. After removing duplicates, the Pipe selects the top five most followed users in the list and builds an RSS feed presenting the username, a link to their twitter account, and the current number of followers they have.

NOTE: If the feed request is empty, try changing your search criteria. It's also quite possible that Twitter is struggling to handle load and won't fulfill the API requests.

If you find this mini-application useful, please let me know. Suggestions for modifications and improvements are always welcome.

Comments

This looks great, but how

This looks great, but how about us on the other side of the pond? anything for the British?

Appears to work

Appears to work internationally thanks to both Yahoo! and Twitter API, although we're subject to how they interpret location. I've tried Edmonton, AB and London, UK and got results from both queries.

Hi Bentrem, If you're

Hi Bentrem,
If you're willing, try again. I suspected this might be some non-US bias of the localization feature, so I tried "Edmonton, AB" myself, and I got a response. Might just be the fickle Twitter API. There are some known issues with it playing nicely with Pipes and my non-programmatic approach doesn't do error handling well. Or for that matter, at all.

Invisible failure ... the

Invisible failure ... the worst kind.

I just ran it using Edmonton, AB ... Yahoo!Pipes really is quite amazing ... and found that my 531 didn't show up.

--bentrem

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options