[Booki-dev] Proposed API for archive.org integration

raj kumar rkumar at archive.org
Thu Apr 29 12:34:10 PDT 2010


Hi,

I met with Adam today and we came up with this very simple API for integration with archive.org

There would be two new services that booki.cc would provide, at the following URLs:

- http://booki.cc/edit/IA/bookId.epub
- http://booki.cc/download/IA/bookId.epub

(the actual urls could be different to fit with booki naming conventions)

The first url, /edit/IA/bookId.epub, would cause the booki editor to launch, pre-populated with an archive.org epub. The workflow would look something like this:

1 . Present log in dialog if user is not already logged in to booki.cc
2. Import IA epub, if this is the first time this book is being edited in booki
3. Open booki editor with the latest revision

The second url, /download/IA/bookId.epub, would cause a download of the latest version of the book in one of the following two ways:

1. If the book has already been cached in an archive.org item, then this service would issue a 302 redirect to something like
http://s3.us.archive.org/booki-bookId/bookId.epub
2. If the latest version of the book hasn't been cached yet, booki would generate the epub for the user, and then cache it for subsequent requests.


From the IA side, we would add a two links to archive.org, one to download the corrected epub, and one to open the editor.

For example, for this book:

http://www.archive.org/details/birdbookillustra00reedrich

In the list of available formats for download on the left, we would add "Corrected EPUB" below "EPUB". This link would point to
http://booki.cc/download/IA/birdbookillustra00reedrich.epub

Elsewhere on the page we would have text that says "Please help us correct the OCR data for this book on booki.cc", which a link that points to
http://booki.cc/edit/IA/birdbookillustra00reedrich.epub

What do you guys think?

-raj


More information about the Booki-dev mailing list