Signing Amazon Request with amazon-ecs-0.5.6
FRI, 21 AUG 2009
If you are using Amazon Web Services or Product Advertising API, Amazon probably had been bugging you to sign your requests by August 15.
If you have not, by now all your requests should have failed. Some of you who are using amazon-ecs have contacted me last week, if there’s a patch to solve this issue; yep there is, the latest version, amazon-ecs-0.5.6 is able to sign your requests. Thanks to Dan Milne for the initial patch; I have also applied a few small patches to ensure that it works smoothly.
sudo gem update amazon-ecs
To sign the request you would need AWS secret key, which you can generate from Amazon associate account page.
# Include your secret key
Amazon::Ecs.options = {:aWS_access_key_id => [your developer token], :aWS_secret_key => [your secret access key]}
# Or you can also set it through 'configure' method
Amazon::Ecs.configure do |options|
options[:aWS_access_key_id] = [your access key]
options[:aWS_secret_key] = [you secret key]
end
# Search like usual
res = Amazon::Ecs.item_search('ruby', {:response_group => 'Medium', :sort => 'salesrank'})

