On a schedule
Post a monthly summary of your Supabase figures to Slack
On the 1st of each month, Slack gets a short written summary of last month's figures from your Supabase table, with the changes from the month before.
- Runs
- On a schedule
- Apps
- Slack, Supabase
- AI
- Yes, uses the built-in AI allowance
- Access
- Supabase read; Slack chat:write
Send this to your assistant
Create a ClickRuntime automation: on the 1st of each month, summarise last month's numbers in my Supabase market_data table against the previous month and post it to #updates.
First time? Adding ClickRuntime to your assistant takes about two minutes.
Why use it
Why teams use this automation
A property team collects rents, prices and listings into a Supabase table all month. The numbers are there, but turning them into 'what happened this month' is an analyst's afternoon, and the update often slips.
Calculating month-on-month changes and having AI write a short summary gives the whole team the monthly picture on day one, without anyone writing it.
What you get out of it
A monthly update that always happens
The summary arrives on the 1st every month, no matter who's on holiday.
Figures and words together
The exact changes are listed, followed by a plain-English read.
Calculated, not guessed
Averages and changes are computed from your data before AI writes anything.
Shared in one place
Everyone in #updates sees the same summary.
How it works
What happens, step by step
On the 1st of each month, ClickRuntime reads last month's and the previous month's rows from your Supabase table.
It calculates the average and change for each area.
AI writes a short summary of the biggest moves.
It posts the figures and summary to #updates in Slack.
Before it runs live
- Connect Slack, then invite the app to the channel (type /invite @ClickRuntime there)
- Connect Supabase
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
- Run it at a different time, more or less often, or only on weekdays
- 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 Slack and Supabase steps into one automation
Under the hood
The code that runs this automation
from datetime import date, timedelta
from statistics import mean
from clickruntime import on_trigger, credentials, http, notify, ai
SUPABASE = "https://your-project.supabase.co/rest/v1"
def sb(method, path, **kw):
key = credentials.secret("SUPABASE_KEY")
r = http.request(method, f"{SUPABASE}/{path}", **kw, headers={"apikey": key, "Authorization": f"Bearer {key}", "Prefer": "return=representation,resolution=merge-duplicates"})
return r.raise_for_status() or (r.json() if r.content else None)
@on_trigger
def run(event):
end = date.today().replace(day=1)
start = (end - timedelta(days=1)).replace(day=1)
prev = (start - timedelta(days=1)).replace(day=1)
rows = sb("GET", f"market_data?date=gte.{prev}&date=lt.{end}&select=area,date,avg_rent")
def avg(area, a, b):
vals = [r["avg_rent"] for r in rows if r["area"] == area and str(a) <= r["date"] < str(b)]
return mean(vals) if vals else None
lines = []
for area in sorted({r["area"] for r in rows}):
now, before = avg(area, start, end), avg(area, prev, start)
if now and before:
lines.append(f"{area}: {now:,.0f} ({(now / before - 1):+.1%})")
figures = "\n".join(lines)
summary = ai.generate(f"Write a 3-sentence plain summary of these monthly average rent changes by area:\n{figures}", max_output_tokens=150).text
notify.slack(f"*{start:%B %Y} market summary*\n{figures}\n\n{summary}", channel="#updates")
return {"areas": len(lines)}FAQ
Common questions
Which figures are included?
Does AI do the maths?
Can it compare with the same month last year?
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
Store new reviews in Supabase and send angry ones to Slack
Every 3 hours, new reviews are saved once in Supabase with a sentiment label, and negative ones go straight to Slack.
See how it worksPost members who've stopped checking in to Slack each morning
Every morning, Slack lists the members in your Supabase table who haven't checked in for 14 days, highlighting the ones new to the list since yesterday.
See how it worksScore every new lead and post the hot ones to Slack
Each new lead gets an AI score and is saved to your Supabase leads table, and hot leads are posted to your sales channel straight away.
See how it worksKeep exploring
Set up “Post a monthly summary of your Supabase figures to Slack” from your assistant
Copy the prompt above, or connect your assistant first. Free plan, no credit card.