04-12-2024, 05:03 PM | #1 |
Junior Member
Posts: 9
Karma: 10
Join Date: May 2023
Device: Kobo Clara 2E
|
Calibre Access in Python Script
Hi,
I am trying to create a request bot in Discord. I successfully created it with movies and tv shows, and am working on getting books working now. I am confident I can get the book requests, but I also want an option for users to get a book sent to their email (mainly for Amazon's send to kindle). My goal is:
What I am curious, is there an API or module to interact with calibre through python? Really I would need to look for a book, grab an epub (convert if it doesn't exist), and send it via an email. I saw some other links but it seemed like that was creating an entire environments for it and it got me confused. |
04-12-2024, 09:05 PM | #2 |
Well trained by Cats
Posts: 30,573
Karma: 58055868
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Calibre has a powerful set of commandline tools.
Visit the online help: commandline tools for the gory details (no Pythons were harmed ) |
04-13-2024, 08:17 PM | #3 |
Junior Member
Posts: 9
Karma: 10
Join Date: May 2023
Device: Kobo Clara 2E
|
|
04-13-2024, 09:02 PM | #4 | ||
Wizard
Posts: 1,121
Karma: 1261763
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
|
Quote:
API documentation for the e-book editing tools: https://manual.calibre-ebook.com/en/polish.html You can use the API in your python scripts. To execute the script, you use this command: calibre-debug /path/to/your/python/script.py Quote:
Yes, using the Command Line Interface. Last edited by thiago.eec; 04-13-2024 at 09:07 PM. |
||
04-13-2024, 10:16 PM | #5 | |
Junior Member
Posts: 9
Karma: 10
Join Date: May 2023
Device: Kobo Clara 2E
|
Quote:
|
|
04-14-2024, 06:42 AM | #6 | |
Wizard
Posts: 1,121
Karma: 1261763
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
|
Quote:
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
How to run python script? | UserError | Kindle Developer's Corner | 1 | 01-09-2024 04:31 PM |
3.34 calibre-debug runs the script code under Python 3 | EbokJunkie | Conversion | 2 | 11-20-2018 08:43 PM |
how to use python script with windows xp | tuufbiz1 | Other formats | 12 | 01-08-2011 09:22 AM |
How do I get a shortcut for a Python script onto the taskbar in W7? | Sydney's Mom | Workshop | 6 | 03-28-2010 09:11 PM |
Nedd a little help with a python script | gandor62 | Calibre | 1 | 08-07-2008 10:59 PM |