Every 15 minutes
Sort outreach replies in Gmail into interested and not
Replies to your SendGrid outreach are read as they land in Gmail, labelled interested or not, and the hot ones are flagged in Slack.
- Runs
- Every 15 minutes
- Apps
- Gmail, SendGrid
- AI
- Yes, uses the built-in AI allowance
- Access
- SendGrid Mail Send; Gmail modify
Send this to your assistant
Create a ClickRuntime automation: every 10 minutes, check Gmail for replies to my outreach campaign. Label each as Interested, Not interested or Out of office, and post the interested ones in #sales.
First time? Adding ClickRuntime to your assistant takes about two minutes.
Why use it
Why teams use this automation
A recruiter sends a few hundred outreach emails a week through SendGrid. Replies pile up in Gmail mixed with out-of-office notes and polite refusals, and the few people who said yes wait a day or two for an answer.
Every reply is now read as it arrives and labelled in Gmail. Interested replies are posted in Slack straight away, so a person can answer within the hour, and the rest are already sorted.
What you get out of it
Interested replies answered first
The people who said yes get a quick response, which is when they're most likely to book a call.
An inbox that sorts itself
Out-of-office notes and refusals are labelled and out of the way.
The team sees wins in Slack
Interested replies posted to #sales let anyone pick them up.
Nothing deleted
Every reply stays in Gmail with a label, so you can always check how something was sorted.
How it works
What happens, step by step
Every 10 minutes, ClickRuntime checks Gmail for new replies to your campaign.
AI reads each reply and decides whether it is interested, not interested or an out-of-office note.
The reply gets a matching label in Gmail, which also stops it being read twice.
Interested replies are posted in your #sales Slack channel with the sender and a short quote.
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 SendGrid
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
- 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 SendGrid steps into one automation
Under the hood
The code that runs this automation
from google.oauth2.credentials import Credentials
from googleapiclient.discovery import build
from clickruntime import on_trigger, credentials, ai, notify, report_fetched
LABELS = {"interested": "Label_Interested", "not_interested": "Label_NotInterested", "out_of_office": "Label_OOO"}
@on_trigger
def run(event):
gmail = build("gmail", "v1", credentials=Credentials(credentials.connection("google", "work")), cache_discovery=False)
query = 'subject:"Re: Quick question about hiring" -label:Interested -label:NotInterested -label:OOO newer_than:7d'
msgs = gmail.users().messages().list(userId="me", q=query).execute().get("messages", [])
report_fetched(len(msgs))
if not msgs:
return {"summary": "No new replies"}
for m in msgs:
full = gmail.users().messages().get(userId="me", id=m["id"], format="metadata", metadataHeaders=["From"]).execute()
sender = full["payload"]["headers"][0]["value"]
label = ai.generate(f"Classify this reply as interested, not_interested or out_of_office: {full['snippet']}",
max_output_tokens=10).text.strip().lower()
label = label if label in LABELS else "not_interested"
gmail.users().messages().modify(userId="me", id=m["id"], body={"addLabelIds": [LABELS[label]]}).execute()
if label == "interested":
notify.slack(f":tada: {sender} is interested: \"{full['snippet'][:140]}\"", channel="#sales")
return {"sorted": len(msgs)}FAQ
Common questions
How does it know which emails are campaign replies?
What if it labels something wrongly?
Does it answer the replies?
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
Send each contact a personalised weekly tip through SendGrid
Every week each subscriber gets a short tip written for them through SendGrid, and you get a send report in Gmail.
See how it worksLabel new emails automatically
New mail is sorted into labels like Inquiry, Invoice and Newsletter within minutes of arriving.
See how it worksGet draft replies to emails that need an answer
Emails that need a reply get a draft in the same thread, ready for you to edit and send.
See how it worksKeep exploring
Set up “Sort outreach replies in Gmail into interested and not” from your assistant
Copy the prompt above, or connect your assistant first. Free plan, no credit card.