The moment it happens
Send e-books to your Kindle from Telegram
Forward an e-book to your Telegram bot and it arrives on your Kindle a few minutes later.
- Runs
- The moment it happens
- Apps
- Outlook, Telegram
- AI
- Not needed
- Access
- Mail.Send; bot token
Send this to your assistant
Create a ClickRuntime automation: when I send a file to my Telegram bot, email it from my Outlook to my Kindle address and reply in Telegram when it's sent.
First time? Adding ClickRuntime to your assistant takes about two minutes.
Why use it
Why teams use this automation
Getting a document onto a Kindle usually means finding the file on a computer, opening email, attaching it and remembering the Kindle address. On a phone, that's fiddly enough that articles and books pile up unread.
Sharing the file to a Telegram bot takes two taps from any app. The email to Amazon is sent from your approved Outlook address, so the file appears in your library without you touching a computer.
What you get out of it
Two taps from your phone
Share a file to the bot from your downloads or another chat. There's no email to write and no address to remember.
Uses your approved address
Amazon only accepts documents from addresses you've approved. Sending from your own Outlook keeps it on that list.
Confirmation in the chat
The bot replies once the email has gone, so you know the file is on its way. If something fails, you hear that too.
Works for anything Kindle reads
EPUB, PDF and Word files all work. Reading material from colleagues or newsletters goes to the same place.
How it works
What happens, step by step
You send or share a file to your Telegram bot.
It checks the message came from you and has a file attached.
The file is downloaded and emailed from your Outlook address to your Kindle address.
The bot replies in the chat to confirm it was sent.
Before it runs live
- Connect Outlook
- Connect Telegram
- Paste your automation's link into the other app's webhook settings
What you get
Build your own
Need it to work differently?
Your own rules
Conditions, thresholds, filters and exceptions, written the way you'd explain them to a colleague.
Any number of apps
One automation can read from one app and update several others. Over 248 apps are ready, and anything with an API works too.
AI where it helps
Summaries, classification, extraction and drafts use ClickRuntime's built-in AI, with no extra key.
On a schedule or on each event
Runs as often as every 5 minutes, or the moment an app sends an event, and keeps track of what it already handled.
Changes you can ask for
- Act only on the items that match your own rules, and skip the rest
- Add an AI step, for example to summarize, sort or draft a reply
- Add another app, for example also send it to Slack
- Combine it with other Outlook and Telegram steps into one automation
Under the hood
The code that runs this automation
GRAPH = "https://graph.microsoft.com/v1.0"
TG = "https://api.telegram.org"
import base64
from clickruntime import on_event, credentials, http
MY_CHAT_ID = 123456789
KINDLE = "yourname@kindle.com"
@on_event
def handle(event):
msg = (event.json or {}).get("message", {})
doc = msg.get("document")
if msg.get("chat", {}).get("id") != MY_CHAT_ID or not doc:
return {"skipped": True}
bot = f"{TG}/bot{credentials.secret('TELEGRAM_BOT_TOKEN')}"
path = http.get(f"{bot}/getFile", params={"file_id": doc["file_id"]}).json()["result"]["file_path"]
data = http.get(f"{TG}/file/bot{credentials.secret('TELEGRAM_BOT_TOKEN')}/{path}").content
att = {"@odata.type": "#microsoft.graph.fileAttachment", "name": doc["file_name"], "contentBytes": base64.b64encode(data).decode()}
mail = {"message": {"subject": doc["file_name"], "body": {"contentType": "Text", "content": "Sent via Telegram"},
"toRecipients": [{"emailAddress": {"address": KINDLE}}], "attachments": [att]}}
h = {"Authorization": f"Bearer {credentials.connection('microsoft', 'work')}"}
http.post(f"{GRAPH}/me/sendMail", headers=h, json=mail).raise_for_status()
http.post(f"{bot}/sendMessage", json={"chat_id": MY_CHAT_ID, "text": f"Sent {doc['file_name']} to your Kindle"})
return {"sent": doc["file_name"]}FAQ
Common questions
Which file types work?
Is there a file size limit?
Can other people use my bot?
What permissions does it need?
Does it need AI?
How many runs does it use?
Can I change how it works?
Related
You might also like
Get a Telegram ping for each sale and thank the buyer by email
Every sale pings your phone on Telegram and the customer gets a thank-you email from your Outlook address.
See how it worksSend this week's Outlook events to a Telegram group
Each morning your Telegram group gets today's, tomorrow's and the rest of the week's events from Outlook.
See how it worksSort your Outlook inbox and get urgent emails on Telegram
New emails are labelled by topic, and the urgent ones reach your phone on Telegram with a one-line summary.
See how it worksKeep exploring
Set up “Send e-books to your Kindle from Telegram” from your assistant
Copy the prompt above, or connect your assistant first. Free plan, no credit card.