On a schedule
Flag Notion docs that are older than your latest release
When a new release ships on GitHub, Slack lists the Notion docs pages for that product that have not been updated since before the release.
- Runs
- On a schedule
- Apps
- GitHub, Notion
- AI
- Not needed
- Access
- GitHub read; Notion read
Send this to your assistant
Create a ClickRuntime automation: every day, check the latest release of each SDK repo on GitHub; when there's a new one, list the pages in my Notion Docs database for that SDK last edited before the release, and post them to #docs.
First time? Adding ClickRuntime to your assistant takes about two minutes.
Why use it
Why teams use this automation
A developer platform keeps its SDK guides in Notion and ships new SDK versions every few weeks. Docs lag behind, and developers follow instructions for a version that no longer exists, then open support tickets.
Flagging the pages that have not been touched since a release gives the docs team a precise to-do list the day it ships. Guides stay in step with the code, and support hears fewer 'the docs are wrong' complaints.
What you get out of it
A precise list of pages to check
Only pages for the released product and older than the release are listed. Writers know exactly where to look.
Docs keep up with releases
Hearing on release day means updates happen in days, not months. Developers read instructions that match the code.
Fewer support tickets
Accurate docs prevent the confused questions that follow every outdated guide.
Once per release
Each release is reported once. The channel is not repeatedly reminded of the same release.
How it works
What happens, step by step
Every day, ClickRuntime checks the latest release of each of your SDK repositories on GitHub.
It skips releases it has already reported.
For a new release, it finds the pages in your Notion docs database for that SDK that were last edited before the release date.
The list is posted to your #docs Slack channel with links to each page.
Before it runs live
- Connect GitHub
- Connect Notion and share the database you want it to use
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
- 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 GitHub and Notion steps into one automation
Under the hood
The code that runs this automation
from clickruntime import on_trigger, credentials, http, notify, state
def gh(method, path, **kw):
resp = http.request(method, f"https://api.github.com{path}", headers={
"Authorization": f"Bearer {credentials.connection('github', 'work')}", "Accept": "application/vnd.github+json"}, **kw)
return resp.raise_for_status() or (resp.json() if resp.content else None)
def notion(method, path, **kw):
resp = http.request(method, f"https://api.notion.com/v1{path}", headers={
"Authorization": f"Bearer {credentials.secret('NOTION_TOKEN')}", "Notion-Version": "2022-06-28"}, **kw)
return resp.raise_for_status() or resp.json()
DOCS = "your-notion-database-id"
SDKS = {"acme/sdk-python": "Python", "acme/sdk-node": "Node"}
@on_trigger
def run(event):
seen = state.get("releases") or {}
posted = 0
for repo, sdk in SDKS.items():
rel = gh("GET", f"/repos/{repo}/releases/latest")
if seen.get(repo) == rel["tag_name"]:
continue
pages = notion("POST", f"/databases/{DOCS}/query", json={"filter": {"and": [
{"property": "SDK", "select": {"equals": sdk}},
{"timestamp": "last_edited_time", "last_edited_time": {"before": rel["published_at"]}}]}})["results"]
if pages:
lines = [f"• <{p['url']}|{''.join(t['plain_text'] for t in p['properties']['Name']['title'])}>" for p in pages]
notify.slack(f"{sdk} SDK {rel['tag_name']} released. These docs pages are older than the release:\n" + "\n".join(lines), channel="#docs")
posted += 1
seen[repo] = rel["tag_name"]
state.set("releases", seen)
return {"posted": posted}FAQ
Common questions
How does it know which pages belong to which SDK?
Does a small edit count as updated?
Can it also check release notes?
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
Back up workflows to GitHub and document them in Notion
Each week your workflow definitions are saved to GitHub, and every changed workflow gets a plain-language description in your Notion database.
See how it worksGet a pre-meeting briefing from GitHub and Notion
Before each engineering meeting, Slack gets a short briefing with recent pull requests and issues and the latest notes from your Notion meeting page.
See how it worksTurn approved Notion feature requests into GitHub issues
When a feature request in Notion is marked Approved, a GitHub issue is opened and its link is written back to the Notion page.
See how it worksKeep exploring
Set up “Flag Notion docs that are older than your latest release” from your assistant
Copy the prompt above, or connect your assistant first. Free plan, no credit card.