Is there a javascript API to get a book summary based on ISBN? [closed]

…衆ロ難τιáo~ 提交于 2020-01-15 07:56:08

问题


I'm working in a very limited environment and I cannot use any API that requires authentication. The API at https://openlibrary.org would be perfect, but it does not serve a book summary. All I need to do is get a book summary (akin to the back cover of a book) from an ISBN number that I pass.

I have to use javascript because I only have access to the client-side code.


回答1:


Based on Amazon's Product Advertising API documentation:

  • ItemLookup
  • EditorialReview Response Group

You should be able to, without authentication, pull up the Product Description for a book using a request to:

http://webservices.amazon.com/onca/xml?
    Service=AWSECommerceService&
    AWSAccessKeyId=[AWS Access Key ID]&
    Operation=ItemLookup&
    ItemId=[ISBN]&
    IdType=ISBN&
    ResponseGroup=EditorialReview&
    Condition=All&
    Timestamp=[YYYY-MM-DDThh:mm:ssZ]&
    Signature=[Request Signature]

Yes, you may have to sign up for an Amazon access key, and there may be rate-limiting which applies to your request, but this should get you there without maintaining a user authentication session.




回答2:


A Google Web Search API might be helpful too (https://www.google.com/search?q=0596002068&)

Then consequently scrape the first result using something like https://www.mashape.com/warting/scrapegoat#!endpoint-scrapePrerendered

I was able to get the summary of the book like below:



来源:https://stackoverflow.com/questions/19979137/is-there-a-javascript-api-to-get-a-book-summary-based-on-isbn

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!