如何使用亚马逊商品广告 API 查找图书的版本?

发布于 2024-09-17 21:21:35 字数 169 浏览 3 评论 0原文

有没有办法使用亚马逊商品广告 API 根据 ISBN 查找书籍的各个版本?

更一般地说,查找书籍的版本元数据有哪些不同的选择?我唯一确定的一个是来自 worldcat 的 xISBN api

在我的网站上,我们有一个“更多版本”按钮,供人们搜索书籍时使用。所以我会进行大量查询(并缓存它们)。

Is there a way to look up the various editions of a book based on its ISBN using the Amazon Product Advertising API?

And, more generally, what are the various choices for looking up edition metadata on a book? Only one I know of for sure is the xISBN api from worldcat

On my site we have a "more editions" button for when people search for books.. so I'd be making a lot of queries (and cacheing them).

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

維他命╮ 2024-09-24 21:21:35

您可以使用 OCLC 的 xISBN API - 给它一个 ISBN,它会给出你会得到一组相同“作品”的所有 ISBN——其他版本、翻译等。它会给你这样的东西:

<?xml version="1.0" encoding="UTF-8"?>
<rsp xmlns="http://worldcat.org/xid/isbn/" stat="ok">
    <isbn form="BA" year="2004" lang="eng" ed="2nd ed.">0596002815</isbn>
    <isbn form="BA DA" year="1999" lang="eng">1565928938</isbn>
    <isbn form="BA" year="1999" lang="eng" ed="1st ed.">1565924649</isbn>
</rsp>

不幸的是,它不是免费的。 这是定价

You could use OCLC's xISBN API - give it an ISBN and it gives you a set of all ISBNs that are the same "work" - other editions, translations, etc. It will give you something like this:

<?xml version="1.0" encoding="UTF-8"?>
<rsp xmlns="http://worldcat.org/xid/isbn/" stat="ok">
    <isbn form="BA" year="2004" lang="eng" ed="2nd ed.">0596002815</isbn>
    <isbn form="BA DA" year="1999" lang="eng">1565928938</isbn>
    <isbn form="BA" year="1999" lang="eng" ed="1st ed.">1565924649</isbn>
</rsp>

Unfortunately, it is not free. Here is the pricing.

掩饰不了的爱 2024-09-24 21:21:35

看看 https://sourceforge.net/projects/isbntools/files/latest/download 。命令 isbn versions ISBN 将为您提供您想要的...

如果您是开发人员,您拥有 https://pypi.python.org/pypi/isbntools

Take a look at https://sourceforge.net/projects/isbntools/files/latest/download. The command isbn editions ISBN will give you what you want...

If you are a developer you have https://pypi.python.org/pypi/isbntools.

遇到 2024-09-24 21:21:35

这个问题已经很老了,但为了完整起见,我要补充一点,亚马逊产品广告 API 确实提供了一种查找书籍其他版本(和 ISBN 编号)的方法,但这涉及两个 ItemLookup 查询:

  • 获取父商品 ASIN 的第一个查询,亚马逊称之为“Authority Non Buyable”;这是一个虚拟产品,没有产品页面,只是儿童产品的容器。
  • 第二个查询列出该父项的子项。

两个查询都必须包含以下参数:

  • ResponseGroup=RelatedItems,ItemAttributes
  • RelationshipType=AuthorityTitle

第一个包含 ISBN 编号的查询如下所示:

...&IdType =ISBN&ItemId=9780345803481

<RelatedItems>
    <Relationship>Parents</Relationship>
    <RelationshipType>AuthorityTitle</RelationshipType>
    <RelatedItemCount>1</RelatedItemCount>
    <RelatedItemPageCount>1</RelatedItemPageCount>
    <RelatedItemPage>1</RelatedItemPage>
    <RelatedItem>
        <Item>
            <ASIN>B0058NLWEC</ASIN>
            ...
        </Item>
    </RelatedItem>
</RelatedItems>

第二个查询使用第一个查询返回的父 ASIN B0058NLWEC 执行:

...&IdType=ASIN&ItemId=B0058NLWEC< /code>

<RelatedItems>
    <Relationship>Children</Relationship>
    <RelationshipType>AuthorityTitle</RelationshipType>
    <RelatedItemCount>42</RelatedItemCount>
    <RelatedItemPageCount>5</RelatedItemPageCount>
    <RelatedItemPage>1</RelatedItemPage>
    <RelatedItem>
        <Item>
            <ASIN>1445026570</ASIN>
            <ItemAttributes>
                <EAN>9781445026572</EAN>
                <ISBN>1445026570</ISBN>
                ...
            </ItemAttributes>
            ...
        </Item>
    </RelatedItem>
    <RelatedItem>
        <Item>
            <ASIN>1471305015</ASIN>
            <ItemAttributes>
                <EAN>9781471305016</EAN>
                <ISBN>1471305015</ISBN>
                ...
            </ItemAttributes>
            ...
        </Item>
    </RelatedItem>
    ...
</RelatedItems>

这列出了亚马逊已知的本书的所有版本:精装本、平装本、Kindle、有声读物……

This question is old, but for the sake of completeness, I'll add that Amazon Product Advertising API does offer a way to look up other editions (and ISBN numbers) of a book, but this involves two ItemLookup queries:

  • a first query to get the ASIN of the parent item, that Amazon calls Authority Non Buyable; this is a virtual product that has no product page, and is just a container for children products.
  • a second query to list the child items of this parent.

Both queries must include the following parameters:

  • ResponseGroup=RelatedItems,ItemAttributes
  • RelationshipType=AuthorityTitle

The first query with an ISBN number would look like:

...&IdType=ISBN&ItemId=9780345803481

<RelatedItems>
    <Relationship>Parents</Relationship>
    <RelationshipType>AuthorityTitle</RelationshipType>
    <RelatedItemCount>1</RelatedItemCount>
    <RelatedItemPageCount>1</RelatedItemPageCount>
    <RelatedItemPage>1</RelatedItemPage>
    <RelatedItem>
        <Item>
            <ASIN>B0058NLWEC</ASIN>
            ...
        </Item>
    </RelatedItem>
</RelatedItems>

The second query is performed with the parent ASIN returned by the first query, B0058NLWEC:

...&IdType=ASIN&ItemId=B0058NLWEC

<RelatedItems>
    <Relationship>Children</Relationship>
    <RelationshipType>AuthorityTitle</RelationshipType>
    <RelatedItemCount>42</RelatedItemCount>
    <RelatedItemPageCount>5</RelatedItemPageCount>
    <RelatedItemPage>1</RelatedItemPage>
    <RelatedItem>
        <Item>
            <ASIN>1445026570</ASIN>
            <ItemAttributes>
                <EAN>9781445026572</EAN>
                <ISBN>1445026570</ISBN>
                ...
            </ItemAttributes>
            ...
        </Item>
    </RelatedItem>
    <RelatedItem>
        <Item>
            <ASIN>1471305015</ASIN>
            <ItemAttributes>
                <EAN>9781471305016</EAN>
                <ISBN>1471305015</ISBN>
                ...
            </ItemAttributes>
            ...
        </Item>
    </RelatedItem>
    ...
</RelatedItems>

This lists all editions of this book as known by Amazon: hardcover, paperback, Kindle, audiobook, ...

不气馁 2024-09-24 21:21:35

ISBN DB 提供远程访问 API,它将返回 XML 格式的各种元数据。通过浏览其网站上的条目,一些 ISBN 条目还包含版本信息。

查看此 API 示例响应:

<?xml version="1.0" encoding="UTF-8"?>
<ISBNdb server_time="2005-07-29T03:02:22">
 <BookList total_results="1">
  <BookData book_id="paul_laurence_dunbar" isbn="0766013502">
   <Title>Paul Laurence Dunbar</Title>
   <TitleLong>Paul Laurence Dunbar: portrait of a poet</TitleLong>
   <AuthorsText>Catherine Reef</AuthorsText>
   <PublisherText publisher_id="enslow_publishers">
    Berkeley Heights, NJ: Enslow Publishers, c2000.
   </PublisherText>
   <Summary>
    A biography of the poet who faced racism and devoted himself
    to depicting the black experience in America.
   </Summary>
   <Notes>
    "Works by Paul Laurence Dunbar": p. 113-114.
    Includes bibliographical references (p. 124) and index.
   </Notes>
   <UrlsText></UrlsText>
   <AwardsText></AwardsText>
   <Prices>
    <Price store_id="alibris" is_in_stock="1" is_new="0"
           check_time="2005-07-29T01:18:18" price="14.92"/>
    <Price store_id="amazon" is_in_stock="1" is_new="1"
           check_time="2005-07-29T01:18:20" price="26.60" />
   </Prices>
  </BookData>
 </BookList>
</ISBNdb>

另外,这里是关于“图书集合”中属性的特定文档响应 XML。

The ISBN DB provides a remote access API that will return various meta data formatted as XML. From browsing entries on their website, some of the ISBN entries include edition information as well.

Check out this API sample response:

<?xml version="1.0" encoding="UTF-8"?>
<ISBNdb server_time="2005-07-29T03:02:22">
 <BookList total_results="1">
  <BookData book_id="paul_laurence_dunbar" isbn="0766013502">
   <Title>Paul Laurence Dunbar</Title>
   <TitleLong>Paul Laurence Dunbar: portrait of a poet</TitleLong>
   <AuthorsText>Catherine Reef</AuthorsText>
   <PublisherText publisher_id="enslow_publishers">
    Berkeley Heights, NJ: Enslow Publishers, c2000.
   </PublisherText>
   <Summary>
    A biography of the poet who faced racism and devoted himself
    to depicting the black experience in America.
   </Summary>
   <Notes>
    "Works by Paul Laurence Dunbar": p. 113-114.
    Includes bibliographical references (p. 124) and index.
   </Notes>
   <UrlsText></UrlsText>
   <AwardsText></AwardsText>
   <Prices>
    <Price store_id="alibris" is_in_stock="1" is_new="0"
           check_time="2005-07-29T01:18:18" price="14.92"/>
    <Price store_id="amazon" is_in_stock="1" is_new="1"
           check_time="2005-07-29T01:18:20" price="26.60" />
   </Prices>
  </BookData>
 </BookList>
</ISBNdb>

Also, here is specific documentation on attributes in 'books collection' response XML.

深海蓝天 2024-09-24 21:21:35

1)相同标题的搜索
2)迭代响应列表(对于大多数书籍来说,应该有 5-10 个结果,具有通用标题(例如“Python 编程”)的书籍将产生大量结果,因此可能无法解决)
3) 查看 ISBN 号 + 发布日期的差异

我不记得有相同的直接 api。

1) search with the title being same
2) Iterate over the response list (which should be of 5-10 results for most books, books with generic titles like say "Python Programming" will result in lot of results hence may not work out)
3) See difference in ISBN number + Published Date

I don't recall there being a direct api for the same.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文