buzzing

July 20, 2011 @ 14:33

Google need to hurry up and release a G+ API, so I can replace the sidebar there -> with my G+ feed rather than my Buzz feed.

Sorta feels like Buzz is irrelevant now, doesn’t it?

Google Buzz

November 4, 2010 @ 15:48

You may have noticed the word ‘buzz’ at the top of the right column on my site here. Yes, that does link to my Google Buzz account. Most things I post there, will also show up on this page.

This is actually quite easy to do.

The first thing you need is Google’z Buzz client library. I’m using Python, so I use this one here. The docs explain pretty well how to use it, but the basic code looks like this:

buzz_client = buzz.Client()
buzz_client.oauth_scopes=[buzz.FULL_ACCESS_SCOPE]
buzz_client.use_anonymous_oauth_consumer(oauth_display_name=g.buzz_name)
buzz_client.build_oauth_access_token(YOUR_API_KEY, YOUR_API_SECRET)

That will get you an active buzz client. Here’s how I fetch a list of my own posts:

try:
    for post in buzz_client.posts(type_id='@self', user_id='@me', max_results=10).data:
        # do something with your posts here

except buzz.RetrieveError, e:
    # handle errors

The things I’m most interested in are the photos I post to my Picasa dropbox (usually taken from my phone while out in pubs and such). Photos are found in p.attachments, you’ll have to check for one with the attribute type equal to ‘photo’ (videos are unsuprisingly, ‘video’). Then you have attachment.preview and attachment.link - these are what show up on my page here.

Also interesting is attachment.type ‘article’.