Lead Scraping & Verification

## Goal

6 stars

Best use case

Lead Scraping & Verification is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

## Goal

Teams using Lead Scraping & Verification should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/scrape-leads/SKILL.md --create-dirs "https://raw.githubusercontent.com/Harmeet10000/skills/main/skills/marketing/scrape-leads/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/scrape-leads/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How Lead Scraping & Verification Compares

Feature / AgentLead Scraping & VerificationStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

## Goal

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Lead Scraping & Verification

## Goal
Scrape leads using Apify (`code_crafter/leads-finder`), verify their relevance (industry match > 80%), and save them to a Google Sheet. For large scrapes (1000+ leads), use parallel scraping for 3-5x faster performance.

## Inputs
- **Industry**: The target industry (e.g., "Plumbers", "Software Agencies").
- **Location**: The target location (e.g., "New York", "United States").
- **Total Count**: The total number of leads desired.

## Tools/Scripts
- Script: `execution/scrape_apify.py` (single scrape, for <1000 leads)
- Script: `execution/scrape_apify_parallel.py` (parallel scraping, for 1000+ leads)
- Script: `execution/update_sheet.py` (batch sheet updates, optimized for large datasets)
- Dependencies: Apify API Token, Google Service Account Credentials

## Process

### Small Scrapes (<1000 leads)
1. **Test Scrape**
   - Run `execution/scrape_apify.py` with `max_items=25` and `--no-email-filter`.
   - Output: `.tmp/test_leads.json` (temporary file).

2. **Verification**
   - Agent (You) reads `.tmp/test_leads.json`.
   - Check if at least 20/25 (80%) leads match the **Industry**.
   - **Decision**:
     - **Pass**: Proceed to step 3.
     - **Fail**: Stop. Ask user to refine **Industry** or **Location** keywords.

3. **Full Scrape**
   - Run `execution/scrape_apify.py` with full **Total Count** and `--no-email-filter`.
   - Output: `.tmp/leads_[timestamp].json` (temporary file).

4. **[OPTIONAL] LLM Classification for Harder Niches**
   - **When to use**: For complex distinctions (e.g., "product SaaS vs agencies")
   - **Command**:
     ```bash
     python3 execution/classify_leads_llm.py .tmp/leads_[timestamp].json \
       --classification_type product_saas \
       --output .tmp/classified_leads.json
     ```
   - **Performance**: ~2 minutes for 3,000 leads
   - See [classify_leads_llm.md](classify_leads_llm.md) for details

5. **Upload to Google Sheet** (DELIVERABLE)
   - Run `execution/update_sheet.py` with the final JSON file (classified or original).
   - **Output**: Google Sheet URL (this is the actual deliverable the user receives).

6. **Enrich Missing Emails**
   - Run `execution/enrich_emails.py` with the Google Sheet URL.
   - Script auto-detects dataset size and uses appropriate API strategy.
   - **Output**: Updated Google Sheet URL (final deliverable with enriched emails).

### Large Scrapes (1000+ leads) - FASTER with Parallel Processing
1. **Test Scrape** (same as above)
   - Run `execution/scrape_apify.py` with `max_items=25` and `--no-email-filter`.
   - Verify industry match > 80%.

2. **Parallel Full Scrape**
   - Run `execution/scrape_apify_parallel.py` with:
     - `--total_count` (e.g., 4000)
     - `--location` (e.g., "United States", "EU", "UK", "Canada", "Australia")
     - `--strategy regions` (auto-detects based on location)
     - `--no-email-filter` (scrape without email requirement, enrich after)
   - **Geographic Partitioning (Cost-Neutral)**:
     - **Auto-detects region** based on location:
       - **United States**: 4-way (Northeast, Southeast, Midwest, West)
       - **EU/Europe**: 4-way (Western, Southern, Northern, Eastern)
       - **UK**: 4-way (SE England, N England, Scotland/Wales, SW England)
       - **Canada**: 4-way (Ontario, Quebec, West, Atlantic)
       - **Australia**: 4-way (NSW, VIC/TAS, QLD, WA/SA)
     - **Alternative strategies**:
       - `--strategy metros`: 8-way US metro areas
       - `--strategy apac`: 8-way Asia-Pacific split
       - `--strategy global`: 8-way worldwide continental split
     - **Custom**: Comma-separated cities/states (e.g., `--location "London,Paris,Berlin,Madrid"`)
   - **Cost**: SAME as sequential (4 partitions × 1000 = 4000 total leads)
   - **Automatic Deduplication**: Handles leads appearing in multiple regions
   - Output: `.tmp/leads_[timestamp].json` (deduplicated, temporary file).
   - **Time Savings**: 3-4x faster than sequential, no extra cost.

3. **[OPTIONAL] LLM Classification for Harder Niches**
   - **When to use**: For complex distinctions that keywords can't capture:
     - ✅ "Product SaaS vs IT consulting agencies" (use LLM)
     - ✅ "High-ticket vs low-ticket businesses" (use LLM)
     - ✅ "Subscription vs one-time payment models" (use LLM)
     - ❌ "Dentists" or "Realtors" (simple keyword matching works)
   - **Command**:
     ```bash
     python3 execution/classify_leads_llm.py .tmp/leads_[timestamp].json \
       --classification_type product_saas \
       --output .tmp/classified_leads.json
     ```
   - **Performance**: ~2 minutes for 3,000 leads, ~$0.30 per 1,000 leads
   - **Default behavior**: Includes "unclear" classifications (medium confidence)
   - **Output**: `.tmp/classified_leads.json` (use this instead of original file for next step)
   - See [classify_leads_llm.md](classify_leads_llm.md) for full details

4. **Upload to Google Sheet** (DELIVERABLE)
   - Run `execution/update_sheet.py` with the final JSON file (classified or original).
   - Script automatically uses chunked batch updates for datasets >1000 rows.
   - **Output**: Google Sheet URL (this is the actual deliverable the user receives).

5. **Enrich Missing Emails** (ALWAYS USE BULK API)
   - **IMPORTANT**: Always run `execution/enrich_emails.py` in the foreground and wait for completion before notifying the user.
   - Run: `python3 execution/enrich_emails.py <SHEET_URL>`
   - **Bulk API Strategy** (200+ rows, PREFERRED):
     - Creates a single AnyMailFinder bulk job for all missing emails
     - Processes ~1000 rows in 5 minutes (much faster than individual calls)
     - Automatically polls until complete
     - **Agent must wait** until enrichment finishes and sheet is updated
   - **Concurrent API Fallback** (<200 rows or if bulk fails):
     - Makes up to 20 concurrent individual API calls
     - Automatically used if bulk API fails
   - **Output**: Updated Google Sheet URL (final deliverable with enriched emails).
   - **Workflow**: DO NOT notify user until enrichment completes and sheet is updated.

## Outputs (Deliverables)
**The ONLY deliverable is the Google Sheet URL.** This sheet contains all verified leads with company info, contact details, etc.

**Important**: Local JSON files (`.tmp/test_leads.json`, `.tmp/leads_*.json`, `.tmp/classified_leads.json`) are temporary intermediates used for processing. They are NOT deliverables and should never be presented to the user as final outputs.

## Edge Cases
- **No leads found**: Apify returns empty list. -> Ask user to broaden search.
- **API Error**: Apify or Google API fails. -> Check credentials in `.env`.
- **Low quality classifications**: If >80% classified as "unclear", consider improving scrape keywords or using custom classification prompt.

## Error Handling
- **Authentication Error**: Ensure `APIFY_API_TOKEN` and `GOOGLE_APPLICATION_CREDENTIALS` are set.

Related Skills

Google SERP Lead Scraper

6
from Harmeet10000/skills

Scrapes Google search results for local businesses, fetches their websites, extracts contact information using GPT-5, and stores structured leads in Google Sheets.

Google Maps Lead Generation

6
from Harmeet10000/skills

Generate high-quality B2B leads from Google Maps with deep contact enrichment.

Goal: Build an LLM-based RAG App

6
from Harmeet10000/skills

Here is the MVP Implementation Plan.

You are a professional Landing page designer who is very friendly and supportive.

6
from Harmeet10000/skills

Your task is to guide a beginner through planning and designing a landing page or personal portfolio.

Workflow & Productivity

You are a professional Chief Marketing Officer. Your task is to help a user start and grow their social media presence organically through a series of questions and generate a growthplan.md blueprint.

6
from Harmeet10000/skills

Follow these instructions:

Marketing Strategy

Convert this into a web based slide deck using reveal.js.

6
from Harmeet10000/skills

Use the following brand colour and logo.

technical-article-writer

6
from Harmeet10000/skills

Write compelling technical articles and blog posts for developer audiences. Use this skill whenever the user asks to write a blog post, technical article, or any long-form technical content. Also trigger when the user says 'write about [technical topic]', 'help me draft an article', 'turn this into a blog post', 'write a post about', 'I want to publish something about', or mentions writing for a developer audience. Covers the full pipeline: idea sharpening, hook/title generation, article structure, body drafting, and editing. Even if the user just says 'I want to write about X' without specifying format, use this skill. Do NOT use for platform-specific optimization, newsletter strategy, or ghostwriting voice matching.

substack-ghostwriting

6
from Harmeet10000/skills

Write, optimize, and grow Substack content — both newsletter issues (email-first) and web posts (web-first articles/essays). Covers ghostwriting with voice matching, Substack algorithm optimization, Notes strategy, email formatting, SEO, growth tactics, and monetization planning. Use when the user mentions Substack, newsletters, write a newsletter issue, Substack post, Substack article, web post on Substack, evergreen content, SEO for Substack, newsletter growth, Notes strategy, ghostwrite for, match someone's voice, write in the style of, newsletter monetization, paid subscribers, or any task involving Substack as a platform. Also trigger for general article/newsletter writing even if Substack isn't named explicitly, or when the user wants to adapt existing content (blog post, talk, thread) into newsletter or web post format. Do NOT use for generic blog post writing without a newsletter/Substack context (-> See samber/cc-skills@technical-article-writer skill).

press-release-writer

6
from Harmeet10000/skills

Write professional press releases for any occasion, media type, and country. Use when the user wants to write, draft, or improve a press release, communiqué de presse, media announcement, news release, or PR statement — including product launches, funding rounds, partnerships, crisis communications, earnings, executive hires, events, M&A, open source milestones, and media advisories. Covers all release types, media targets (print, digital/wire, broadcast, social/SMPR, trade press), and region-specific conventions (Western/Eastern Europe, Americas, Middle East, Africa, Asia, Oceania). Also trigger when the user says 'I need to announce something' or 'how do I tell the press about X.'

pdf

6
from Harmeet10000/skills

Use this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple PDFs into one, splitting PDFs apart, rotating pages, adding watermarks, creating new PDFs, filling PDF forms, encrypting/decrypting PDFs, extracting images, and OCR on scanned PDFs to make them searchable. If the user mentions a .pdf file or asks to produce one, use this skill.

linkedin-ghostwriting

6
from Harmeet10000/skills

B2B LinkedIn ghostwriting — strategic interview, hook engineering, and post body. Use when the user wants to write LinkedIn content, create ghostwritten posts, ghostwrite for a founder or executive, develop a B2B social strategy, or needs hooks, post structures, or copywriting frameworks for LinkedIn. Apply when the user shares a story, result, or insight and wants it turned into a post.

docx

6
from Harmeet10000/skills

Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files). Triggers include: any mention of 'Word doc', 'word document', '.docx', or requests to produce professional documents with formatting like tables of contents, headings, page numbers, or letterheads. Also use when extracting or reorganizing content from .docx files, inserting or replacing images in documents, performing find-and-replace in Word files, working with tracked changes or comments, or converting content into a polished Word document. If the user asks for a 'report', 'memo', 'letter', 'template', or similar deliverable as a Word or .docx file, use this skill. Do NOT use for PDFs, spreadsheets, Google Docs, or general coding tasks unrelated to document generation.