Skip to content

Daily

Get alerted when key events fall

You hear in Slack when a key event such as purchases drops well below its usual level.

Runs
Daily
Apps
Google Analytics
AI
Not needed
Access
analytics.readonly

Send this to your assistant

Create a ClickRuntime automation: every morning, alert me in #sales on Slack if yesterday's purchase events were more than 30% below the 7-day average.

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 SaaS company counts the sign_up key event in GA4, and it normally sees around 80 a day. After a release, the signup form silently fails in Safari. Traffic looks normal, ads keep spending, and the sign-up count drops to 35. The product team finds out nine days later when someone in sales asks why the pipeline looks thin.

Each day, ClickRuntime pulls the event count for the key event you choose over the last eight days, compares yesterday against the previous seven and sends an alert if it fell past your threshold. Because it watches an outcome instead of traffic, it catches broken forms that visitor numbers never reveal. It reads GA4 only, with no changes to your tags.

Teams use it for purchases, demo requests, newsletter signups or any event that stands for money coming in.

What you get out of it

  • Broken forms found in a day

    A drop in sign-ups while traffic holds is the classic sign of a form or checkout bug. Alerting the next morning limits the lost leads to a single day instead of more than a week.

  • Ad spend stays tied to results

    When conversions fall, paid campaigns keep spending. A prompt alert lets you pause or adjust before budget goes to clicks that cannot convert because something on the page is broken.

  • Engineering gets a concrete signal

    "Sign-ups fell 55 percent yesterday" is easier to investigate than a vague feeling that numbers look low. Developers can compare against the release log and narrow the cause quickly. The alert gives them a date and a size to start from.

  • Revenue-linked monitoring

    Watching purchase or generate_lead directly measures what the business cares about. That covers failures upstream monitoring tools miss, like a payment button that renders but does nothing. A purchase count is the clearest sign that money is still flowing.

  • Confidence after launches

    After a redesign or release, you know that if conversion breaks you will hear about it. That makes teams more willing to ship improvements, instead of freezing changes out of caution.

How it works

What happens, step by step

  1. Every day, ClickRuntime pulls the last eight days of your chosen key event, such as purchases, from Google Analytics.

  2. It compares yesterday's count with the daily average of the week before.

  3. If yesterday fell well below normal, it posts a line to your #marketing Slack channel, such as "'purchase' dropped: 18 yesterday vs 54/day average". Otherwise nothing is sent.

Before it runs live

  • Connect Google Analytics

What you get

RunsDaily
Get alerted when key events falltoday, 9:00Succeeded
Slack · #marketing'purchase' dropped: 18 yesterday vs 54/day average

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

  • 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 Google Analytics 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.
key_event_conversion_drop_alert.pyexample
from clickruntime import on_trigger, credentials, http, notify

PROPERTY = "123456789"
KEY_EVENT = "purchase"
DROP = 0.5

@on_trigger
def run(event):
    rows = http.post(f"https://analyticsdata.googleapis.com/v1beta/properties/{PROPERTY}:runReport",
        headers={"Authorization": f"Bearer {credentials.connection('google', 'work')}"},
        json={"dateRanges": [{"startDate": "8daysAgo", "endDate": "yesterday"}],
              "dimensions": [{"name": "date"}], "metrics": [{"name": "eventCount"}],
              "dimensionFilter": {"filter": {"fieldName": "eventName", "stringFilter": {"value": KEY_EVENT}}},
              "orderBys": [{"dimension": {"dimensionName": "date"}}], "keepEmptyRows": True},
    ).json().get("rows", [])
    counts = [int(r["metricValues"][0]["value"]) for r in rows]
    if len(counts) < 2:
        return {"skipped": "not enough data"}
    yesterday, avg = counts[-1], sum(counts[:-1]) / len(counts[:-1])
    if yesterday < avg * DROP:
        notify.slack(f"'{KEY_EVENT}' dropped: {yesterday} yesterday vs {avg:.0f}/day average", channel="#marketing")
    return {"yesterday": yesterday, "average": round(avg)}

FAQ

Common questions

Which events can it watch?
Any event marked as a key event in GA4, or any event name you can see in your reports, such as purchase, generate_lead or sign_up. Pick the one that best represents success. You can run separate alerts for several events if needed.
Does it handle low-volume events like enterprise demo requests?
With only a few events a day, percentage drops are misleading, because going from 3 to 1 looks dramatic. For rare events, use a weekly comparison or alert only when the count hits zero for a full day or more.
Can the alert go to Slack instead of email?
Yes. The destination is a setting, so the message can go to a Slack channel, an email address or both. Many teams send conversion alerts to the same channel where developers watch deploys, so cause and effect are seen together.
What permissions does it need?
analytics.readonly. Nothing else in your accounts is used.
Does it need AI?
No. It runs without AI, so it doesn't use your plan's AI allowance.
How many runs does it use?
One run each time it runs (daily). Checks that find nothing to do 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 “Get alerted when key events fall” from your assistant

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