# Uk Trades Lead List (`handlet/uk-trades-lead-list`) Actor

- **URL**: https://apify.com/handlet/uk-trades-lead-list.md
- **Developed by:** [Ellis Marshall](https://apify.com/handlet) (community)
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-usage

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## UK Trades Lead List Generator

An Apify Actor that builds enriched, scored lead lists of UK trades businesses (plumbers, window cleaners, electricians, etc.) by combining Google Maps data with Companies House verification, website enrichment and booking technology detection.

Built by [Handlet](https://handlet.ai), the AI office assistant for UK trades.

### What it does

This Actor finds and scores local trades businesses to help you identify the best prospects for your B2B services. It:

1. **Searches Google Maps** for trades businesses in your target locations (e.g. "window cleaner Peterborough")
2. **Deduplicates** by phone number, website domain and business name + postcode
3. **Enriches websites** to find public business emails, booking forms (Calendly, Jobber, ServiceM8, etc.), chat widgets (Intercom, Tidio, WhatsApp) and age/slowness signals
4. **Matches to Companies House** to verify limited companies, find directors and incorporation dates (sole traders marked separately for PECR compliance)
5. **Scores each lead 0-100** based on technology gaps (no booking form, old website), business type (active Ltd) and credibility signals
6. **Filters** by rating, reviews, company type, chains/franchises, website and email requirements

#### Example output

| Score | Business | Phone | Email | Postcode | Rating | Reviews | Ltd/Sole | Contact rule |
|-------|----------|-------|-------|----------|--------|---------|----------|--------------|
| 87 | Crystal Clear Windows | 01480 123456 | info@crystalclear.co.uk | PE28 5WW | 4.8 | 12 | ltd | B2B email allowed with opt-out |
| 76 | John's Window Cleaning | 07700 900123 | (none) | PE28 4AB | 4.9 | 6 | sole_trader_or_unknown | do not cold email (PECR: individual subscriber) |

Every lead includes:

- **Business name, phone, email, website, address, postcode**
- **Rating and review count** from Google Maps
- **Ltd or sole trader** (verified against Companies House)
- **Company number, directors, incorporation date** (for limited companies)
- **Booking form** (true/false or unknown)
- **Chat widget** (intercom, tidio, whatsapp, etc. or none)
- **Score 0-100** with reasons explaining why they're a good or poor fit
- **Contact rule** (PECR guidance: B2B email allowed vs individual subscriber)

### How scoring works

Every lead starts at 30 points and gains or loses points based on:

| Points | Reason |
|--------|--------|
| +15 | No online booking form (needs your solution) |
| +10 | Active limited company (stable, creditworthy) |
| +10 | Public business email found |
| +10 | Good rating (4.0+) but small review count (3-29) |
| +8 | Slow website (>2.5 seconds) |
| +8 | Old-looking website (no HTTPS, no viewport, old copyright year) |
| +4 | No chat widget |
| +4 | Recently incorporated (within 2 years) |
| +3 | Phone number available |
| +2 | No reviews yet |
| -5 | Very established review base (150+ reviews) |
| -25 | Looks like a chain or franchise |

Scores help you prioritise leads who need your product (e.g. booking systems for trades without one) and avoid saturated markets or large chains.

### PECR and GDPR compliance

This Actor collects **business contact data only**. No personal home addresses are included.

Under the Privacy and Electronic Communications Regulations (PECR), you can email limited companies for B2B purposes with an opt-out, but **sole traders and partnerships are "individual subscribers"** and cold email to them is not allowed without consent.

The `contact_rule` field encodes this:

- **Ltd** (matched at Companies House): `B2B email allowed with opt-out`
- **Sole trader / unknown**: `do not cold email (PECR: individual subscriber)`

#### Important notes

- Sole traders can still be contacted by **phone** (but honour TPS/CTPS registrations)
- Director names come from **Companies House public officer records** only (not scraped from websites)
- Always include an opt-out mechanism in your emails and honour TPS/CTPS when phoning
- This is a research aid, not legal advice. Consult a solicitor if unsure about your marketing practices

The `exclude_sole_traders_from_email` behaviour is built into the `contact_rule` field. Use it to filter your outreach lists.

### Inputs

#### Search

- **Trade keywords** (required): One or more trades to search for, e.g. "window cleaner", "gutter cleaning", "plumber". Multiple keywords are combined.
- **UK postcodes or towns** (required): Each location is searched as `<keywords> <location>`. Start small (1-3 locations) to control costs.
- **Max results per location** (default 50): Google Maps places per location. The Maps Actor bills per result, so start with 10-20 for testing.
- **Max results total** (optional): Overall cap across all locations. Leave empty for no limit.

#### Companies House

- **Companies House API key** (optional): Get a free key from [developer.company-information.service.gov.uk](https://developer.company-information.service.gov.uk). Without a key, all leads are marked as `sole_trader_or_unknown`.

#### Filters

- **Minimum rating** (e.g. 4.0): Filter out leads below this rating.
- **Minimum reviews** (e.g. 3): Filter out leads with fewer reviews.
- **Only limited companies**: Keep only leads matched to an active limited company (requires Companies House key).
- **Exclude chains and franchises**: Remove likely chains (Checkatrade, Safestyle, Everest, Dyno, Pimlico, etc.).
- **Require website**: Keep only leads with a website listed.
- **Require email**: Keep only leads where a public business email was found.

#### Enrichment

- **Include Checkatrade** (default false): Best-effort Checkatrade listings. Skipped gracefully if blocked.

### Outputs

- **Overview** (table view): Key fields only (score, business, phone, email, postcode, rating, reviews, ltd/sole, contact rule)
- **Leads (full)** (table view): All enrichment fields including directors, booking form, chat widget, score reasons
- **Leads CSV**: Download as CSV for import into your CRM or Google Sheets
- **Run summary (JSON)**: Counts (found, after filters, ltd, sole trader, with email, average score)

### Cost estimate

**Google Maps Actor**: The `compass/crawler-google-places` Actor bills per result (place) scraped. At typical Apify pricing (~$0.01-0.02 per result depending on your plan), a run with 3 locations × 50 results = 150 places costs roughly $1.50-3.00 in Maps usage.

**Compute**: Website enrichment and Companies House matching use your Actor compute hours (typically a few cents per run).

**Total example**: 150 leads = ~$1.50-3.00. Start small (10 results per location) to test before scaling up.

### Tips for best results

1. **Start small**: Use 1-2 locations and `maxResultsPerLocation: 10` for your first run. Scale up once you're happy with the output.
2. **Get a Companies House key**: It's free and dramatically improves lead quality by identifying limited companies vs sole traders.
3. **Use filters wisely**: `minRating: 4.0` and `minReviews: 3` remove unproven businesses. `excludeChains: true` focuses on independent trades.
4. **Export to Google Sheets**: Download the CSV and import into Google Sheets for easy sorting and CRM integration.
5. **Schedule weekly runs**: Use Apify's scheduler to build your lead list over time (e.g. "window cleaner" in a different town each week).
6. **Combine keywords**: Use `tradeKeywords: ["window cleaner", "gutter cleaning"]` to find businesses offering multiple services.

### FAQ

**Q: Why are some leads marked as sole_trader_or_unknown?**

A: Without a Companies House key, or if the business name doesn't match an active limited company, leads are marked unknown. Get a free key to improve matching.

**Q: Can I search multiple trades at once?**

A: Yes. Use `tradeKeywords: ["window cleaner", "gutter cleaning", "oven cleaning"]` to find businesses offering any of those services.

**Q: Why is the email field empty for some leads?**

A: Many trades businesses don't publish an email on their homepage. The Actor checks the homepage and `/contact` page, but some businesses only use contact forms or phone.

**Q: What does "B2B email allowed with opt-out" mean?**

A: Under PECR, you can send marketing emails to limited companies for B2B purposes, but you must include an opt-out mechanism (e.g. unsubscribe link).

**Q: Can I use this for cold calling?**

A: Yes, but honour the Telephone Preference Service (TPS) and Corporate TPS (CTPS) registrations. This Actor doesn't check TPS status.

**Q: How do I integrate this with Make (formerly Integromat) or Zapier?**

A: Use Apify's webhooks to trigger your automation when a run finishes, then fetch the dataset via the Apify API. See [Apify's integration docs](https://docs.apify.com/integrations).

**Q: Why do some leads have a low score?**

A: Low scores typically mean the business is very established (150+ reviews), looks like a chain/franchise, or has modern booking technology already (so they don't need your solution).

### Limitations

- **Google Maps only**: This Actor relies on Google Maps as the primary data source. Businesses not listed on Google Maps won't appear.
- **Email extraction is best-effort**: Only emails visible on the homepage or `/contact` page are found. Many trades use contact forms instead.
- **Checkatrade is optional**: Checkatrade often blocks scrapers. If you enable it and it fails, the run continues without Checkatrade data.
- **Companies House matching is fuzzy**: Name variations (e.g. "Joe's Plumbing" vs "Joe's Plumbing Services Ltd") may not match. Matching improves with a postcode.
- **No TPS checking**: You must check TPS/CTPS registrations separately before calling leads.

### Changelog

**0.1** (2026-10-11)

- Initial release
- Google Maps + Companies House + website enrichment
- Scoring system with filters
- PECR-compliant contact rules
- Dataset views and CSV export

### Local development

```bash
pip install -r requirements-dev.txt
npm i -g apify-cli
export APIFY_TOKEN=...  # needed for Actor.call to run the Maps Actor
export COMPANIES_HOUSE_API_KEY=...  # optional
apify run --input-file example_input.json
```

Results land in `storage/datasets/default` and `storage/key_value_stores/default/leads.csv`.

### Tests and lint

```bash
ruff check . && pytest
```

Tests cover scoring, dedupe/normalisation, Companies House matching (mocked HTTP), enrichment and output shaping.

### Support

For issues or feature requests, open an issue on GitHub or contact [Handlet](https://handlet.ai).

# Actor input Schema

## `tradeKeywords` (type: `array`):

Trades to search for (e.g. 'window cleaner', 'gutter cleaning', 'plumber'). Multiple keywords are combined into one search.

## `locations` (type: `array`):

Each location is searched as '<keywords> <location>'. Start small to control costs.

## `maxResultsPerLocation` (type: `integer`):

Maximum Google Maps places per location. The Maps Actor bills per result.

## `maxResultsTotal` (type: `integer`):

Overall cap across all locations. Leave empty for no total limit.

## `companiesHouseApiKey` (type: `string`):

Get a free key from developer.company-information.service.gov.uk. Falls back to COMPANIES_HOUSE_API_KEY environment variable. Without a key, Companies House matching is skipped (all leads marked as sole_trader_or_unknown).

## `minRating` (type: `number`):

Filter out leads with a rating below this value (e.g. 4.0). Leave empty for no filter.

## `minReviews` (type: `integer`):

Filter out leads with fewer reviews than this. Leave empty for no filter.

## `onlyLtd` (type: `boolean`):

Keep only leads matched to an active limited company at Companies House. Requires a Companies House API key.

## `excludeChains` (type: `boolean`):

Remove likely chains and franchises (Checkatrade, Safestyle, Everest, Dyno, Pimlico, etc.).

## `requireWebsite` (type: `boolean`):

Keep only leads with a website listed.

## `requireEmail` (type: `boolean`):

Keep only leads where a public business email was found on their website.

## `includeCheckatrade` (type: `boolean`):

Best-effort Checkatrade listings. Skipped gracefully if blocked.

## Actor input object example

```json
{
  "tradeKeywords": [
    "window cleaner"
  ],
  "locations": [
    "PE28 5WW",
    "Huntingdon",
    "Peterborough"
  ],
  "maxResultsPerLocation": 50,
  "onlyLtd": false,
  "excludeChains": false,
  "requireWebsite": false,
  "requireEmail": false,
  "includeCheckatrade": false
}
```

# Actor output Schema

## `leads` (type: `string`):

No description

## `overview` (type: `string`):

No description

## `leadsCsv` (type: `string`):

No description

## `summary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "locations": [
        "PE28 5WW",
        "Huntingdon",
        "Peterborough"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("handlet/uk-trades-lead-list").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "locations": [
        "PE28 5WW",
        "Huntingdon",
        "Peterborough",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("handlet/uk-trades-lead-list").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "locations": [
    "PE28 5WW",
    "Huntingdon",
    "Peterborough"
  ]
}' |
apify call handlet/uk-trades-lead-list --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,handlet/uk-trades-lead-list"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/bpwcjsH6B3qiUXlGf/builds/Dk8udVfnW3XaGyWQ9/openapi.json
