See llms.txt for all machine-readable content.

Back to Templates

Qualify and triage leads with Google Gemini, HubSpot, Gmail, Slack and Sheets

Quick overview

This workflow captures website and Google Ads leads via webhooks, logs them to Google Sheets, and uses Google Gemini to qualify them against a Business Profile sheet, then creates HubSpot contacts and call tasks and sends Slack and Gmail alerts, reminders, and daily reports.

How it works

  1. Receives new leads from a website form or Google Ads lead form via webhook, validates a shared secret key, normalizes the fields, and appends the lead to a Google Sheets Lead Log.
  2. Loads services, service area, and qualification rules from a Google Sheets Business Profile and sends the lead details (or a matched Gmail reply) to Google Gemini to classify the lead and draft any needed email.
  3. Updates the Lead Log with the AI outcome, priority, summary, and missing information details.
  4. For qualified or not-a-fit leads, upserts the contact in HubSpot, creates an associated call task with a calculated due time, and emails the lead a confirmation.
  5. For qualified leads, sends real-time alerts to a Slack channel and to the owner via Gmail.
  6. For missing-info leads, emails the lead questions once and stores the Gmail thread ID so their reply can be matched and re-evaluated.
  7. Runs hourly to check HubSpot task completion, send Slack/Gmail reminders for open qualified tasks, and escalate no-reply missing-info leads to “please call,” and runs daily at 6 PM to email a summary report from the Lead Log.

Setup

  1. Create a Google Sheets Lead Log spreadsheet and a Business Profile spreadsheet with tabs and headers matching the notes for the Lead Log, Services, Service Area, and About and Rules.
  2. Add credentials for Google Sheets, Gmail, Slack, and Google Gemini (Gemini API / Google AI), and create a HubSpot private app token with access to contacts and tasks.
  3. Update the Config values for both sheet URLs, webhookSecret, businessName, alertEmail, slackChannel, timezone, and (optionally) hubspotOwnerId and reminder timing settings.
  4. Copy the two webhook URLs and configure your website form and Google Ads Lead Form webhook to post leads with the secret key (header x-webhook-key or ?key= parameter).