# Illinois Roofing Contractor Directory & Leads Scraper (IDFPR) (`muhammadafzal/illinois-roofing-contractor-directory-leads-scraper`) Actor

Search public Illinois IDFPR records for licensed roofing contractor businesses by city, county, ZIP, business name, or license number. Returns deduplicated business license and public discipline details.

- **URL**: https://apify.com/muhammadafzal/illinois-roofing-contractor-directory-leads-scraper.md
- **Developed by:** [Muhammad Afzal](https://apify.com/muhammadafzal) (community)
- **Categories:** Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.80 / 1,000 idfpr roofing contractor records

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## Illinois Roofing Contractor Directory & Leads Scraper (IDFPR)

Search the Illinois Department of Financial and Professional Regulation (IDFPR) public licensing dataset for **licensed roofing contractor businesses**. Filter by city, county, mailing state, ZIP, business name, or license number, then export deduplicated license and public discipline records.

The IDFPR dataset contains license and location details, not business websites, phone numbers, or email addresses. This Actor does not invent or infer those contact fields. It excludes qualifying-party records and individual-only license records so the default output stays focused on licensed businesses.

**Free plan:** up to 5 business records per run. **Paid plan:** request up to 5,000 records per run. The live total-charge cap can reduce that limit further.

### Output

Each dataset item represents one unique licensed roofing contractor business and includes:

- Business name, DBA, license number, and IDFPR license status
- City, state, ZIP, and county from the public record
- Original issue, effective, expiration, and source last-modified dates
- IDFPR's historical discipline flag and any published case/action details
- The source dataset link and official IDFPR lookup page for verification

The source can contain multiple rows for a license when IDFPR lists several discipline actions. The Actor merges those rows into one business record and keeps each distinct discipline entry.

### Input

| Field | Default | Description |
| --- | --- | --- |
| `city` | empty | Exact city in the public record |
| `county` | empty | Exact county, such as `COOK` |
| `state` | empty | Two-letter mailing-state filter; blank includes out-of-state businesses licensed in Illinois |
| `zip` | empty | Exact ZIP or ZIP+4 |
| `businessNameContains` | empty | Partial match on the IDFPR business name or DBA |
| `licenseNumber` | empty | Exact license number; dots, spaces, and hyphens are ignored |
| `includeInactiveStatuses` | `false` | Include records with statuses other than `ACTIVE` |
| `maxResults` | `50` | Maximum unique businesses, from 1 to 5,000; free-plan runs are capped at 5 |
| `pageSize` | `500` | Source API page size, from 1 to 1,000 |
| `maxRetries` | `2` | Retries for temporary network, rate-limit, and server errors, from 0 to 3 |

With no filters, the Actor returns the first matching records in license-number order up to the effective limit. It uses the source's public JSON endpoint, applies bounded pagination, and stops when it reaches the result, request, or charge limit.

#### Example input

```json
{
  "county": "COOK",
  "state": "IL",
  "includeInactiveStatuses": false,
  "maxResults": 100
}
```

To search a specific company:

```json
{
  "businessNameContains": "ACCREDITED ROOFING",
  "state": "IL",
  "maxResults": 10
}
```

### Pricing

This Actor uses pay-per-event pricing. Platform usage for its run is included in the event price; the platform-usage pass-through option is disabled. A run start is charged once. A result event is charged automatically for each item successfully written to the default dataset.

| Event | FREE | BRONZE | SILVER | GOLD, PLATINUM, DIAMOND |
| --- | ---: | ---: | ---: | ---: |
| Actor start | $0.005 | $0.005 | $0.005 | $0.005 |
| One IDFPR business record | $0.001 | $0.000975 | $0.00095 | $0.0008 |

Representative FREE-tier event totals are $0.006 for one result and $0.010 for five results, before any account charges outside this Actor run. The configured total-charge cap is honored conservatively using the FREE-tier result price.

### Source and verification

- [IDFPR License Lookup information](https://idfpr.illinois.gov/checklicense.html) links to the public Professional Regulation lookup and the bulk-license data portal. IDFPR describes single lookups as updated daily and bulk lookup data as updated weekly.
- [IDFPR Roofing Contractor page](https://idfpr.illinois.gov/profs/roof.html) identifies the regulated license as “Roofing Contractor, Licensed.”
- [Illinois Open Data: Professional Licensing](https://data.illinois.gov/Business-and-Workforce/Professional-Licensing/pzzh-kp68/about_data) is the dataset used by this Actor. Its public API provides the license, status, business, and mailing-location fields.
- [Official IDFPR License Lookup](https://online-dfpr.micropact.com/lookup/licenselookup.aspx) should be used to verify current status for consequential decisions. The separate monthly Active License Report is informational and is not an official license verification.

The Actor filters the source to `ROOFING CONTRACTOR`, `LICENSED ROOFING CONTRACTOR`, and business records. It does not return the related “Qualifying Party Roofing Contractor” occupation as a business lead. Public source data can lag or change; use the official lookup for current verification.

### Responsible use

This Actor retrieves public business licensing information from a State of Illinois open-data source. It does not access accounts, submit forms, solve CAPTCHAs, or collect private contact data. Use the records lawfully and follow applicable marketing and privacy requirements.

# Actor input Schema

## `city` (type: `string`):

Optional exact mailing city from the IDFPR record, such as CHICAGO.

## `county` (type: `string`):

Optional exact county from the IDFPR record, such as COOK or DUPAGE.

## `state` (type: `string`):

Optional two-letter mailing-state filter. Leave blank to include out-of-state businesses licensed by Illinois.

## `zip` (type: `string`):

Optional exact ZIP or ZIP+4 from the public record.

## `businessNameContains` (type: `string`):

Optional partial match against the IDFPR business name or DBA. Individual qualifying-party records are excluded.

## `licenseNumber` (type: `string`):

Optional exact Illinois roofing contractor license number. Dots, spaces, and hyphens are ignored.

## `includeInactiveStatuses` (type: `boolean`):

Include IDFPR business records with any source status, including suspended, expired, revoked, or not renewed. The status is returned as published by IDFPR.

## `maxResults` (type: `integer`):

Maximum unique business license records to save. Free-plan runs are capped at 5; paid runs can request up to 5,000. Start with 3 to review the records.

## `pageSize` (type: `integer`):

Rows requested per page from the public Illinois data API. Smaller pages use more requests when exporting larger lists.

## `maxRetries` (type: `integer`):

Bounded retries for temporary network, rate-limit, and server errors.

## Actor input object example

```json
{
  "city": "",
  "county": "",
  "state": "",
  "zip": "",
  "businessNameContains": "",
  "licenseNumber": "",
  "includeInactiveStatuses": false,
  "maxResults": 3,
  "pageSize": 100,
  "maxRetries": 2
}
```

# Actor output Schema

## `results` (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 = {
    "city": "",
    "county": "",
    "state": "",
    "zip": "",
    "businessNameContains": "",
    "licenseNumber": "",
    "includeInactiveStatuses": false,
    "maxResults": 3,
    "pageSize": 100,
    "maxRetries": 2
};

// Run the Actor and wait for it to finish
const run = await client.actor("muhammadafzal/illinois-roofing-contractor-directory-leads-scraper").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 = {
    "city": "",
    "county": "",
    "state": "",
    "zip": "",
    "businessNameContains": "",
    "licenseNumber": "",
    "includeInactiveStatuses": False,
    "maxResults": 3,
    "pageSize": 100,
    "maxRetries": 2,
}

# Run the Actor and wait for it to finish
run = client.actor("muhammadafzal/illinois-roofing-contractor-directory-leads-scraper").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 '{
  "city": "",
  "county": "",
  "state": "",
  "zip": "",
  "businessNameContains": "",
  "licenseNumber": "",
  "includeInactiveStatuses": false,
  "maxResults": 3,
  "pageSize": 100,
  "maxRetries": 2
}' |
apify call muhammadafzal/illinois-roofing-contractor-directory-leads-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,muhammadafzal/illinois-roofing-contractor-directory-leads-scraper"
        }
    }
}
```

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/O36D2lB54tQI67Azh/builds/x89Nu0p9WugZbPaqj/openapi.json
