Skip to content

Every 15 minutes

Track your spending from receipt emails

Each receipt that lands in your inbox is posted to Slack, and you always know this month's total.

Runs
Every 15 minutes
Apps
Gmail, Slack
AI
Optional
Access
Gmail gmail.readonly; Slack chat:write

Send this to your assistant

Create a ClickRuntime automation: when a receipt from Uber Eats or Deliveroo arrives in Gmail, post the restaurant and amount to my #spending channel in Slack and keep a running total for the month.

Paste it into your assistant. It tells you what it will send or change before it runs live.

First time? Adding ClickRuntime to your assistant takes about two minutes.

Why use it

Why teams use this automation

A team that orders lunch or snacks through a delivery service ends up with a mailbox full of receipts and no idea what the monthly total is. Someone asks at the end of the month why the food budget is blown, and tallying means opening forty emails, finding the amounts and typing them into a spreadsheet. By then it is too late to change anything.

Every 15 minutes Gmail is searched for receipts from the delivery sender. The amount and items are parsed from each, a summary goes to Slack, and a running counter for the month is updated. The tally is part of every post, so spending is visible as it grows.

It suits office managers, small teams with a food allowance and individuals who want to watch their own takeaway spend.

What you get out of it

  • Spending is visible before it overruns

    A running monthly figure in each post lets a team notice at mid-month that they are already at 80 percent of the budget, while there is still time to adjust.

  • No one tallies receipts by hand

    The amounts are read and added automatically, which removes a tedious month-end task and the arithmetic errors that come with copying figures between emails. Accuracy improves too, since no one retypes figures.

  • The team sees who ordered what

    Posting items to a shared channel avoids double orders and shows what the group likes, which can inform a standing order or a better deal. It can even start friendly conversations about the next order.

  • A clear record for expenses

    Receipts in Slack with amounts form a searchable log, helpful when reimbursing a person or reconciling the card statement later. Reimbursement conversations are much calmer with the evidence at hand.

  • Reset happens on its own each month

    The counter starts over at the beginning of a new month, so figures never mix across periods and you never need to clear anything. Nothing is left behind from the previous month.

How it works

What happens, step by step

  1. Every 15 minutes, ClickRuntime checks Gmail for receipt or order emails from Uber or Deliveroo, skipping any it has already counted.

  2. It reads the amount from each receipt.

  3. It adds the amount to your running total for the month.

  4. Each receipt is posted to your #spending Slack channel with the shop, amount and month-to-date total.

Before it runs live

  • Connect Google through your own Google app (a one-time, 10-minute setup), so it works with your own Gmail
  • Connect Slack, then invite the app to the channel (type /invite @ClickRuntime there)

What you get

RunsEvery 15 minutes
Track your spending from receipt emailstoday, 9:00Succeeded
Slack · #spending🍔 Northwind Noodle Bar: £18.40 (month so far £142.75)

Build your own

Need it to work differently?

This template is a starting point. Copy the prompt and change it, or describe a different automation from scratch, with your own conditions, more apps or an AI step. Your assistant writes it, tests it and runs it on ClickRuntime.
  • 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 Google Sheets
  • Combine it with other Gmail and Slack steps into one automation

Under the hood

The code that runs this automation

This is the Python script that runs each time the automation starts. Your AI assistant writes it for you when you send the prompt, and you allow each step in your assistant. To change how the automation works, describe the change to your assistant and it updates the script for you. For every function it can use, see the script reference.
order_receipt_emails_to_slack_with_a_spend_tally.pyexample
import re
from datetime import date
from google.oauth2.credentials import Credentials
from googleapiclient.discovery import build
from clickruntime import on_trigger, credentials, state, notify, report_fetched

@on_trigger
def run(event):
    gmail = build("gmail", "v1", credentials=Credentials(credentials.connection("google", "work")), cache_discovery=False)
    seen = set(state.get("seen") or [])
    msgs = gmail.users().messages().list(userId="me", maxResults=20,
                                         q="from:(uber.com OR deliveroo.co.uk) subject:(receipt OR order) newer_than:2d").execute().get("messages", [])
    new = [m for m in msgs if m["id"] not in seen]
    report_fetched(len(new))
    if not new:
        return {"new": 0}
    month = date.today().strftime("%Y-%m")
    total = state.get(f"total:{month}") or 0.0
    for m in new:
        msg = gmail.users().messages().get(userId="me", id=m["id"], format="metadata", metadataHeaders=["Subject"]).execute()
        subject = msg["payload"]["headers"][0]["value"]
        amount = float((re.search(r"£\s?(\d+[.,]\d{2})", msg["snippet"]) or re.search(r"(\d+\.\d{2})", msg["snippet"]) or [0, "0"])[1].replace(",", "."))
        place = re.sub(r"^(Your|Order|Receipt).*?(from|for)\s+", "", subject, flags=re.I)
        total += amount
        notify.slack(f"🍔 {place}: £{amount:.2f} (month so far £{total:.2f})", channel="#spending")
    state.set(f"total:{month}", total)
    state.set("seen", [m["id"] for m in msgs])
    return {"new": len(new), "month_total": total}

FAQ

Common questions

Which delivery services does it work with?
Any service that emails receipts. You provide the sender address, and the amount and items are read from the message text. Services with unusual receipt layouts may need the parsing adjusted, which your AI assistant can do.
Can it warn me when the budget is reached?
Yes. Add a threshold, such as $400 a month, and a warning is posted when the tally passes it. The check uses the same running counter, so it adds no extra effort. The warning is posted just once.
Does the AI step matter here?
It is optional. Plain parsing handles well-structured receipts, and the built-in AI can help when receipts vary in layout. Without it the amounts are still read where the format is consistent. Results depend on how consistent the receipts are.
What permissions does it need?
Gmail gmail.readonly; Slack chat:write. Nothing else in your accounts is used.
Does it need AI?
No, but you can ask for an AI step (for example a summary). It then uses ClickRuntime's built-in AI allowance.
How many runs does it use?
One run each time it checks. Checks that find nothing new and stop right away aren't counted.
Can I change how it works?
Yes. Describe the change to your AI assistant, for example a different schedule, channel or filter. It updates the automation, tests it and tells you what changed.

Set up “Track your spending from receipt emails” from your assistant

Copy the prompt above, or connect your assistant first. Free plan, no credit card.