# Ultron — Lead-gen scrapers

Slow-daily lead generation via Saudi residential proxies (Evomi) on a Linux VPS.
Phase 1: **Google Maps**.

## What the Maps scraper collects
Per business: name, category, phone, website, address, rating, review count, GPS,
maps link — plus **email + social links** crawled from the website, and a
**freshness signal** (newly-added businesses = hotter leads) derived from review
count and the oldest/newest review dates.

## Setup (already done on the VPS)
- Ubuntu 24.04, Node 22, Google Chrome, 2 GB swap
- Proxy geo-targeting: username `USER__cr.sa` → rotating Saudi IPs

## Configure
Edit `config/targets.json`:
```json
{ "keywords": ["restaurant","coffee shop"], "locations": ["Riyadh","Jeddah"], "maxResultsPerSearch": 30 }
```

## Run
```bash
npm install          # first time
npm run maps         # scrapes every keyword x every location
```
Output → `data/maps_leads.csv` (append-only, de-duplicated by place).

## Files
- `src/browser.js` — Chrome launch: proxy auth, stealth, image/font blocking
- `src/maps.js` — search, scroll, detail + review-date extraction, freshness score
- `src/website.js` — email + social-link harvesting from business sites
- `src/output.js` — CSV writer
- `src/index.js` — orchestrator (reads config, loops, writes CSV)
