Skip to content

Weekly

Get a weekly list of customers at risk of leaving

Each Monday you get a ranked list of customers who look likely to churn, with a reason for each.

Runs
Weekly
Apps
HubSpot
AI
Yes, uses the built-in AI allowance
Access
crm.objects.contacts.read, crm.objects.deals.read

Send this to your assistant

Create a ClickRuntime automation: every Monday at 8am, look at my HubSpot customers' recent activity and deals, flag the ones at risk of leaving with a one-line reason, and email me the list.

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 customer success manager covering 120 accounts cannot read every contact timeline each week. An account that went quiet after a pricing dispute looks fine in HubSpot because its deal is still open and the last logged note is two months old. The warning signs, such as no emails, no meetings and a stalled renewal deal, are all there, but they are spread across records no one has time to cross-check.

Once a week, ClickRuntime pulls each customer's last activity date and deal data from HubSpot and has built-in AI read them together. It gives every account a risk score with a short reason, such as "no contact in 60 days, renewal deal stuck in negotiation", then emails you the list ranked from highest risk down.

Teams with a book of customers too large to review by hand will get the most from it.

What you get out of it

  • Save accounts while there is still time

    Churn is usually visible weeks before a cancellation email. A ranked list on Monday morning points you at the accounts to call that week, when a conversation can still change the outcome.

  • Attention goes to the right accounts

    Without a ranking, success managers tend to contact the loudest customers. A score with a stated reason directs effort toward quiet accounts that are actually drifting, which is where revenue is lost.

  • Reasons you can act on

    A bare score is easy to ignore. Because each line states why the account was flagged, such as a stalled deal or long silence, you know what to ask in the call instead of starting from scratch.

  • Renewal forecasts get more honest

    Seeing which renewals are at risk lets finance and leadership discount them in forecasts. You avoid the surprise of a renewal quarter that looks strong on paper and collapses at the end.

  • A weekly habit with no spreadsheet work

    The report arrives on its own each week, so the review actually happens. Nobody has to export contacts and deals, merge them and eyeball dates, which is the step teams skip when busy.

How it works

What happens, step by step

  1. Every Monday, ClickRuntime gathers your HubSpot customers with their last activity and open deals.

  2. AI looks at each one and gives it a churn risk score with a short reason, like "no contact in 47 days".

  3. You get an email with the customers ranked from highest risk to lowest.

Before it runs live

  • Connect HubSpot

What you get

RunsWeekly
Get a weekly list of customers at risk of leavingtoday, 9:00Succeeded
Email · At-risk customers this week1. Northwind: no contact in 47 days and renewal deal stuck in negotiation 2. Acme: usage call cancelled twice, no open deals

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
  • 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 HubSpot 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.
weekly_at_risk_customer_report_with_ai.pyexample
from clickruntime import on_trigger, credentials, http, ai, notify

API = "https://api.hubapi.com/crm/v3/objects"

@on_trigger
def run(event):
    headers = {"Authorization": f"Bearer {credentials.connection('hubspot', 'work')}"}
    customers = http.post(f"{API}/contacts/search", headers=headers, json={"limit": 100,
        "properties": ["email", "company", "notes_last_contacted", "hs_last_sales_activity_timestamp", "num_associated_deals"],
        "filterGroups": [{"filters": [{"propertyName": "lifecyclestage", "operator": "EQ", "value": "customer"}]}]}).json()["results"]
    deals = http.post(f"{API}/deals/search", headers=headers, json={"limit": 100,
        "properties": ["dealname", "dealstage", "amount", "closedate"]}).json()["results"]
    lines = [f"{c['properties'].get('company')} | last contacted {c['properties'].get('notes_last_contacted')} | "
             f"last activity {c['properties'].get('hs_last_sales_activity_timestamp')}" for c in customers]
    deal_lines = [f"{d['properties']['dealname']} | {d['properties']['dealstage']} | {d['properties'].get('amount')}" for d in deals]
    report = ai.generate("Customers:\n" + "\n".join(lines) + "\n\nDeals:\n" + "\n".join(deal_lines),
                         system="List the customers most at risk of leaving, highest risk first, one line each with a short reason.",
                         max_output_tokens=600).text
    notify.email_me("At-risk customers this week", report)
    return {"customers_checked": len(customers)}

FAQ

Common questions

How does the AI decide an account is at risk?
It reads the activity dates and deal data pulled from HubSpot, such as time since last contact and the state of open deals, and writes a score with a plain-language reason. It is a prompt to look, not a verdict, so use the reasons to decide which accounts deserve a call.
Do I need my own OpenAI or Anthropic key for the AI step?
No. The scoring step uses ClickRuntime's built-in AI, so there is no key to create or pay for separately. The only credential involved is your HubSpot connection, which is stored as a secret and used only to read those records.
Can it include fields from my own HubSpot properties?
Yes, if the data lives in a HubSpot property on the contact, company or deal, it can be added to what the AI reads. Examples are a plan tier, a support ticket count or a health score you maintain. Ask for the extra property by its name.
What permissions does it need?
crm.objects.contacts.read, crm.objects.deals.read. Nothing else in your accounts is used.
Does it need AI?
Yes. It uses ClickRuntime's built-in AI, so you don't need an OpenAI or Anthropic key. Every plan includes a monthly AI allowance.
How many runs does it use?
One run each time it runs (weekly). 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 a weekly list of customers at risk of leaving” from your assistant

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