See llms.txt for all machine-readable content.

Back to Templates

Write LinkedIn-based cold email icebreakers with Google Sheets, Apify and Claude

Quick overview

This workflow pulls unprocessed B2B leads from Google Sheets, uses Apify to scrape each lead’s recent LinkedIn posts and website content, generates a LinkedIn-based cold email icebreaker with Anthropic Claude, and writes the approved icebreaker back to the sheet.

How it works

  1. Manually starts and reads leads from Google Sheets where the “Processed” column is set to “NO”.
  2. Limits processing to the first 50 leads and loops through them one at a time.
  3. For each lead, triggers an Apify actor run to scrape recent LinkedIn posts, waits briefly, fetches the actor dataset results, and extracts the most recent non-repost post text.
  4. Fetches the lead’s company website HTML, converts it to plain text, and uses Anthropic Claude to summarize specific company details for context.
  5. Uses Anthropic Claude to write a single 15–30 word icebreaker using only the LinkedIn post content, or returns “SKIP” if the post lacks a strong personalizable detail.
  6. Rejects icebreakers that match banned patterns (for example missing “LinkedIn”, salesy language, clichés, or hyphenated phrasing) and flags them as “SKIP”.
  7. After a short rate-limit wait, appends or updates the lead’s row in Google Sheets (matched by email) with the icebreaker and sets “Processed” to “YES”.

Setup

  1. Connect your Google Sheets OAuth credentials and select the spreadsheet and sheet to read from and update.
  2. Ensure your Google Sheet includes columns for at least “email”, “linkedin”, “company_website”, “Processed”, and “Icebreaker”, with “Processed” set to “NO” for new leads.
  3. Provide an Apify API token and, if needed, replace the hardcoded Apify actor ID and token in the HTTP requests.
  4. Add an Anthropic API credential and choose the Claude model used for website summarization and icebreaker writing.
  5. Review the batch size (currently first 50 leads) and the wait durations (Apify wait and rate limiting) to fit your volume and scraping latency.