Skip to content

The moment it happens

Weekly email of new members in a Telegram group

Your bot records who joins and leaves your Telegram group, and every Monday you get an email listing them with the week's net change.

Runs
The moment it happens
Apps
Telegram
AI
Not needed
Access
bot token (bot must be group admin to receive chat_member updates)

Send this to your assistant

Create a ClickRuntime automation: track who joins and leaves my Telegram community group, and every Monday at 8:00 email me a list of joins and leaves with names and usernames, the net change and the current member count.

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

Community owners want to know whether their group is growing and who is new, so they can welcome people or notice when a post drove people away. Telegram shows the current count but not who came and went this week.

This automation listens for member changes through your bot and keeps a weekly log. Every Monday you get one email with the names of people who joined and left, the net change and the current total.

It suits community managers, course creators and small brands that run a Telegram group as part of their business.

What you get out of it

  • Growth you can see

    A weekly net change shows the trend without exporting anything.

  • Names, not just numbers

    Knowing who joined lets you welcome new members or spot a returning customer.

  • Notice drop-offs

    A spike in leavers after a post or announcement is easy to see in the list.

  • Lands in your inbox

    A Monday email is easy to file or forward to a partner who is not in the group.

  • No extra bots in the group

    Your own bot does the work with a single admin permission.

How it works

What happens, step by step

  1. You make your bot an admin of the group so Telegram tells it about member changes.

  2. Each time someone joins or leaves, ClickRuntime records their name, username and the time.

  3. Every Monday at 8:00 it emails you the week's joins and leaves, the net change and the current member count.

  4. The list then starts fresh for the new week.

Before it runs live

  • Connect Telegram
  • Paste your automation's link into the other app's webhook settings

What you get

RunsThe moment it happens
Weekly email of new members in a Telegram groupjust nowSucceeded
Email · Telegram group: +14 this weekJoined (19): Ana Ruiz (@anaruiz), Kofi Mensah (@kofim), … Left (5): Dev P. (@devp), … Net change: +14 · Members now: 1,262

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
  • 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 Telegram 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_email_of_new_members_in_a_telegram_group.pyexample
from clickruntime import on_trigger, credentials, http, state, notify

GROUP = -1001234567890

def tg(method, **params):
    r = http.post(f"https://api.telegram.org/bot{credentials.secret('TELEGRAM_BOT_TOKEN')}/{method}", json=params)
    r.raise_for_status()
    return r.json()["result"]

def who(u):
    name = " ".join(filter(None, [u.get("first_name"), u.get("last_name")]))
    return f"{name} (@{u['username']})" if u.get("username") else name

@on_trigger
def run(event):
    log = state.get("log") or {"joined": [], "left": []}
    cm = (event.get("json") or {}).get("chat_member")
    if cm:  # webhook update
        if cm["chat"]["id"] != GROUP:
            return {"skipped": True}
        old, new = cm["old_chat_member"]["status"], cm["new_chat_member"]["status"]
        member = ("member", "administrator", "creator", "restricted")
        if old not in member and new in member:
            log["joined"].append(who(cm["new_chat_member"]["user"]))
        elif old in member and new not in member:
            log["left"].append(who(cm["new_chat_member"]["user"]))
        state.set("log", log)
        return {"recorded": True}
    count = tg("getChatMemberCount", chat_id=GROUP)  # weekly report
    net = len(log["joined"]) - len(log["left"])
    body = (f"Joined ({len(log['joined'])}): " + (", ".join(log["joined"]) or "none") +
            f"\n\nLeft ({len(log['left'])}): " + (", ".join(log["left"]) or "none") +
            f"\n\nNet change: {net:+d} · Members now: {count:,}")
    notify.email_me(subject=f"Telegram group: {net:+d} this week", body=body)
    state.set("log", {"joined": [], "left": []})
    return {"net": net}

FAQ

Common questions

Why does the bot need to be an admin?
Telegram only sends member join and leave updates to bots that are administrators of the group. The bot needs no other admin rights, so you can switch the rest off.
Does it work for channels?
Yes for the count. Channels also send member updates to admin bots, though Telegram may not report every subscriber of very large channels by name.
Can I get it daily instead?
Yes. Ask your assistant to change the report to every morning; the list then covers the last 24 hours.
What permissions does it need?
bot token (bot must be group admin to receive chat_member updates). 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 for each event the app sends.
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 “Weekly email of new members in a Telegram group” from your assistant

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