書籍検索API

書籍管理アプリに使用できそうな書籍APIを調査しました。

openBD

 openBDは、書籍のメタデータを無料で提供しているAPIです。ISBNコードを指定することで、書籍のメタデータを取得できます。 登録の必要なくデータを使用できるAPIです。レスポンスの速さを売りにしているようです。

実行例

https://api.openbd.jp/v1/get?isbn=978-4-87311-565-8&pretty

レスポンス例

          
[
  {
    "onix": {
      "RecordReference": "9784873115658",
      "NotificationType": "03",
      "ProductIdentifier": {
        "ProductIDType": "15",
        "IDValue": "9784873115658"
      },
      "DescriptiveDetail": {
        "ProductComposition": "00",
        "ProductForm": "BZ",
        "Measure": [
          {
            "MeasureType": "01",
            "Measurement": "21",
            "MeasureUnitCode": "mm"
          }
        ],
        "Collection": {
          "CollectionType": "10",
          "TitleDetail": {
            "TitleType": "01",
            "TitleElement": [
              {
                "TitleElementLevel": "02",
                "TitleText": {
                  "content": "THEORY/IN/PRACTICE"
                }
              }
            ]
          }
        },
        "TitleDetail": {
          "TitleType": "01",
          "TitleElement": {
            "TitleElementLevel": "01",
            "TitleText": {
              "collationkey": "リーダブル コード : ヨリ ヨイ コード オ カク タメ ノ シンプル デ ジッセンテキ ナ テクニック",
              "content": "リーダブルコード : より良いコードを書くためのシンプルで実践的なテクニック"
            }
          }
        },
        "Contributor": [
          {
            "SequenceNumber": "1",
            "ContributorRole": [
              "A01"
            ],
            "PersonName": {
              "content": "Boswell, Dustin"
            }
          },
          {
            "SequenceNumber": "2",
            "ContributorRole": [
              "A01"
            ],
            "PersonName": {
              "content": "Foucher, Trevor"
            }
          },
          {
            "SequenceNumber": "3",
            "ContributorRole": [
              "B06"
            ],
            "PersonName": {
              "content": "角 征典"
            }
          },
          {
            "SequenceNumber": "4",
            "ContributorRole": [
              "A01"
            ],
            "PersonName": {
              "content": " フォシェ トレバー"
            }
          },
          {
            "SequenceNumber": "5",
            "ContributorRole": [
              "A01"
            ],
            "PersonName": {
              "content": "ボズウェル ダスティン"
            }
          }
        ],
        "Language": [
          {
            "LanguageRole": "01",
            "LanguageCode": "jpn",
            "CountryCode": "JP"
          }
        ],
        "Extent": [
          {
            "ExtentType": "11",
            "ExtentValue": "237",
            "ExtentUnit": "03"
          }
        ]
      },
      "CollateralDetail": {
        "TextContent": [
          {
            "TextType": "03",
            "ContentAudience": "00",
            "Text": "コードは理解しやすくなければならない。本書はこの原則を日々のコーディングの様々な場面に当てはめる方法を紹介する。名前の付け方、コメントの書き方など表面上の改善について。コードを動かすための制御フロー、論理式、変数などループとロジックについて。またコードを再構成するための方法。さらにテストの書き方などについて、楽しいイラストと共に説明する。日本語版ではRubyやgroongaのコミッタとしても著名な須藤功平氏による解説を収録。"
          },
          {
            "TextType": "04",
            "ContentAudience": "00",
            "Text": "理解しやすいコード
第1部 表面上の改善(名前に情報を詰め込む
誤解されない名前
美しさ
コメントすべきことを知る
コメントは正確で簡潔に)
第2部 ループとロジックの単純化(制御フローを読みやすくする
巨大な式を分割する
変数と読みやすさ)
第3部 コードの再構成(無関係の下位問題を抽出する
一度に1つのことを
コードに思いを込める
短いコードを書く)
第4部 選抜テーマ(テストと読みやすさ
「分/時間カウンタ」を設計・実装する)
付録 あわせて読みたい"
          }
        ],
        "SupportingResource": [
          {
            "ResourceContentType": "01",
            "ContentAudience": "01",
            "ResourceMode": "03",
            "ResourceVersion": [
              {
                "ResourceForm": "02",
                "ResourceVersionFeature": [
                  {
                    "ResourceVersionFeatureType": "01",
                    "FeatureValue": "D502"
                  },
                  {
                    "ResourceVersionFeatureType": "04",
                    "FeatureValue": "9784873115658.jpg"
                  }
                ],
                "ResourceLink": "https://cover.openbd.jp/9784873115658.jpg"
              }
            ]
          }
        ]
      },
      "PublishingDetail": {
        "Imprint": {
          "ImprintIdentifier": [
            {
              "ImprintIDType": "19",
              "IDValue": "87311"
            }
          ],
          "ImprintName": "オライリー・ジャパン : オーム社"
        },
        "PublishingDate": [
          {
            "PublishingDateRole": "01",
            "Date": ""
          }
        ]
      },
      "ProductSupply": {
        "MarketPublishingDetail": {
          "MarketPublishingStatus": "00",
          "MarketPublishingStatusNote": "1;"
        },
        "SupplyDetail": {
          "ProductAvailability": "99"
        }
      }
    },
    "hanmoto": {
      "datecreated": "2015-11-16 18:20:34",
      "dateshuppan": "2012-06",
      "datemodified": "2015-11-16 18:20:34"
    },
    "summary": {
      "isbn": "9784873115658",
      "title": "リーダブルコード : より良いコードを書くためのシンプルで実践的なテクニック",
      "volume": "",
      "series": "",
      "publisher": "オライリー・ジャパン : オーム社",
      "pubdate": "2012-06",
      "cover": "https://cover.openbd.jp/9784873115658.jpg",
      "author": "Boswell,Dustin/著 Foucher,Trevor/著 角征典/翻訳 フォシェトレバー/著 ほか"
    }
  }
]
          
        

Google Books APIs

 Google Book APIsも書籍のメタデータを提供しているAPIです。isbnコードはもちろん、書籍のタイトルや著者名などで検索することができます。

実行例

https://www.googleapis.com/books/v1/volumes?q=リーダブルコード

レスポンス例

          
{
  "kind": "books#volumes",
  "totalItems": 1439,
  "items": [
    {
      "kind": "books#volume",
      "id": "Wx1dLwEACAAJ",
      "etag": "owJWC592PvU",
      "selfLink": "https://www.googleapis.com/books/v1/volumes/Wx1dLwEACAAJ",
      "volumeInfo": {
        "title": "リーダブルコード",
        "subtitle": "より良いコードを書くためのシンプルで実践的なテクニック",
        "authors": [
          "Dustin Boswell",
          "Trevor Foucher"
        ],
        "publisher": "O'Reilly Media, Inc.",
        "publishedDate": "2012-06",
        "description": "読んでわかるコードの重要性と方法について解説",
        "industryIdentifiers": [
          {
            "type": "ISBN_10",
            "identifier": "4873115655"
          },
          {
            "type": "ISBN_13",
            "identifier": "9784873115658"
          }
        ],
        "readingModes": {
          "text": false,
          "image": false
        },
        "pageCount": 237,
        "printType": "BOOK",
        "averageRating": 5,
        "ratingsCount": 1,
        "maturityRating": "NOT_MATURE",
        "allowAnonLogging": false,
        "contentVersion": "preview-1.0.0",
        "imageLinks": {
          "smallThumbnail": "http://books.google.com/books/content?id=Wx1dLwEACAAJ&printsec=frontcover&img=1&zoom=5&source=gbs_api",
          "thumbnail": "http://books.google.com/books/content?id=Wx1dLwEACAAJ&printsec=frontcover&img=1&zoom=1&source=gbs_api"
        },
        "language": "ja",
        "previewLink": "http://books.google.co.jp/books?id=Wx1dLwEACAAJ&dq=9784873115658&hl=&cd=1&source=gbs_api",
        "infoLink": "http://books.google.co.jp/books?id=Wx1dLwEACAAJ&dq=9784873115658&hl=&source=gbs_api",
        "canonicalVolumeLink": "https://books.google.com/books/about/%E3%83%AA%E3%83%BC%E3%83%80%E3%83%96%E3%83%AB%E3%82%B3%E3%83%BC%E3%83%89.html?hl=&id=Wx1dLwEACAAJ"
      },
      "saleInfo": {
        "country": "JP",
        "saleability": "NOT_FOR_SALE",
        "isEbook": false
      },
      "accessInfo": {
        "country": "JP",
        "viewability": "NO_PAGES",
        "embeddable": false,
        "publicDomain": false,
        "textToSpeechPermission": "ALLOWED",
        "epub": {
          "isAvailable": false
        },
        "pdf": {
          "isAvailable": false
        },
        "webReaderLink": "http://play.google.com/books/reader?id=Wx1dLwEACAAJ&hl=&source=gbs_api",
        "accessViewStatus": "NONE",
        "quoteSharingAllowed": false
      },
      "searchInfo": {
        "textSnippet": "読んでわかるコードの重要性と方法について解説"
      }
    }
  ]
}
          
        

参考

更新履歴