Calibre integration

350 views
Skip to first unread message

Szymon Szott

unread,
Dec 30, 2018, 8:37:00 AM12/30/18
to Standard Ebooks
Hi!

I was recently listening to an interview with Kovid Goyal, the creator of Calibre. I wasn't aware of this, but it turns out that Calibre has a "Get books" button which allows you to search among several ebook websites/stores, including Archive.org and Project Gutenberg. Perhaps it would be a good idea to add (or suggest adding) Standard Ebooks as well?

Best,
Szymon

Alex Cabal

unread,
Dec 30, 2018, 3:29:01 PM12/30/18
to standar...@googlegroups.com

Sure, why not get in touch to see what he thinks? I imagine Calibre just ingests an OPDS feed, which we have available at the bottom of the site.

--
You received this message because you are subscribed to the Google Groups "Standard Ebooks" group.
To unsubscribe from this group and stop receiving emails from it, send an email to standardebook...@googlegroups.com.
To post to this group, send email to standar...@googlegroups.com.
Visit this group at https://groups.google.com/group/standardebooks.
To view this discussion on the web visit https://groups.google.com/d/msgid/standardebooks/f6c3b955-f4a8-43f1-9cf8-f9acf534974f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

David Grigg

unread,
Dec 30, 2018, 11:07:27 PM12/30/18
to Standard Ebooks
The OPDS feed works just fine. There's an 'OPDS Client' plugin which works really well. I like it because it just shows me the books I don't have in my local Calibre library and then lets me download just those.

Szymon Szott

unread,
Dec 31, 2018, 5:47:12 AM12/31/18
to standar...@googlegroups.com
Alex, thanks for the go-ahead. I've written to Kovid on FB, let's see what happens.

David, I'm glad to hear that the OPDS client plugin is working, though I expect this to be an option for advanced users. I was hoping SE could be one of the ebook stores in the default installation of Calibre.

Best,
Szymon

You received this message because you are subscribed to a topic in the Google Groups "Standard Ebooks" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/standardebooks/czCsi3Wwd5s/unsubscribe.
To unsubscribe from this group and all its topics, send an email to standardebook...@googlegroups.com.

To post to this group, send email to standar...@googlegroups.com.
Visit this group at https://groups.google.com/group/standardebooks.

Paul

unread,
Jan 26, 2019, 1:30:19 PM1/26/19
to Standard Ebooks
What's the latest on this Szymon?

Szymon Szott

unread,
Jan 27, 2019, 12:49:08 AM1/27/19
to standar...@googlegroups.com

Hi Paul!

Thanks for asking; I've been meaning to write. Each ebook store in Calibre is developed as a separate plugin, and there's a dedicated forum thread, where (a) users can request stores and (b) developers can announce plugins. In 2017, user giJT requested SE to be added, but no one has responded so far. Is there anyone on this forum who has any experience in developing Calibre plugins? Based on David's info regarding the OPDS feed, it shouldn't be too hard, so if no one's done this before, I could take a swing at it.

Best,
Szymon

Alex Cabal

unread,
Jan 27, 2019, 1:01:48 PM1/27/19
to standar...@googlegroups.com
I haven't worked on Calibre plugins before but there's a ton so putting
a basic one together shouldn't be too tough, if someone wants to give it
a crack. Our OPDS feed is here: https://standardebooks.org/opds/

On 1/26/19 11:48 PM, Szymon Szott wrote:
> Hi Paul!
>
> Thanks for asking; I've been meaning to write. Each ebook store in
> Calibre is developed as a separate plugin, and there's a dedicated forum
> thread <https://www.mobileread.com/forums/showthread.php?t=132420>,
> where (a) users can request stores and (b) developers can announce
> plugins. In 2017, user giJT requested SE to be added, but no one has
> responded so far. Is there anyone on this forum who has any experience
> in developing Calibre plugins? Based on David's info regarding the OPDS
> feed, it shouldn't be too hard, so if no one's done this before, I could
> take a swing at it.
>
> Best,
> Szymon
>
> --
> You received this message because you are subscribed to the Google
> Groups "Standard Ebooks" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to standardebook...@googlegroups.com
> <mailto:standardebook...@googlegroups.com>.
> To post to this group, send email to standar...@googlegroups.com
> <mailto:standar...@googlegroups.com>.
> Visit this group at https://groups.google.com/group/standardebooks.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/standardebooks/CAEm%2BXfoHSXHHx2B8Uvf3eN8M2_DN995wdO38tu9bp42WmFUcEg%40mail.gmail.com
> <https://groups.google.com/d/msgid/standardebooks/CAEm%2BXfoHSXHHx2B8Uvf3eN8M2_DN995wdO38tu9bp42WmFUcEg%40mail.gmail.com?utm_medium=email&utm_source=footer>.

David Grigg

unread,
Jan 27, 2019, 5:33:13 PM1/27/19
to standar...@googlegroups.com
All of the plugins have open source code, so I'm thinking that looking at the code for some other store and also the OPDS plugin should make it simple. Though I'm not yet volunteering! My programming skills in general are getting very rusty.

Regards,

David
You received this message because you are subscribed to a topic in the Google Groups "Standard Ebooks" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/standardebooks/czCsi3Wwd5s/unsubscribe.
To unsubscribe from this group and all its topics, send an email to standardebook...@googlegroups.com.
To post to this group, send email to standar...@googlegroups.com.

Szymon Szott

unread,
Feb 17, 2019, 1:23:59 AM2/17/19
to Standard Ebooks
Hi everyone!

I've looked into this issue and can report the following progress (it's not much):

1. Here's the code for an example Calibre store plugin.
2. Having almost no knowledge of OPDS, I can't immediately see what links SE's OPDS XML with the OpenSearch XML used in the example.
3. I've had no luck in finding the OPDS plugin mentioned by David. It's not in Calibre's index of plugins, I can't find it with the UI:


If anyone knows how to move forward with this I'd be happy to pass the torch.

Best,
Szymon

David Grigg

unread,
Feb 17, 2019, 1:38:16 AM2/17/19
to Standard Ebooks
I'm not sure how I got the link, can't find it on a simple search here in Google Groups, but here's a link to the GitHub repository of the OPDS client by Steinar Bang.

Chris Brooks

unread,
Feb 17, 2019, 12:43:53 PM2/17/19
to standar...@googlegroups.com
I forked this repo last year to exclude the epub3 files which were the default it wanted to pull from our OPDS server. So this might be of help:


-Chris

On Sat, Feb 16, 2019 at 10:38 PM David Grigg <david...@gmail.com> wrote:
I'm not sure how I got the link, can't find it on a simple search here in Google Groups, but here's a link to the GitHub repository of the OPDS client by Steinar Bang.

--
You received this message because you are subscribed to the Google Groups "Standard Ebooks" group.
To unsubscribe from this group and stop receiving emails from it, send an email to standardebook...@googlegroups.com.

To post to this group, send email to standar...@googlegroups.com.
Visit this group at https://groups.google.com/group/standardebooks.

Szymon Szott

unread,
Mar 3, 2019, 2:08:58 AM3/3/19
to standar...@googlegroups.com

Thanks David and Chris for the suggestions! I've been comparing the relevant parts of the OPDS plugin and an example Calibre store plugin. It seems that the former implements what the latter calls from various calibre.gui2.store.* modules. Looking also at the code complexity, I think there should be an easier way than converting the OPDS plugin into a store plugin.

Here's what I found so far: the above-mentioned store plugin refers to Archive.org's OpenSearch XML which provides a "search URL":

<?xml version="1.0" encoding="UTF-8"?>
<OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/">
<ShortName>Internet Archive Search</ShortName>
<Description>Search archive.org's OPDS Catalog.</Description>
<Url template="https://bookserver.archive.org/opensearch?q={searchTerms}" type="application/atom+xml;profile=opds-catalog;kind=acquisition"/>
</OpenSearchDescription>

Similarly, other "store plugins" rely on the search capabilities of the store they're querying (through OpenSearch or parsing the web search results). Meanwhile SE's OPDS feed has a link to all ebooks: https://standardebooks.org/opds/all but I could not find a "search URL".

Alex, would it be possible to add OpenSearch to SE as Archive.org has done?

Best, Szymon

Alex Cabal

unread,
Mar 4, 2019, 5:24:30 PM3/4/19
to standar...@googlegroups.com
Can you clarify where that goes? Is that mean to go in the OPDS feed
root? I.e. standardebooks.org/opds? Or somewhere else?

On 3/3/19 1:08 AM, Szymon Szott wrote:
> Thanks David and Chris for the suggestions! I've been comparing the
> relevant parts of the OPDS plugin
> <https://github.com/brookscl/opds-reader/blob/master/calibre_plugin/model.py>and
> an example Calibre store plugin
> <https://github.com/kovidgoyal/calibre/blob/master/src/calibre/gui2/store/stores/archive_org_plugin.py>.
> It seems that the former implements what the latter calls from various
> |calibre.gui2.store.*|modules. Looking also at the code complexity, I
> think there should be an easier way than converting the OPDS plugin into
> a store plugin.
>
> Here's what I found so far: the above-mentioned store plugin refers to
> Archive.org's OpenSearch XML which provides a "search URL":
>
> <?xml version="1.0" encoding="UTF-8"?>
> <OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/">
> <ShortName>Internet Archive Search</ShortName>
> <Description>Search archive.org <http://archive.org>'s OPDS
> Catalog.</Description>
> <Url
> template="https://bookserver.archive.org/opensearch?q={searchTerms}"
> type="application/atom+xml;profile=opds-catalog;kind=acquisition"/>
> </OpenSearchDescription>
>
> Similarly, other "store plugins" rely on the search capabilities of the
> store they're querying (through OpenSearch or parsing the web search
> results). Meanwhile SE's OPDS feed has a link to all ebooks:
> https://standardebooks.org/opds/allbut I could not find a "search URL".
>
> Alex, would it be possible to add OpenSearch to SE as Archive.org has done?
>
> Best,Szymon
>
> --
> You received this message because you are subscribed to the Google
> Groups "Standard Ebooks" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to standardebook...@googlegroups.com
> <mailto:standardebook...@googlegroups.com>.
> To post to this group, send email to standar...@googlegroups.com
> <mailto:standar...@googlegroups.com>.
> Visit this group at https://groups.google.com/group/standardebooks.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/standardebooks/CAEm%2BXfobm3Kt7xnGfEE%2B38AVWPKM4_wCvtPbXw0PeTa0_LUtYw%40mail.gmail.com
> <https://groups.google.com/d/msgid/standardebooks/CAEm%2BXfobm3Kt7xnGfEE%2B38AVWPKM4_wCvtPbXw0PeTa0_LUtYw%40mail.gmail.com?utm_medium=email&utm_source=footer>.

Szymon Szott

unread,
Mar 6, 2019, 11:56:43 AM3/6/19
to standar...@googlegroups.com

Alex,

I'm afraid I can't help much as I know almost nothing about OPDS and Open Search. However, I've found this example which has:

<link type="application/opensearchdescription+xml" title="Search on test catalog" rel="search" href="opensearch.xml"/>

Perhaps this should go into https://standardebooks.org/opds/? Then the .xml file would need to be filled out according to the Open Search spec.

Best, Szymon

Alex Cabal

unread,
Mar 6, 2019, 3:22:54 PM3/6/19
to standar...@googlegroups.com
OK. I don't have time to figure this out at the moment but if anyone is
interested, please go for it!

On 3/6/19 10:56 AM, Szymon Szott wrote:
> Alex,
>
> I'm afraid I can't help much as I know almost nothing about OPDS and
> Open Search. However, I've found this example
> <https://feedbooks.github.io/opds-test-catalog/catalog/root.xml>which has:
>
> <link type="application/opensearchdescription+xml" title="Search on test
> catalog" rel="search" href="opensearch.xml"/>
>
> Perhaps this should go into https://standardebooks.org/opds/? Then the
> |.xml|file would need to be filled out according to the Open Search spec
> <https://github.com/dewitt/opensearch/blob/master/opensearch-1-1-draft-6.md>.
>
> Best,Szymon
>
> On Mon, Mar 4, 2019 at 11:24 PM Alex Cabal <al...@standardebooks.org
> <mailto:al...@standardebooks.org>> wrote:
>
> Can you clarify where that goes? Is that mean to go in the OPDS feed
> root? I.e. standardebooks.org/opds <http://standardebooks.org/opds>?
> Or somewhere else?
>
> On 3/3/19 1:08 AM, Szymon Szott wrote:
> > Thanks David and Chris for the suggestions! I've been comparing the
> > relevant parts of the OPDS plugin
> >
> <https://github.com/brookscl/opds-reader/blob/master/calibre_plugin/model.py>and
> > an example Calibre store plugin
> >
> <https://github.com/kovidgoyal/calibre/blob/master/src/calibre/gui2/store/stores/archive_org_plugin.py>.
> > It seems that the former implements what the latter calls from various
> > |calibre.gui2.store.*|modules. Looking also at the code complexity, I
> > think there should be an easier way than converting the OPDS
> plugin into
> > a store plugin.
> >
> > Here's what I found so far: the above-mentioned store plugin refers to
> > Archive.org's OpenSearch XML which provides a "search URL":
> >
> > <?xml version="1.0" encoding="UTF-8"?>
> > <OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/">
> > <ShortName>Internet Archive Search</ShortName>
> > <Description>Search archive.org <http://archive.org>
> <http://archive.org>'s OPDS
> > Catalog.</Description>
> > <Url
> >
> template="https://bookserver.archive.org/opensearch?q={searchTerms}
> <https://bookserver.archive.org/opensearch?q=%7BsearchTerms%7D>"
> > type="application/atom+xml;profile=opds-catalog;kind=acquisition"/>
> > </OpenSearchDescription>
> >
> > Similarly, other "store plugins" rely on the search capabilities
> of the
> > store they're querying (through OpenSearch or parsing the web search
> > results). Meanwhile SE's OPDS feed has a link to all ebooks:
> > https://standardebooks.org/opds/allbut I could not find a "search
> URL".
> >
> > Alex, would it be possible to add OpenSearch to SE as Archive.org
> has done?
> >
> > Best,Szymon
>
> --
> You received this message because you are subscribed to the Google
> Groups "Standard Ebooks" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to standardebook...@googlegroups.com
> <mailto:standardebook...@googlegroups.com>.
> To post to this group, send email to standar...@googlegroups.com
> <mailto:standar...@googlegroups.com>.
> Visit this group at https://groups.google.com/group/standardebooks.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/standardebooks/CAEm%2BXfqEFSM1%2B5TDps_vNK7ZG3iah-hwZyx-YVqNs1o2kqnp0A%40mail.gmail.com
> <https://groups.google.com/d/msgid/standardebooks/CAEm%2BXfqEFSM1%2B5TDps_vNK7ZG3iah-hwZyx-YVqNs1o2kqnp0A%40mail.gmail.com?utm_medium=email&utm_source=footer>.

InfiniteAnts

unread,
Feb 13, 2021, 11:49:02 PM2/13/21
to Standard Ebooks
Hi I have made a Calibre Source Plugin for Standard Ebooks. You can find it here. You should be able to install it straight from Calibre when the mods at Mobileread see my thread and add it to the Plugin Index. Till then you can download it from the thread or my repo and load it manually in Calibre.

Thanks a lot for this Standard Ebooks project. I've been enjoying the O. Henry collection.

David Grigg

unread,
Feb 13, 2021, 11:57:51 PM2/13/21
to Standard Ebooks
Wow, great stuff, well done. Seems to work perfectly. Thanks so much.

John Reid

unread,
Feb 14, 2021, 5:31:01 AM2/14/21
to Standard Ebooks
I see that your plugin also solves the format selection problem recently discussed in another thread, very nice work!

Alex Cabal

unread,
Feb 14, 2021, 11:22:09 AM2/14/21
to standar...@googlegroups.com
Great work, thanks! I see that JSWolf is already in there with his usual hating :)

On February 13, 2021 10:49:02 PM CST, InfiniteAnts <ferra...@gmail.com> wrote:
>Hi I have made a Calibre Source Plugin for Standard Ebooks. You can
>find it
>here. <https://www.mobileread.com/forums/showthread.php?t=337368> You
>should be able to install it straight from Calibre when the mods at
>Mobileread see my thread and add it to the Plugin Index. Till then you
>can
>download it from the thread or my repo
><https://github.com/InfiniteAnts/calibre-store-standardebooks> and load
Reply all
Reply to author
Forward
0 new messages