goodreads-bookshelf
Version:
Facade of Goodreads Bookshelf
29 lines (20 loc) • 1.06 kB
Markdown
[](https://travis-ci.com/brombaut/goodreads-bookshelf)
[](https://codecov.io/gh/brombaut/goodreads-bookshelf/)


```bash
npm i goodreads-bookshelf
```
You will need to provide your own [Goodreads API](https://www.goodreads.com/api) developer ID and key.
```typescript
import { GoodreadsBookshelf, Book, Shelf } from "goodreads-bookshelf";
const myBookshelf: GoodreadsBookshelf =
new GoodreadsBookshelf("Goodread Id", "Goodreads Key");
await myBookshelf.getBooks();
const myReadingBooks: Book[] = myBookshelf.readingBooks();
const myReadBooks: Book[] = myBookshelf.readBooks();
const groupedByYear: { [key: number]: Book[] } = myBookshelf.readBooksGroupedByYear();
```