Description • Composition • How It Works • How To Use • TODO • Endpoints • Demo • Notes
I am an active user on Goodreads, who is always updating my current readings and also adding new books to my want-to-read
list. Most of the times when I want to buy a book, I go through my list, pick a book, and then I go check on some shops if there is a good price. So, I decided to create this application to automate the process.
🏪 Stores available:
This application is divided in two parts:
The project already has the latest version of the frontend compiled. However, you can also access the source code repository through the link above.
-
Make a request to the Goodreads API in order to figure it out if the user exists.
-
Get the books from the
want-to-read
list and parse. -
For each book, get the price in the available stores, and send a socket.io event to the client.
This three points are the main steps of how the application works. The endpoint that sends a request to the Goodreads API is the /user/books.
-
git clone
-
npm install
-
Set environment variable
GOODREADS_API_KEY
You can read more about Goodreads API here.
-
This application is just a sample of an idea, so it requires alot of optimaizations, like reducing the number of renders.
-
Add more shops.
-
Add more options to the search, like searching by a book isbn or name, instead of just searching by the Goodreads username.
There is an endpoint that lets you get the books prices from all stores by using the isbn. You can make a GET request to /shops/prices?isbn=ISBN_NUM for instance: https://goodreads-price-tracker.herokuapp.com//shops/prices?isbn=9781451673319.
https://goodreads-price-tracker.herokuapp.com/
Each book has many versions, each one with an isbn and/or isbn13, and sometimes the stores does not have all those versions. Goodreads usually has many versions of the same book, because of that, to get some reasonable results, it is important to add the right version to the Goodreads.
In order to get better results I recommend you to run this locally because the Heroku has a timeout after 30 seconds without a response, which most of the cases is not enough.