# Texas Permit × Contractor License Leads (`recordstack/texas-permit-contractor-leads`) Actor

Austin building permits joined with the official Texas TDLR contractor license registry. Each row is a recent job plus the contractor who pulled it — license type, number, expiration, and business location verified against the state registry. Matched and verified, not just permits.

- **URL**: https://apify.com/recordstack/texas-permit-contractor-leads.md
- **Developed by:** [Alex Meacham](https://apify.com/recordstack) (community)
- **Categories:** Lead generation, Developer tools
- **Stats:** 2 total users, 1 monthly users, 50.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$40.00 / 1,000 matched permit lead delivereds

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

## Texas Permit × Contractor License Leads

**Fresh Austin building permits, joined to the official Texas contractor license registry — so every lead is a real job, pulled by a verified, licensed contractor.**

Permit data alone is a commodity (and free). What a sales pipeline actually needs is the join: *which licensed company just pulled which job, where, and is their license current?* That's what this actor produces.

### What you get

One row per permit whose contractor matched the Texas Department of Licensing and Regulation (TDLR) registry:

- The job: permit number, issue date, permit type/class, work class, project address and ZIP, description
- The contractor: company name as printed on the permit, and its trade
- The verification: license type, license number(s), expiration date, and whether the license was active on the run date — straight from TDLR's "All Licenses" dataset (updated daily on the Texas open-data portal)
- The business footprint: registry business city, county, ZIP, and the business telephone the registry publishes

### Who it's for

- **Building-materials, equipment, and software suppliers** building territory lists of *active* contractors — not stale directory entries.
- **Insurance, bonding, and compliance teams** who need license status tied to real work volume.
- **Home-services platforms** recruiting licensed pros who are demonstrably working right now.

### Inputs

| Input | What it does |
|---|---|
| Permits issued within (days) | Recency window, default 30 |
| Permit class | Austin permit class, or All |
| Contractor trade contains | e.g. `Electrical`, `Mechanical` |
| Only registry-matched permits | Default on — unmatched permits are skipped, not charged |
| Max results | Cap per run |

### Pricing

**$0.04 per matched lead row.** For comparison, multi-city permit aggregators on this store charge $0.05 per row for permit data *without* any license verification. You pay only for rows that matched.

### Honest notes on matching

- Matching is exact-after-normalization (case, punctuation, and legal suffixes like LLC/INC are normalized; DBA parentheticals dropped). It is deliberately conservative: on a measured batch of 200 recent Austin permits, **59 (~30%) matched**. The misses are mostly name variants we refuse to guess at — a wrong match is worse than a missing one.
- Match rate varies by trade. TDLR licenses electricians and A/C contractors, who match best. Texas does **not** license general contractors statewide, and plumbers are licensed by a different board (TSBPE, not in this dataset) — so GC and plumbing permits match at low rates. `registryMatchCount` and `licenseNumbersMatched` show every registry record behind a row, so you can audit any match.
- When several license records share a company name, the actor picks the one whose license type fits the permit's trade, then the closest business ZIP, then the latest expiration — and still lists all matched license numbers on the row.
- Personal-data discipline: individual names, personal phones, and mailing addresses that exist in the source systems are never requested or emitted. Business fields only, exactly as published in the public registries.
- Coverage today: City of Austin permits × the Texas statewide registry. The permit side is one config entry per open-data portal, so more Texas cities slot into the same schema over time.

### Verified before listing

Local end-to-end test, 2026-10-27: scanned 50 permits issued in the prior 30 days; 33 contractor names checked against the registry; 10 matched leads delivered (sample: `sample-output.json`) — e.g. an electrical permit for a new pool/spa joined to the contractor's Electrical Contractor license, expiry and business location. A separate 200-permit measurement put the overall match rate at ~30% (59/200).

# Actor input Schema

## `issuedWithinDays` (type: `integer`):

Only permits issued within this many days before the run.

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

Cap on lead rows delivered (and charged) in this run. The actor scans up to 5× this many permits to find matches.

## `onlyMatched` (type: `boolean`):

Recommended. When on (default), only permits whose contractor matched a TDLR license record are delivered. Turn off to also receive unmatched permits (flagged registryMatched=false) for raw territory data.

## `permitClass` (type: `string`):

Exact Austin permit class filter (e.g. 'Commercial'), or 'All'.

## `tradeContains` (type: `string`):

Case-insensitive substring matched against the permit's contractor trade (e.g. 'Electrical', 'Mechanical'). Leave empty for all trades.

## Actor input object example

```json
{
  "issuedWithinDays": 30,
  "maxResults": 100,
  "onlyMatched": true,
  "permitClass": "All",
  "tradeContains": "Electrical"
}
```

# Actor output Schema

## `datasetUrl` (type: `string`):

URL to the dataset containing the rows from this run.

# 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 = {
    "permitClass": "All"
};

// Run the Actor and wait for it to finish
const run = await client.actor("recordstack/texas-permit-contractor-leads").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 = { "permitClass": "All" }

# Run the Actor and wait for it to finish
run = client.actor("recordstack/texas-permit-contractor-leads").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 '{
  "permitClass": "All"
}' |
apify call recordstack/texas-permit-contractor-leads --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,recordstack/texas-permit-contractor-leads"
        }
    }
}
```

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/jgyzEEggeHYPBVKbM/builds/Yx0cGPfBLPUHLdqWv/openapi.json
