TwitterLove: Applying the Social Graph API

John Musser, February 18th, 2008

Want to visualize someone’s “following” list on Twitter? Thanks to this creative application of the Google Social Graph API you can. Even though Social Graph API was just released a couple weeks ago it didn’t take long before creative developers began seeing ways to put it to use. And as you can see in our TwitterLove profile the application uses 2 other APIs including the Twitter API to create a timeline and the Japanese service to create thumbnails.

For a bit of insight into traversing through the social graph, developer Ko-Ji described to us his application flow using his own id of ‘fkoji’ as the example user to lookup:

1. Send an initial request to with arguments callback=loop&q=fkoji&edo=1
2. In the callback we look for “types” in any “node_referenced” nodes returned (where “types” are “me” or “contact”).
3. If type is “me”, then we have a starting point URL for this person.
4. If type is “contact”, then we push the node to a contacts array.
5. If contacts array is not empty, then we send a request to social graph api again with a query of contacts twitter urls.
6. In the callback we do the same process as above and if we find “fkoji” in their contact, we know they are contacts of each other, so we put a heart icon.
7. We use the service to get their thumbnail images.

You can also get more details doing a View Source on the TwitterLove HTML.

Update: In the comments ReadWriteWeb’s Marshall Kirkpatrick points to a very slick mashup from Kent Brewster: BlogJuice. It uses the brand new MyBlogLog API and a variety of other services and tools (like Yahoo! Pipes) and “looks for a MyBlogLog identifier on the page you’re on, and uses the MyBlogLog API to dig out information about its reader roll”. Read Kent’s post for lots of details with a live example with his own site, and see Marshall’s coverage here.

Both comments and pings are currently closed.

3 Responses to “TwitterLove: Applying the Social Graph API”

February 18th, 2008
at 1:40 am
Comment by: » Twitter + Social Graph Web Notes: Design | Strategy | Marketing

[...] the Social Graph API to Twitter | TwitterLove via Programmableweb: “the application uses 2 other APIs including the Twitter API to create a timeline and the [...]

February 18th, 2008
at 1:16 pm
Comment by: Marshall Kirkpatrick

Didn’t work for me. I think BlogJuice built on MBL kicks this one’s butt, fwiw. Would love to see PW coverage of that one.

February 18th, 2008
at 1:49 pm
Comment by: John Musser

Hi Marshall, thanks for the link to Kent’s BlogJuice, very slick! Will add this as Update to the main post.

Follow the PW team on Twitter

APIs, mashups and code. Because the world's your programmable oyster.

John Musser
Founder, ProgrammableWeb

Adam DuVander
Executive Editor, ProgrammableWeb. Author, Map Scripting 101. Lover, APIs.