Ruby Amazon book search

2019-03-11 10:21发布

Does anybody have a good Ruby script for finding books (or other products) on Amazon using their API?

3条回答
够拽才男人
2楼-- · 2019-03-11 10:54

VonC's third link was a partial answer. It led me to ruby-aaws (note - different from ruby-aws).

I then found this blog post with an example of using it.

查看更多
该账号已被封号
3楼-- · 2019-03-11 10:56

I suppose that kind of script would have to use Ruby/AWS, like this test.

You have here an quick introduction.

And you have there a full example involving searching books.

response = r.keyword_search
('ruby programming', 'books')
查看更多
趁早两清
4楼-- · 2019-03-11 11:17

I've been using Amazon/ECS with great success. One important point is that it's not GPLed (whereas Ruby/AWS seems to be), so if it's important in your case, take care.

Here is a sample:

require 'amazon/ecs'

# default options; will be camelized and converted 
# to REST request parameters.
Amazon::Ecs.options = {:aWS_access_key_id => [your access key]}
res = Amazon::Ecs.item_search('ruby')

You may also want to have a look at some example of integration with the Mephisto blogging system.

cheers!

查看更多
登录 后发表回答