Skip to content

The moment it happens

Follow up new leads by email and WhatsApp within minutes

Each new lead gets a personal email and a WhatsApp message within minutes, written around what they asked.

Runs
The moment it happens
Apps
Gmail, WhatsApp Business
AI
Yes, uses the built-in AI allowance
Access
Gmail send+read; WhatsApp messaging

Send this to your assistant

Create a ClickRuntime automation: when a new lead comes in from my form, write a short personal reply based on their message, email it from my Gmail, send my WhatsApp intro template, and remember the lead.

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

Leads go cold fast. A prospect who filled in a form on a Friday evening and hears nothing until Monday has usually spoken to two competitors by then.

A personal email that responds to what they actually asked, plus a WhatsApp message they'll see on their phone, makes the first contact within minutes and starts the conversation on the channel they prefer.

What you get out of it

  • First to reply

    Leads hear from you in minutes, day or night.

  • Personal, not generic

    The email picks up on what the lead wrote, so it reads like a real reply.

  • Two ways to respond

    Leads can reply by email or WhatsApp, whichever suits them.

  • A list of every lead

    Each lead is remembered with the time they were contacted.

How it works

What happens, step by step

  1. Your lead form sends each new lead to ClickRuntime.

  2. AI writes a short, personal email reply based on what they asked.

  3. The email is sent from your Gmail, and your WhatsApp intro template goes to their phone if they gave a number.

  4. The lead and contact time are remembered so they aren't contacted twice.

Before it runs live

  • Connect Google through your own Google app (a one-time, 10-minute setup), so it works with your own Gmail
  • Connect WhatsApp Business
  • Paste your automation's link into the other app's webhook settings

What you get

RunsThe moment it happens
Follow up new leads by email and WhatsApp within minutesjust nowSucceeded
Email · Re: your enquiry, TaylorThanks for asking about bookkeeping for Acme Studio. Moving from spreadsheets is our speciality. Could we do a 15-minute call this week?

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
  • 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 Gmail and WhatsApp Business 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.
follow_up_new_leads_by_email_and_whatsapp.pyexample
from google.oauth2.credentials import Credentials
from googleapiclient.discovery import build
import base64, time
from clickruntime import on_event, credentials, http, state, ai

WA = "https://graph.facebook.com/v20.0/your-phone-number-id/messages"

def wa_template(to, name, params):
    body = {"messaging_product": "whatsapp", "to": to, "type": "template", "template": {"name": name, "language": {"code": "en"},
            "components": [{"type": "body", "parameters": [{"type": "text", "text": str(p)} for p in params]}]}}
    return http.post(WA, headers={"Authorization": f"Bearer {credentials.secret('WHATSAPP_TOKEN')}"}, json=body).json()
gmail = lambda: build("gmail", "v1", credentials=Credentials(credentials.connection("google", "work")), cache_discovery=False).users()

def send_email(to, subject, text):
    raw = base64.urlsafe_b64encode(f"To: {to}\r\nSubject: {subject}\r\n\r\n{text}".encode()).decode()
    gmail().messages().send(userId="me", body={"raw": raw}).execute()

@on_event
def handle(event):
    lead = event.json or {}
    email, name = lead.get("email", ""), lead.get("name", "there")
    if "@" not in email or state.get(f"lead:{email}"):
        return {"skipped": True}
    body = ai.generate(f"Lead {name} wrote: {lead.get('message', '')[:1500]}", max_output_tokens=250,
                       system="Write a friendly 4-sentence reply from a small business owner. Offer a short call. No sign-off.").text
    send_email(email, f"Re: your enquiry, {name}", f"{body.strip()}\n\nBest,\nAlex")
    if lead.get("phone"):
        wa_template(lead["phone"], "lead_intro", [name])
    state.set(f"lead:{email}", {"at": time.time(), "phone": lead.get("phone")})
    return {"lead": email}

FAQ

Common questions

Can I check emails before they go?
Yes. It can save the email as a Gmail draft instead of sending it, and you send it yourself.
What does the WhatsApp message say?
Your approved intro template, usually a short hello with your name.
What if the lead didn't give a phone number?
They just get the email.
What permissions does it need?
Gmail send+read; WhatsApp messaging. 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 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 “Follow up new leads by email and WhatsApp within minutes” from your assistant

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