Skip to content

Every 15 minutes

Log new emails in a sheet and turn action items into tasks

Every new email is sorted and logged in your sheet, and the ones that need you become Google Tasks.

Runs
Every 15 minutes
Apps
Google Sheets, Google Tasks
AI
Yes, uses the built-in AI allowance
Access
Sheets write; tasks

Send this to your assistant

Create a ClickRuntime automation: every 15 minutes, sort my new emails into action needed, waiting, FYI or newsletter, log each in my Email log sheet and create a Google Task for anything I need to act on.

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

In a busy inbox, the emails that ask you to do something look much like the ones that only keep you informed. Requests get read, mentally noted, and then buried under the next twenty messages.

Office managers, assistants and small business owners use it to keep a simple record of what came in and to make sure every request turns into a task they can tick off.

What you get out of it

  • Requests become tasks you can see

    An email asking for a quote or a signature becomes a task in Google Tasks, next to the rest of your to-do list.

  • A searchable log of your inbox

    The sheet shows sender, subject, category and date for every message, which helps when you need to report on volume or find a thread from last month.

  • FYI mail stays out of your task list

    Newsletters and updates are logged but do not create tasks, so your list stays about real work.

  • Your inbox is left as it is

    Emails are not moved or deleted. The sorting happens in the sheet and the task list.

How it works

What happens, step by step

  1. Every 15 minutes, ClickRuntime checks your Gmail inbox for messages it has not seen yet.

  2. AI reads the sender, subject and opening lines and picks a category.

  3. Each email is added as a row in your log sheet with its category.

  4. Emails that need action also become a Google Task, with a link back to the message.

Before it runs live

  • Connect your Google Sheets account and pick the spreadsheets it may use
  • Connect Google Tasks

What you get

RunsEvery 15 minutes
Log new emails in a sheet and turn action items into taskstoday, 9:00Succeeded
Google Tasks · My TasksSign and return the Northwind supply agreement From: legal@northwind.example

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 Google Sheets and Google Tasks 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.
email_triage_log_to_sheets_action_to_tasks.pyexample
from google.oauth2.credentials import Credentials
from googleapiclient.discovery import build
from clickruntime import on_trigger, report_fetched, credentials, state, ai

SHEET_ID = "your-spreadsheet-id"

@on_trigger
def run(event):
    creds = Credentials(credentials.connection("google", "work"))
    gmail = build("gmail", "v1", credentials=creds, cache_discovery=False).users().messages()
    done = set(state.get("done") or [])
    new = [m for m in gmail.list(userId="me", q="in:inbox newer_than:1d", maxResults=50).execute().get("messages", [])
           if m["id"] not in done]
    report_fetched(len(new))
    if not new:
        return {"new": 0}
    rows = []
    for m in new:
        msg = gmail.get(userId="me", id=m["id"], format="metadata", metadataHeaders=["From", "Subject", "Date"]).execute()
        h = {x["name"]: x["value"] for x in msg["payload"]["headers"]}
        cat = ai.generate("Pick one of Action needed, Waiting, FYI, Newsletter for this email. Reply with the category only."
                          f"\nFrom: {h.get('From')}\nSubject: {h.get('Subject')}\n{msg['snippet']}", max_output_tokens=10).text.strip()
        rows.append([h.get("Date", ""), h.get("From", ""), h.get("Subject", ""), cat])
        if cat == "Action needed":
            build("tasks", "v1", credentials=creds, cache_discovery=False).tasks().insert(tasklist="@default", body={
                "title": h.get("Subject") or "Email to action", "notes": f"https://mail.google.com/mail/u/0/#all/{m['id']}"}).execute()
    build("sheets", "v4", credentials=creds, cache_discovery=False).spreadsheets().values().append(
        spreadsheetId=SHEET_ID, range="Email log!A:D", valueInputOption="USER_ENTERED", body={"values": rows}).execute()
    state.set("done", sorted(done | {m["id"] for m in new})[-1000:])
    return {"logged": len(rows)}

FAQ

Common questions

Does it read the whole email?
It reads the sender, subject and the first part of the message, which is enough to tell a request from an update. Long threads and attachments are not sent to the AI.
Can I use my own categories?
Yes. Give your AI assistant the categories you want, such as Client request, Invoice and Internal. Only the ones you mark as needing action create tasks.
Does the task link back to the email?
Yes. The task notes include the sender, the subject and a link that opens the message in Gmail.
What permissions does it need?
Sheets write; tasks. 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 checks. Checks that find nothing new 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 “Log new emails in a sheet and turn action items into tasks” from your assistant

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