Amazon Web Service with ColdFusion

October 14, 2006 8:44 PM
Related Categories: Web Dev

Update: I have revised the code, don't use below but here instead.

I was just looking for how to use CF to process Amazons ecommerce web service. Specifically I wanted to use the ItemSearch functionality. The code below will loop through a few categories, query amazon, loop through the total number of pages (10 results per page) and output the results.

You will need to put in your own AWSAccessKeyId. Also, this is just test code. It isn't optimized. You will probably wnat to clean it up.

I am using Bluedragon on my server, which supports CFPause. CFMX doesn't at this point, and so you can remove that code and replace with something else. The reason I pause is because this will send a lot of requests to amazon. They request that you only query their service once a second.

You will not want to use this code in your web site directly, but run this to store the information locally, then use that local information for output. This way you don't query the Amazon service on every page read.

see other blog entry


Like this entry? Subscribe to my blog.

Comments (moderation on)

Sponsors


Savvy Content Manager