The moment it happens
Log receipts by sending a photo to Telegram
Snap a receipt, send it to your bot, and the merchant, date and amount are logged, with an SMS confirming what was saved.
- Runs
- The moment it happens
- Apps
- Telegram, Twilio
- AI
- Yes, uses the built-in AI allowance
- Access
- Telegram bot; Twilio messaging
Send this to your assistant
Create a ClickRuntime automation: when I send a receipt photo to my Telegram bot, pull out the merchant, date and amount, keep a log of it, and text me a confirmation.
First time? Adding ClickRuntime to your assistant takes about two minutes.
Why use it
Why teams use this automation
A contractor pays for fuel, materials and lunches on the road, then spends a Sunday each month matching crumpled receipts to card statements. Half the paper has faded by then, and some receipts never make it home at all.
Sending a photo to a Telegram bot takes seconds at the till. The details are read from the image straight away and kept in a running log, so the receipt can go in the bin and the expense is already recorded.
What you get out of it
Expenses captured at the till
The moment you pay is the moment you are most likely to remember the receipt. A photo sent there and then means nothing waits in a wallet for a month.
No typing amounts by hand
Merchant, date, total and currency are read from the photo. You only correct the odd one the image was too blurry to read.
A confirmation you can trust
The SMS repeats what was saved, so a misread total is caught while the receipt is still in your hand.
A log ready for your accountant
Every receipt sits in one list with its date and amount, ready to export at month end or tax time.
How it works
What happens, step by step
You send a receipt photo to your Telegram bot.
ClickRuntime downloads the photo and AI reads the merchant, date, total and currency from it.
The receipt is added to your expense log, and each photo is handled once even if Telegram resends it.
You get a text message confirming what was saved, such as "Saved: Northwind Fuel, 42.10 EUR".
Before it runs live
- Connect Telegram
- Connect Twilio
- 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
- Change what the AI looks for, or how it writes the result
- Add another app, for example also send it to Slack
- Combine it with other Telegram and Twilio steps into one automation
Under the hood
The code that runs this automation
from clickruntime import on_event, credentials, http, ai, state
from twilio.rest import Client
@on_event
def handle(event):
msg = (event.json or {}).get("message", {})
if not msg.get("photo") or state.get(f"seen:{msg['message_id']}"):
return {"skipped": True}
token = credentials.secret("TELEGRAM_BOT_TOKEN")
file_id = msg["photo"][-1]["file_id"]
path = http.get(f"https://api.telegram.org/bot{token}/getFile", params={"file_id": file_id}).json()["result"]["file_path"]
caption = msg.get("caption", "")
fields = ai.generate(f"Receipt photo {path}, caption: {caption}. Return merchant, date, total, currency.",
json_schema={"type": "object", "properties": {"merchant": {"type": "string"}, "date": {"type": "string"},
"total": {"type": "number"}, "currency": {"type": "string"}}}).json
receipts = state.get("receipts") or []
receipts.append(fields)
state.set("receipts", receipts)
state.set(f"seen:{msg['message_id']}", True)
sms = Client(credentials.secret("TWILIO_ACCOUNT_SID"), credentials.secret("TWILIO_AUTH_TOKEN"))
sms.messages.create(to="+15550100", from_="+15550199", body=f"Saved: {fields['merchant']}, {fields['total']} {fields['currency']}")
return fieldsFAQ
Common questions
What if the photo is blurry or cut off?
Does it handle receipts in other currencies?
Can more than one person send receipts?
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
Ping Telegram and text the customer on every new sale
Each new sale or lead pings you on Telegram, and the customer gets a thank-you text within seconds.
See how it worksText back missed callers and tell me on Telegram
When you miss a call, the caller gets a text straight away and you get a Telegram message with their number.
See how it worksSend a daily quiz question to Telegram and SMS
Every morning one new question from your list goes to your Telegram group and your SMS subscribers, with no repeats until the list runs out.
See how it worksKeep exploring
Set up “Log receipts by sending a photo to Telegram” from your assistant
Copy the prompt above, or connect your assistant first. Free plan, no credit card.