# @halkeye/gatsby-source-goodreads

> Get the public books from a shelf in Goodreads for use in Gatsby.

Latest version **0.1.0** (published 2020-12-01) · MIT license · 0 weekly downloads

## Install

```sh
npm install @halkeye/gatsby-source-goodreads
pnpm add @halkeye/gatsby-source-goodreads
yarn add @halkeye/gatsby-source-goodreads
bun add @halkeye/gatsby-source-goodreads
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.0 |
| Published | 2020-12-01 |
| First published | 2018-05-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 7.3 KB |
| Known vulnerabilities | 0 (+24 in 2 direct dependencies) |
| Install scripts | no |
| GitHub stars | 3 |
| Author | Gavin Mogan |
| Maintainers | halkeye |
| Keywords | goodreads, gatsby, gatsby-plugin |

## Links

- npm: https://www.npmjs.com/package/@halkeye/gatsby-source-goodreads
- Repository: https://github.com/halkeye/gatsby-source-goodreads
- Homepage: https://github.com/halkeye/gatsby-source-goodreads#readme
- Issues: https://github.com/halkeye/gatsby-source-goodreads/issues
- npm.io page: https://npm.io/package/@halkeye/gatsby-source-goodreads

## Dependencies (3)

- [pify](https://npm.io/package/pify.md) ^5.0.0
- [axios](https://npm.io/package/axios.md) ^0.21.0
- [xml2js](https://npm.io/package/xml2js.md) ^0.4.23

## Recent versions

- 0.1.0 (latest) — 2020-12-01
- 0.0.6 — 2018-05-25
- 0.0.5 — 2018-05-24
- 0.0.4 — 2018-05-24
- 0.0.3 — 2018-05-24
- 0.0.2 — 2018-05-24
- 0.0.1 — 2018-05-20

## README

# gatsby-source-goodreads

Source plugin for pulling your read books into Gatsby from Goodreads API.

## How to use
```javascript
// In your gatsby-config.js
module.exports = {
  plugins: [
    {
      resolve: "gatsby-source-goodreads",
      options: {
        developerKey: "IAmDeveloperKey",
        goodReadsUserId: "IAmGoodreadsUserId",
        userShelf: "to-read" //optional
      }
    }
  ],
}
```

## Plugin options

* **developerKey**: Use your [Goodreads developer API key](https://www.goodreads.com/api/keys)
* **goodReadsUserId**: The Goodreads user ID of the user to get data for.
* **userShelf**: _OPTIONAL_. read, currently-reading, to-read, etc.

## How to query your Goodread data using GraphQL

Below is a sample query for fetching the shelf's books. 

```graphql
query goodRead {
  allGoodreadsShelf(filter: {shelfNames: {in: ["currently-reading"]}}) {
    edges {
      node {
        shelfNames
        review {
          reviewID
          rating
          votes
          spoilerFlag
          dateAdded
          dateUpdated
        }
        book {
          bookID
          isbn
          isbn13
          textReviewsCount
          uri
          link
          title
          titleWithoutSeries
          imageUrl
          smallImageUrl
          largeImageUrl
          description
        }
      }
    }
  }
}
```

---
_Source: https://npm.io/package/@halkeye/gatsby-source-goodreads · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
