Automated Lead Generation with AI Agents: Scrape → Enrich → Score → Close (2026 Playbook)
The key is not just scraping data — it is building a complete pipeline that goes from raw web data to scored, enriched leads in your CRM, automatically.
This playbook covers the architecture, tool-by-tool setup, cost model, and compliance framework for building an AI lead generation system in 2026.
TL;DR:
| Pipeline stage | Tool | What it does |
|---|---|---|
| Source | Apify Google Maps, LinkedIn, directory scrapers | Collect raw lead data from public sources |
| Enrich | Claude API / Ollama (local) | Add company data, tech stack, revenue estimates |
| Score | Claude API / Ollama | Rate leads 1–10 against your Ideal Customer Profile (ICP) |
| Route | Clay, HubSpot, Google Sheets | Push scored leads to CRM |
| Orchestrate | n8n / Make.com | Automate the entire pipeline on schedule |
Prerequisites:
- Apify account (Starter plan: $29/mo for production use)
- Claude API key or self-hosted Ollama (see Self-Host AI Stack)
- CRM account (HubSpot free, Clay, or Google Sheets)
- n8n or Make.com for orchestration
The 2026 AI lead gen architecture
┌───────────────────────────────────────────────────────────────────────┐
│ AI Lead Generation Pipeline │
│ │
│ ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐ │
│ │ SOURCE │──▶│ ENRICH │──▶│ SCORE │──▶│ ROUTE │ │
│ │ │ │ │ │ │ │ │ │
│ │ Apify │ │ Claude/ │ │ Claude/ │ │ Clay / │ │
│ │ Scrapers │ │ Ollama │ │ Ollama │ │ HubSpot │ │
│ │ │ │ │ │ │ │ │ │
│ │ Google │ │ Company │ │ ICP fit │ │ Auto- │ │
│ │ Maps, │ │ data, │ │ score │ │ assign │ │
│ │ LinkedIn, │ │ tech │ │ 1-10 │ │ to rep │ │
│ │ dirs │ │ stack │ │ │ │ │ │
│ └──────────┘ └──────────┘ └──────────┘ └──────────┘ │
│ │
│ ┌──────────────────────────────────────────────────────────────┐ │
│ │ n8n / Make.com (Orchestrator) │ │
│ │ Schedules, retries, error handling, alerts │ │
│ └──────────────────────────────────────────────────────────────┘ │
└───────────────────────────────────────────────────────────────────────┘
Step 1: Define your ICP (Ideal Customer Profile)
Before scraping anything, define who you're looking for. This drives every downstream decision.
Use this Claude prompt template to construct your ICP:
Based on [your company]'s product and pricing, define our Ideal Customer Profile:
1. Company size: [10-200 employees]
2. Industry: [B2B SaaS, e-commerce, fintech]
3. Revenue range: [$1M-$50M ARR]
4. Geography: [US, EU, UK]
5. Tech stack signals: [Uses Stripe, AWS, React]
6. Buying signals: [Recently raised funding, hiring engineers, expanding product]
7. Disqualifiers: [Government, enterprise >5000, outside target geo]
In that template, ARR stands for Annual Recurring Revenue — a common shorthand for company scale. Store your ICP as a structured prompt that feeds into the scoring step.
Step 2: Source identification and Apify scraping
Google Maps leads (local businesses, agencies, services)
The Google Maps Scraper is the highest-value Apify Actor for lead generation:
{
"searchStringsArray": ["marketing agencies in Austin TX", "SaaS companies in San Francisco"],
"maxCrawledPlacesPerSearch": 100,
"language": "en",
"includeWebResults": true
}
Verify
includeWebResultsand other fields against the current Google Maps Scraper input schema — Actor inputs change over time.
Output per lead: company name, address, phone, website, rating, review count, category, opening hours.
LinkedIn leads (B2B professionals)
Use Apify's LinkedIn scrapers from the Apify Store:
- Company profiles — employee count, industry, headquarters, recent posts
- Job postings — hiring signals (AI, engineering expansion)
- People profiles — decision-makers in target companies
LinkedIn actively blocks scraping. Use residential proxies, low concurrency (1-2 requests/second), and comply with LinkedIn's Terms of Service. For high-volume enterprise use, consider LinkedIn Sales Navigator API. See Best Proxies for LinkedIn Scraping.
Industry directories and websites
Use the Website Content Crawler for:
- SaaS directory listings (G2, Capterra, ProductHunt)
- Industry association member pages
- Conference attendee lists (publicly available)
For the complete scraping guide, see Web Scraping Lead Generation Guide.
Step 3: AI enrichment
For each scraped lead, enrich with additional data using Claude or Ollama.
Enrichment prompt
Analyze this company based on their website content and available data.
Extract and return as JSON:
{
"company_name": "string",
"employee_estimate": "number or range",
"industry": "string",
"tech_stack_signals": ["list of technologies detected"],
"revenue_tier": "pre-revenue | <$1M | $1M-$10M | $10M-$50M | $50M+",
"business_model": "B2B SaaS | B2C | marketplace | services | other",
"recent_news": "string (latest announcement or milestone)",
"key_decision_makers": ["list of C-level/VP titles found"]
}
Company website content:
[scraped content here]
Implementation options
| Option | Cost | Quality | Speed |
|---|---|---|---|
| Claude API (Sonnet) | ~$0.003-$0.01 per lead | High | 2-5 sec/lead |
| Claude API (Haiku) | ~$0.0005-$0.002 per lead | Medium | 1-2 sec/lead |
| Ollama (Llama 3.1 8B) | $0 (self-hosted VPS cost) | Medium | 3-10 sec/lead |
For high-volume enrichment (1,000+ leads/day), self-hosted Ollama is the most cost-effective. See Self-Host Ollama + n8n + Coolify.
Step 4: AI lead scoring
Score each enriched lead against your ICP from Step 1.
Scoring prompt
You are a B2B sales qualification expert.
Score this lead 1-10 against our ICP:
- Target: B2B SaaS companies, 10-200 employees, $1M-$50M ARR
- Geography: US or EU
- Tech signals: Uses cloud infrastructure, modern web stack
- Buying signals: Recently hired, raised funding, expanding product
Lead data:
[enriched lead JSON]
Respond with ONLY this JSON:
{
"score": 8,
"reasoning": "One sentence explaining the score",
"recommended_outreach": "personalized | template | skip",
"outreach_angle": "One sentence on best approach"
}
Score distribution targets
| Score | Meaning | Action | Expected % of leads |
|---|---|---|---|
| 9–10 | Perfect ICP fit + buying signals | Priority outreach (personalized) | 5–10% |
| 7–8 | Good ICP fit | Standard outreach (semi-personalized) | 15–25% |
| 5–6 | Partial fit | Nurture sequence | 25–35% |
| 1–4 | Poor fit | Skip or archive | 30–50% |
Step 5: CRM push
Option A: Clay
Clay is built for AI-enriched lead workflows:
- Create a Clay table with columns matching your enrichment schema
- Use Clay's API integration to push enriched leads
- Clay handles deduplication and further enrichment automatically
See Apify + Clay Integration and Clay CRM Review 2026.
Option B: HubSpot
Push scored leads to HubSpot via their API:
# Note: `ai_fit_score` is not a default HubSpot property.
# Before running this, create a custom contact property in HubSpot:
# Settings → Properties → Create property → Contact → Number type → Name: ai_fit_score
# Then use the internal name you chose (e.g., "ai_fit_score") in your API calls.
{
"url": "https://api.hubapi.com/crm/v3/objects/contacts",
"method": "POST",
"headers": {
"Authorization": "Bearer YOUR_HUBSPOT_TOKEN",
"Content-Type": "application/json"
},
"body": {
"properties": {
"email": "lead@company.com",
"company": "Acme Corp",
"ai_fit_score": "8",
"lead_source": "ai_pipeline"
}
}
}
See Make.com + HubSpot CRM Automation.
Option C: Google Sheets
For teams not ready for a CRM, Google Sheets works:
- Push enriched leads as new rows
- Use conditional formatting for score-based highlighting
- Share with the team for manual follow-up
Step 6: Orchestration with n8n or Make.com
n8n workflow
[Schedule: Daily 06:00]
→ [Apify API: Run Google Maps Scraper]
→ [Wait for completion]
→ [Apify API: Fetch dataset]
→ [Loop: For each lead]
→ [HTTP: Scrape company website via Apify]
→ [HTTP: Call Ollama/Claude for enrichment]
→ [HTTP: Call Ollama/Claude for scoring]
→ [IF: Score >= 7]
→ [HTTP: Push to HubSpot]
→ [Slack: Alert "New qualified lead"]
→ [ELSE]
→ [Google Sheets: Archive]
Make.com workflow
The same logic in Make.com with visual modules. See Make.com Lead Generation Pipeline for step-by-step.
Cost model
Projected costs per 500 leads processed:
| Component | Cost per 500 leads | Notes |
|---|---|---|
| Apify scraping (Google Maps) | ~$5–10 | ~100 CU (compute units, Apify's usage billing unit) for 500 listings |
| Apify scraping (company websites) | ~$10–20 | Website Content Crawler, 5 pages each |
| Claude API enrichment (Sonnet) | ~$1.50–5 | ~1,000 tokens/lead |
| Claude API scoring | ~$0.50–2 | ~300 tokens/lead |
| CRM | $0–49 | HubSpot free, Clay $149+ |
| Orchestration | $0–49 | n8n self-hosted free, Make.com $9+ |
| Total per 500 leads | ~$17–85 | |
| Cost per lead | $0.03–0.17 | vs $5–15 for manual research |
With self-hosted Ollama replacing Claude API, the enrichment and scoring cost drops to $0, bringing the per-lead cost to $0.02–0.06.
Compliance: General Data Protection Regulation (GDPR), CAN-SPAM, and ethical scraping
| Regulation | What it covers | Your obligation |
|---|---|---|
| GDPR (gdpr.eu) | EU personal data | Legitimate interest basis for B2B prospecting; right to deletion; data minimization |
| CAN-SPAM | US commercial email | Opt-out mechanism, physical address, no deceptive headers |
| CCPA | California consumer data | Right to know, right to delete, right to opt-out |
| Ethical scraping | Apify compliance guide | Respect robots.txt, rate limits, no login circumvention |
Practical guidelines:
- Only scrape publicly available business data
- Never scrape behind login walls without permission
- Include unsubscribe links in all outreach emails
- Implement a deletion process for GDPR requests
- Minimize personal data: collect only what you need
- Document your legitimate interest basis for B2B prospecting
With the recommended setup: 200-1,000 leads/day on Apify Starter plan ($29/month). Bottleneck is usually the Apify compute units, not the AI processing. For higher volume, upgrade to Apify Scale or use multiple Actor instances.
Google Maps data is publicly accessible and scraping for business purposes is generally accepted. LinkedIn's Terms of Service prohibit scraping; enforcement varies. For LinkedIn, consider official APIs (Sales Navigator) or accept the risk of account restrictions. Always consult legal counsel for your specific jurisdiction.
On well-defined ICP criteria with good enrichment data, expect 70-85% agreement with human scoring. The main failure mode is insufficient data — if the company website is sparse, the score is unreliable. Mitigate by adding a confidence field to your scoring prompt and flagging low-confidence scores for human review.
Claude API (Sonnet) produces higher quality enrichments but costs $0.003-$0.01 per lead. Self-hosted Ollama (Llama 3.1 8B) is free per-lead but requires a $12-25/month VPS and produces slightly lower quality output. Use Claude for high-value leads (under 100/day), Ollama for bulk processing (1,000+/day).
Implement deduplication at the pipeline level: hash email + company name as a unique identifier. Use upsert (update-or-insert) operations instead of creates. Clay handles deduplication natively. For HubSpot, use the search-before-create pattern.
Google Maps Scraper for local businesses and agencies. Website Content Crawler for company data enrichment. Google Search Scraper for finding company websites by name. See our Best Lead Generation Actors guide for the complete list.
Yes, but add compliance safeguards: verify email addresses before sending, include unsubscribe links, and honor opt-out requests within **10 business days** as required by **CAN-SPAM** — confirm current FTC guidance at ftc.gov CAN-SPAM compliance. Never send to purchased lists without legal review. The scoring step should filter leads where outreach is inappropriate.
ZoomInfo ($15,000-$30,000/year) and Apollo ($49-$119/month) provide pre-built databases. This pipeline builds a custom database from public sources at $17-85 per 500 leads. The trade-off: you invest setup time but get fresher data, custom enrichment, and no per-seat licensing.
AI lead generation in 2026 is not about replacing sales people — it is about giving them better data, faster. The pipeline above processes raw web data into scored, enriched CRM records at $0.03–$0.17 per lead, compared to $5–15 for manual research.
Start with one source (Google Maps is the fastest to set up), build the pipeline end-to-end, validate lead quality, then expand to LinkedIn and directories.
Sign up on Apify to start scraping leads today. For visual pipeline building, create a Make.com account. For AI-powered CRM, evaluate Clay.
