# B2B Leads Cleaner — Clean, Dedupe & Enrich Lead Lists (`abdelwarith/b2b-leads-cleaner`) Actor

Clean, deduplicate, and enrich B2B leads from JSON, CSV, or Excel. Remove duplicates, normalize phones to E.164, filter disposable emails, and enrich with company website data. 3 tiers starting at $4 per 1,000 leads.

- **URL**: https://apify.com/abdelwarith/b2b-leads-cleaner.md
- **Developed by:** [Khaled Attya](https://apify.com/abdelwarith) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $4.00 / 1,000 starter per leads

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## 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

## B2B Leads Cleaner

> Clean, deduplicate, and enrich your existing B2B leads — from JSON, CSV, or Excel.

### What it does

Transform raw B2B leads (from any source) into clean, ready-to-use data:

- UTF-8 normalization + address cleaning
- Phone numbers to E.164 format
- Email filtering (basic + advanced)
- Duplicate removal (text + geospatial)
- Website liveness check
- Email enrichment from company websites

### 3 Tiers

#### Starter — $4 / 1,000 leads

- UTF-8 + Address + URL cleaning
- Phone E.164
- Basic email filtering
- Text deduplication
- JSON input
- Max: 2,000 leads/run

#### Growth — $6 / 1,000 leads

- Everything in Starter
- File upload (Excel + CSV + JSON)
- Advanced email filtering (disposable + placeholder)
- Email enrichment (Layer 1 — free)
- Max: 1,000 leads/run

#### Pro — $8 / 1,000 leads

- Everything in Growth
- HTTP ping (live website check)
- Geospatial deduplication (50m + Levenshtein)
- Email enrichment (Layer 2 — Apify fallback)
- Priority queue
- Direct support
- Max: 500 leads/run

### Usage

#### JSON input

Send a JSON body like this:

```
{
  "plan": "starter",
  "leads": [
    {
      "business_name": "Test Cafe",
      "formatted_address": "Cairo",
      "international_phone": "01012345678"
    }
  ],
  "country_code": "EG"
}
```

#### File upload (Growth + Pro)

Upload .xlsx, .csv, or .json directly in the Actor input.

### Output

Each cleaned lead is pushed to the dataset with:

- business\_name, phone\_e164, extracted\_public\_emails
- is\_website\_alive, city, country
- All original fields preserved + cleaned

### Pricing

- $0.10 per run start
- $4.00 / 1,000 leads (Starter)
- $6.00 / 1,000 leads (Growth)
- $8.00 / 1,000 leads (Pro)

### Support

For Pro tier: direct support.
For other tiers: community support.

# Actor input Schema

## `plan` (type: `string`):

Starter (Clean Basic) | Growth (Clean + L1) | Pro (Full Power)

## `leads` (type: `array`):

Raw leads as JSON array. Use this OR 'file'.

## `file` (type: `string`):

Upload file (Growth + Pro only)

## `country_code` (type: `string`):

ISO 3166-1 alpha-2 (EG, US, GB, ...)

## Actor input object example

```json
{
  "plan": "starter",
  "leads": [
    {
      "business_name": "Test Cafe",
      "formatted_address": "17 El Mansour St, Cairo",
      "international_phone": "01022539955"
    }
  ],
  "country_code": "EG"
}
```

# Actor output Schema

## `dataset` (type: `string`):

Cleaned, deduplicated, and enriched B2B leads

## `stats` (type: `string`):

Input count, output count, duplicates removed

# 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 = {
    "leads": [
        {
            "business_name": "Test Cafe",
            "formatted_address": "17 El Mansour St, Cairo",
            "international_phone": "01022539955"
        }
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("abdelwarith/b2b-leads-cleaner").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 = { "leads": [{
            "business_name": "Test Cafe",
            "formatted_address": "17 El Mansour St, Cairo",
            "international_phone": "01022539955",
        }] }

# Run the Actor and wait for it to finish
run = client.actor("abdelwarith/b2b-leads-cleaner").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 '{
  "leads": [
    {
      "business_name": "Test Cafe",
      "formatted_address": "17 El Mansour St, Cairo",
      "international_phone": "01022539955"
    }
  ]
}' |
apify call abdelwarith/b2b-leads-cleaner --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,abdelwarith/b2b-leads-cleaner"
        }
    }
}
```

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/tSR6H22KHbYplWBeJ/builds/03brsMqDt7fMT4hHx/openapi.json
