Giter VIP home page Giter VIP logo

goodreads-parser's Introduction

goodreads-parser

Goodreads book parser for Node.js

Install

yarn add goodreads-parser

Usage

First, import library

const GoodReadsParser = require("goodreads-parser");

try {
  const data = await GoodReadsParser.getBook({ isbn: '1524759783' });
  console.log("Book Data::", data);
} catch (error) {
  console.log("error", error);
}

Response:

{
  title: 'The Three-Body Problem',
  originalTitle: '三体',
  author: 'Liu Cixin',
  description: `"1967: Ye Wenjie witnesses Red Guards beat her father to death during China's Cultural Revolution. This singular event will shape not only the rest of her life but also the future of mankind.<br><br>Four decades later, Beijing police ask nanotech engineer Wang Miao to infiltrate a secretive cabal of scientists after a spate of inexplicable suicides. Wang's investigation will lead him to a mysterious online game and immerse him in a virtual world ruled by the intractable and unpredicatable interaction of its three suns.<br><br>This is the Three-Body Problem and it is the key to everything: the key to the scientists' deaths, the key to a conspiracy that spans light-years and the key to the extinction-level threat humanity now faces."`,
  cover: 'https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1545742427l/36262331._SY475_.jpg',
  isbn13: '9781788543002',
  pages: 434,
  rating: 4.06,
  ratingCount: 173247,
  reviewsCount: 17086,
  language: undefined,
  genres: [
    'Science Fiction',
    'Fiction',
    'Cultural > China',
    'Science Fiction Fantasy',
    'Audiobook',
    'Fantasy',
    'Science Fiction > Aliens',
    'Novels',
    'Speculative Fiction',
    'Cultural > Asia'
  ],
  id: '36262331',
  url: 'https://www.goodreads.com/book/show/36262331-the-three-body-problem'
}

API

You can fetch book data by providing ISBN13 or just the url of the book in format like this: https://www.goodreads.com/book/show/{ID}

By ISBN13

const result = await GoodReadsParser.getBook({ isbn: '1524759783' });

By URL

const result = await GoodReadsParser.getBook({ url: "https://www.goodreads.com/book/show/36262331-the-three-body-problem" });

goodreads-parser's People

Contributors

shakogegia avatar ahmadthakur avatar dependabot[bot] avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.