View Single Post
Old 01-23-2011, 09:59 AM   #5
nickdma
Enthusiast
nickdma began at the beginning.
 
Posts: 41
Karma: 12
Join Date: Oct 2010
Device: Tablet PC
Quote:
Originally Posted by kovidgoyal View Post
I had a look at the goodreads api a while back and like most web 2.0 vintage APIs it is designed for use only from other websites, and low traffic ones at that. One request per second is unworkable, even routing through a central server, calibre has too many users. I'm not criticizing GoodReads for that, they have their business model, it's just not usable from calibre.

And no, there is no OAuth code in calibre, I've never been able to make heads or tails of OAuth, something about OAuth and my brain just don't get along.
I found a snippit on someone's blog that eluded to the "request per second" being when using "devkey" related API calls, and not "OAuth" calls. I'm trying to look further into that. I may just email Goodreads and ask them to clarify and see if what's being discussed here would be a problem.

I also found this, a python example to add books to a shelf, complete with OAuth.

http://www.goodreads.com/topic/show/...w-to-use-oauth

It uses a library for OAuth, and I don't know if a library can be part of a GUI plugin, or if the library would have to be included with Calibre for a plugin to use it. Hopefully it could be included with just the plugin so Calibre wouldn't have to carry additional libraries others may not use.

I didn't see any need for a web service to accept a callback URL. I think the plugin would require an additional menu entry (or a GUI) with a mechanism to send the user to the GoodReads site to login and approve plugin access. I think that's just a one time thing though, which is the nice part of OAuth, the user allows your app to access their data, and that's it, no login each use.

Edit: I posted on their dev forum asking for clarification on the TOS. http://www.goodreads.com/topic/show/...rvice-question
nickdma is offline   Reply With Quote