# Dallas TX Building Permits - New Permit Feed (`themartygriffin/dallas-building-permits-feed`) Actor

New City of Dallas building permits since your last run: residential and commercial, new construction, alterations, demolition and trade permits, filtered by type, ZIP, value or keyword. Includes the contractor on the permit. Dallas publishes on business days.

- **URL**: https://apify.com/themartygriffin/dallas-building-permits-feed.md
- **Developed by:** [Marty Griffin](https://apify.com/themartygriffin) (community)
- **Categories:** Real estate, Business
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$5.00 / 1,000 permits

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

## Dallas Building Permits — New Permit Feed

New City of Dallas building permits since your last run: the issued-permit register, cleaned into one
record per permit — number, type, issue date, address, ZIP, scope of work and square footage.

Run it on a schedule and each run returns only what is new since the last one. Dallas issues roughly
5,000–6,000 permits a month across residential and commercial, new construction and trades.

### Read this before you buy: what Dallas actually publishes

The City of Dallas has **stopped publishing job value and contractor on current permits**. Measured on
2026-11-16:

| Field | November 2026 (2,855 permits) | Whole dataset (396,736 permits, back to 2018) |
|---|---|---|
| `work_description` | 2,824 (99%) | — |
| `zip` | 2,825 (99%) | 234,827 (59%) |
| `area_sqft` | 1,008 (35%) | — |
| `valuation` | **3 (0.1%)** | 172,567 (43%) |
| `contractor` | **4 (0.1%)** | 278,272 (70%) |

So on current data you get the permit register: what was issued, where, what kind of work, and often the
area. Value and contractor are present only for older records. This Actor returns those fields and never
invents them; the value filter is therefore only useful on historical backfills.

### Quick start

Click **Start** and leave the form alone: the default `backfill` mode with `lookback_days: 30` returns
the last month of permits and saves your position. Schedule it with mode `new` to get only permits issued
since the previous run.

| Mode | What it does | Charged |
|---|---|---|
| `backfill` | Returns permits issued in the last `lookback_days` (1–365) days and saves the watermark. Start here. | One event per permit you have never been charged for |
| `new` | Returns permits not reported to you by an earlier run, re-scanning one month back for late-published permits. Needs saved state: a first run with no `backfill` behind it returns an empty dataset and charges nothing. | One event per permit new to you |

Both modes are safe to repeat. A permit you have already been charged for is never charged again — not
under another `state_key`, not with `include_already_reported` on, and not after a crashed run.

### What you get

| Field | Meaning |
|---|---|
| `permit_number` | The city's permit number, e.g. `COM-NEW-26-000153`. Unique across the dataset (396,736 rows, 396,736 distinct numbers). |
| `issue_date` | Issue date as `YYYY-MM-DD`. Dallas publishes it as text `MM/DD/YY`; this Actor converts it. |
| `permit_type` | The city's type, e.g. `Residential New Construction Permit`, `Commercial Alteration Addition Permit`, `Commercial Electrical Permit`. |
| `permit_class` | `Residential` or `Commercial`, from the type prefix. |
| `construction_class` | Normalised: `new_construction`, `addition`, `alteration`, `demolition`, `trade`, `other`. |
| `is_new_construction` | `true` for new-construction permits. |
| `work_description` | The scope of work as filed. |
| `address`, `zip` | Street address as filed (often includes `Dallas, TX`) and 5-digit ZIP. |
| `area_sqft` | Job area in square feet, when published. |
| `valuation` | Job value, when published. Mostly historical — see the table above. |
| `contractor` | Contractor name, when published. Mostly historical. |
| `land_use`, `mapsco` | Legacy columns, populated for older records. |
| `first_seen_at` | When this Actor first returned the permit to you. |

### Input

| Field | Notes |
|---|---|
| `mode` | `backfill` (default) or `new`. |
| `lookback_days` | Backfill window, 1–365. Default 30. |
| `include_already_reported` | Backfill only. Re-emits permits you already have, free. Default off. |
| `permit_types` | Exact values, e.g. `Residential New Construction Permit`. Empty = all. |
| `permit_classes` | `Residential` and/or `Commercial` (prefix match on the type). Empty = both. |
| `min_valuation`, `max_valuation` | Filter on the published job value. **On current data almost nothing has a value**, so setting either excludes nearly every permit. Useful only for historical backfills. |
| `zip_codes` | 5-digit ZIPs. Empty = all. |
| `keywords` | Substring match (case-insensitive) on the work description: `solar`, `ADU`, `pool`, `restaurant`. |
| `max_results` | Cap on permits **charged** in one run (default 1000). Free re-reports do not count. |
| `state_key` | Name of the saved watermark. Use one per scheduled filter set. |

### Billing

Pay per event: **$5.00 per 1,000 permits returned**, billed once per permit the first time it is written
to your dataset. A permit you have already been billed for is free forever, including when it is returned
again. A run that finds nothing new costs nothing, and filters, lookback and mode inputs are free.

### Data source

City of Dallas Open Data Portal, dataset `e7gq-4sah` — *Building Permits*
(`https://www.dallasopendata.com/resource/e7gq-4sah.json`). Published by the City of Dallas. The Actor
reads only the columns it returns, pages 1,000 rows at a time, and never edits the source.

### Freshness and volume — measured, not claimed

Measured on 2026-11-16:

- **8,336 permits** in the 30 days from mid-October (5,481 in October, 2,855 in November to date), scanned
  in **8.3 s**.
- Monthly volume 2026: 5,874 (September), 5,481 (October). The dataset holds 396,736 permits back to 2018
  and was last updated on 2026-11-16, so it is a live daily feed.
- Dallas publishes `issued_date` as **text** in `MM/DD/YY` form, zero-padded. A date range cannot be
  queried directly, so the Actor walks the window month by month and pages on `permit_number` inside each
  month. That is also why `new` re-scans the previous month: a permit published late is caught then.
- `mapsco` is empty on current rows; it is kept for older records.

### Caveats

- **Value and contractor are mostly historical** (see the table). Do not build a lead list that depends on
  them for recent permits.
- `address` is the city's filed street address and frequently includes `, Dallas, TX`; it is not a
  normalised postal address.
- The source covers the City of Dallas only. Neighbouring cities (Fort Worth, Plano, Irving, Arlington)
  publish their own data.
- `permit_number` is the identity used for billing. Dallas numbers embed a legacy permit system id, so a
  resubmitted permit can appear under a new number; it is then billed as a new permit.

# Actor input Schema

## `mode` (type: `string`):

'backfill' returns permits issued in the last N days and saves the state; it is the default, so a first run returns real results. 'new' returns only permits not reported by an earlier run and needs saved state - it exits with an empty dataset if you have never run 'backfill'.

## `lookback_days` (type: `integer`):

Backfill only. Return permits issued in the last this many days (1 to 365, the same span the Actor remembers reported permits for). Dallas publishes on business days, so the newest day or two can be missing.

## `include_already_reported` (type: `boolean`):

Backfill only. Controls whether permits an earlier run already reported appear in the dataset again. Off (the default): they are left out. On: they are returned again. It never changes what you are charged: a permit is billed once, the first time it is reported, and re-reported permits are free. Permits are remembered for 365 days of issue dates, which covers the longest lookback.

## `permit_types` (type: `array`):

Exact dataset values, e.g. 'Residential New Construction Permit', 'Commercial Alteration Addition Permit', 'Commercial Electrical Permit', 'Residential Demolition Permit'. Empty = all. Use permit_classes for a broad residential/commercial cut.

## `permit_classes` (type: `array`):

'Residential' and/or 'Commercial'. Dallas puts the class at the start of the permit type, so this is a prefix match. Empty = both.

## `min_valuation` (type: `integer`):

Skip permits whose stated job value is below this. WARNING: the City of Dallas has stopped publishing job value on current permits (3 of 2,855 in November 2026), so setting this excludes nearly every recent permit. It is only useful on historical backfills. Permits with no value are excluded whenever this or the maximum is set.

## `max_valuation` (type: `integer`):

Skip permits whose stated job value is above this. Same warning as the minimum: almost no current permit carries a value. Permits with no value are excluded whenever this or the minimum is set.

## `zip_codes` (type: `array`):

5-digit ZIP codes, e.g. 75217. Empty = all.

## `keywords` (type: `array`):

Return a permit if its work description contains ANY of these text fragments (case-insensitive), e.g. solar, ADU, pool, restaurant. This is a substring match, so 'ADU' also matches longer words that contain it.

## `max_results` (type: `integer`):

Safety cap on charged permits (never reported before) per run. Permits returned again for free do not count. Default 1000. Oldest month first. The rest are picked up on the next 'new' run.

## `state_key` (type: `string`):

Name of the saved watermark. Use a different name for each filter set you schedule, because 'already reported' is tracked per name, not per filter set.

## Actor input object example

```json
{
  "mode": "backfill",
  "lookback_days": 14,
  "include_already_reported": true,
  "max_results": 1000,
  "state_key": "default"
}
```

# Actor output Schema

## `results` (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 = {
    "mode": "backfill",
    "lookback_days": 14,
    "include_already_reported": true,
    "max_results": 1000,
    "state_key": "default"
};

// Run the Actor and wait for it to finish
const run = await client.actor("themartygriffin/dallas-building-permits-feed").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 = {
    "mode": "backfill",
    "lookback_days": 14,
    "include_already_reported": True,
    "max_results": 1000,
    "state_key": "default",
}

# Run the Actor and wait for it to finish
run = client.actor("themartygriffin/dallas-building-permits-feed").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 '{
  "mode": "backfill",
  "lookback_days": 14,
  "include_already_reported": true,
  "max_results": 1000,
  "state_key": "default"
}' |
apify call themartygriffin/dallas-building-permits-feed --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,themartygriffin/dallas-building-permits-feed"
        }
    }
}
```

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/NgqJY6KG0EBviaIZ7/builds/ORQ8GuQ9DlNwW9BZ2/openapi.json
