Blending the Google and Amazon Web Services

A blending of the Google and Amazon web service APIs.

Google doesn’t have a lock on the API concept. Other companies and sites, including online bookstore Amazon, have their own APIs. Mockerybird’s Book Watch Plus (http://mockerybird.com/bookwatch-plus/bookwatch-plus.cgi) blends the Google and Amazon APIs with a feed of information from the Book Watch service (http://onfocus.com/BookWatch/) to create a list of books, referrals to them in Google, and a list of items that people who bought that book on Amazon also bought. Figure 6-15 illustrates this.

Book Watch Plus

Figure 6-15. Book Watch Plus

How It Works

Book Watch Plus does several things to generate its page of information. First, it grabs a page of books most frequently mentioned on weblogs. That list is generated by another service run by Paul Bausch’s Book Watch service.

Book Watch Plus wrangles the ISBNs (unique identifiers for books) and then places a couple of calls. The first is to the Amazon web service for detailed information on the book. Then Google is queried via the Google Web API for items related to the book. All this information is aggregated on a regular basis rather than on the fly for each visitor. Results are cached in XML and displayed in the form of a web page via the HTML::Template Perl module.

Tip

You might think that with all this fetching and displaying of information, the hack ...

Get Google Hacks now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.