PlaybooksReal estate
Contractor Licence Watch
Contractor businesses whose licence, bond or insurance expires in the next weeks, from official state and city registers.
- Id
contractor-license-watch- Version
- 1.0.0
- Category
- Real estate
- Status
- Live
- Saved, it runs
- daily, weekly, monthly
- Unit cap
- 20 by default, 1 to 200
Reads an official contractor-licence register (Washington, Texas, Oregon, Chicago, Buffalo or New York's mold and elevator registers) for the businesses whose licence runs out in the coming days, with the trade, the licence status and, where the register publishes them, the bond and insurance expiry dates. A saved playbook delivers each licence and expiry once, so each week brings only the newly due: a list for insurance and bonding agents, licence renewal services, and suppliers checking who is still licensed.
Use when someone wants contractor businesses whose licence, bond or insurance is about to expire, from a US state or city register.
Run it with POST /v1/formulas/contractor-license-watch/runs. How runs work is in Running a playbook; what a run costs is below.
Parameters
The fields of params, the Basics first. Only the required ones must be given; every other has a default. A field that is not listed is refused. The OpenAPI document has them as the type ContractorLicenseWatchParams.
| Parameter | Type | Required or default | What it is |
|---|---|---|---|
registerBasics | string | required | Register. Washington L&I, Texas TDLR, Oregon CCB (with bond and insurance dates), Chicago home repair, Buffalo, or New York's mold and elevator contractors.One of washington, texas, oregon, chicago, buffalo, new_york_mold, new_york_elevator. |
expiring_within_daysBasics | integer | 30 | Expiring within (days). Licences that run out between today and this many days from now.at least 1, at most 180. |
tradesBasics | list of strings | [] | Trades. Words in the licence's type or trade, such as electrical, plumbing or roofing. Each is one search. Empty reads every trade.up to 8, each up to 60 characters. |
active_onlyFilters | boolean | true | Only licences in good standing. Leave out licences the register shows as suspended, revoked, cancelled or expired. |
licences_to_readFilters | integer | 200 | Licences read per search. The register is read up to this many licences for each trade word.at least 10, at most 200. |
resurface_after_daysOutput | integer | 300 | Show a licence again after (days). For a saved playbook, how long before the same licence and expiry date may come back.at least 1, at most 365. |
max_resultsOutput | integer | 500 | Most rows. The run stops at this many licences, soonest expiry first.at least 1, at most 2000. |
Presets
Ready-made answers to start from: give them as params, with any of your own beside them.
Oregon, with bond and insurance dates oregon-bond-and-insurance
{
"register": "oregon",
"expiring_within_days": 30
}Washington electrical contractors washington-electrical
{
"register": "washington",
"trades": [
"electric"
],
"expiring_within_days": 45
}Texas air-conditioning contractors texas-hvac
{
"register": "texas",
"trades": [
"A/C"
],
"expiring_within_days": 60
}Columns
The columns of each row’s data, in order; rows also carry a score from 0 to 100, and come best first. A value that is not known is null.
| Column | Label | Type | Shown by default |
|---|---|---|---|
business_name | Business | string | yes |
licence_number | Licence | string | yes |
licence_type | Licence type | string | yes |
trade | Trade | string | no |
status | Status | string | yes |
expires | Expires | date | yes |
days_left | Days left | integer | yes |
bond_expires | Bond expires | date | yes |
insurance_expires | Insurance expires | date | yes |
issued | First issued | date | no |
city | City | string | yes |
region | State | string | yes |
postal_code | ZIP | string | no |
register | Register | string | yes |
record_url | Register data | url | no |
score | Score | number | yes |
Example request
# Start the run and wait up to 60 seconds for it to finish
curl -X POST "https://api.enrichednow.com/v1/formulas/contractor-license-watch/runs?wait=60" \
-H "Authorization: Bearer $ENRICHEDNOW_API_KEY" \
-H "Content-Type: application/json" \
-d '{"params":{"register":"oregon","expiring_within_days":30,"trades":[],"active_only":true,"licences_to_read":200,"resurface_after_days":300,"max_results":500},"unit_cap":20}'
# Follow it until it ends, then read its rows, with the id the first call answered
curl "https://api.enrichednow.com/v1/formula-runs/$RUN_ID?wait=60" \
-H "Authorization: Bearer $ENRICHEDNOW_API_KEY"
curl "https://api.enrichednow.com/v1/formula-runs/$RUN_ID/rows?limit=100" \
-H "Authorization: Bearer $ENRICHEDNOW_API_KEY"from enrichednow import EnrichedNow
client = EnrichedNow() # reads ENRICHEDNOW_API_KEY
# Start the run, wait for it to end, and get its rows
params = {
"register": "oregon",
"expiring_within_days": 30,
"trades": [],
"active_only": True,
"licences_to_read": 200,
"resurface_after_days": 300,
"max_results": 500,
}
result = client.run_formula("contractor-license-watch", params, unit_cap=20)
print(result.run.id, result.run.status, result.run.rows_total, result.run.units_spent)
# Read its rows, best first: pages are fetched as you go
for row in result:
print(row.data)Install it with pip install enrichednow, then save as run.py and run python3 run.py
import EnrichedNow from "enrichednow";
const client = new EnrichedNow(); // reads ENRICHEDNOW_API_KEY
// Start the run, wait for it to end, and get its rows
const params = {
register: "oregon",
expiring_within_days: 30,
trades: [],
active_only: true,
licences_to_read: 200,
resurface_after_days: 300,
max_results: 500,
};
const { run, rows } = await client.runFormula("contractor-license-watch", params, { unitCap: 20 });
console.log(run.id, run.status, run.rows_total, run.units_spent);
// Read its rows, best first: pages are fetched as you go
for await (const row of rows) console.log(row.data);Install it with npm install enrichednow, then save as run.mjs and run node run.mjs
package main
import (
"context"
"fmt"
"log"
"time"
enrichednow "github.com/enrichednow/enrichednow-go"
)
func main() {
client, err := enrichednow.NewClient() // reads ENRICHEDNOW_API_KEY
if err != nil {
log.Fatal(err)
}
ctx, cancel := context.WithTimeout(context.Background(), 30*time.Minute)
defer cancel()
// Start the run, wait for it to end, and get its rows
params := map[string]any{"register": "oregon", "expiring_within_days": 30, "trades": []any{}, "active_only": true, "licences_to_read": 200, "resurface_after_days": 300, "max_results": 500}
run, rows, err := client.RunFormula(ctx, "contractor-license-watch", params, &enrichednow.RunFormulaParams{UnitCap: 20})
if err != nil {
log.Fatal(err)
}
fmt.Println(run.ID, run.Status, run.RowsTotal, run.UnitsSpent)
// Read its rows, best first: pages are fetched as you go
for rows.Next() {
fmt.Println(string(rows.Current().Data))
}
if err := rows.Err(); err != nil {
log.Fatal(err)
}
}Install it with go get github.com/enrichednow/enrichednow-go@latest, then save as run.go and run go run run.go
import com.enrichednow.EnrichedNowClient;
import com.enrichednow.FormulaResult;
import com.enrichednow.FormulaRunOptions;
import com.enrichednow.models.FormulaRow;
import java.util.List;
import java.util.Map;
public class Run {
public static void main(String[] args) {
EnrichedNowClient client = EnrichedNowClient.fromEnv(); // reads ENRICHEDNOW_API_KEY
// Start the run, wait for it to end, and get its rows
FormulaResult result = client.runFormula("contractor-license-watch", Map.of("register", "oregon", "expiring_within_days", 30, "trades", List.of(), "active_only", true, "licences_to_read", 200, "resurface_after_days", 300, "max_results", 500), FormulaRunOptions.builder().unitCap(20).build());
System.out.println(result.run().id() + " " + result.run().status() + " " + result.run().rowsTotal() + " " + result.run().unitsSpent());
// Read its rows, best first: pages are fetched as you go
for (FormulaRow row : result.rows()) {
System.out.println(row.data());
}
}
}Add com.enrichednow:enrichednow-java:0.4.0 to your Maven or Gradle build, then save as Run.java
enrichednow formulas run contractor-license-watch --params-json '{"register":"oregon","expiring_within_days":30,"trades":[],"active_only":true,"licences_to_read":200,"resurface_after_days":300,"max_results":500}' --unit-cap 20Install it with curl -fsSL https://raw.githubusercontent.com/enrichednow/enrichednow-cli/main/install.sh | sh
{
"name": "run_formula",
"arguments": {
"formula_id": "contractor-license-watch",
"params": {
"register": "oregon",
"expiring_within_days": 30,
"trades": [],
"active_only": true,
"licences_to_read": 200,
"resurface_after_days": 300,
"max_results": 500
}
}
}It starts a full run with the answers the sample rows below were made with and the default unit cap, waits for it, and reads its rows a page at a time. The key is read from an environment variable. The MCP tab is the same run asked of an agent connected to the MCP server, which runs a preview first.
Example response
The data of the first 3 rows a real run returned with these answers on 2026-11-24: it ended ok with 333 rows, after 2 scraper calls charged 2 units. Text over 160 characters is cut here and ends with … [truncated]; the API returns every value whole.
[
{
"business_name": "ALL POINTS HOME INSPECTION LLC",
"licence_number": "233359",
"licence_type": "Residential General Contractor",
"trade": "Residential General Contractor",
"status": null,
"expires": "2026-11-24",
"days_left": 0,
"bond_expires": "2026-11-24",
"insurance_expires": "2027-10-19",
"issued": "2020-11-24",
"city": "ALBANY",
"region": "OR",
"postal_code": "97322",
"register": "Oregon CCB",
"record_url": "https://data.oregon.gov/d/g77e-6bhs",
"score": 80
},
{
"business_name": "BTW FLOORING LLC",
"licence_number": "233376",
"licence_type": "Commercial General Contractor Level 2",
"trade": "Commercial General Contractor Level 2",
"status": null,
"expires": "2026-11-24",
"days_left": 0,
"bond_expires": "2026-11-24",
"insurance_expires": "2027-10-06",
"issued": "2020-11-24",
"city": "MONROE",
"region": "OR",
"postal_code": "97302",
"register": "Oregon CCB",
"record_url": "https://data.oregon.gov/d/g77e-6bhs",
"score": 80
},
{
"business_name": "BTW FLOORING LLC",
"licence_number": "233376",
"licence_type": "Residential General Contractor",
"trade": "Residential General Contractor",
"status": null,
"expires": "2026-11-24",
"days_left": 0,
"bond_expires": "2026-11-24",
"insurance_expires": "2027-10-06",
"issued": "2020-11-24",
"city": "MONROE",
"region": "OR",
"postal_code": "97302",
"register": "Oregon CCB",
"record_url": "https://data.oregon.gov/d/g77e-6bhs",
"score": 80
}
]Each row also has its id, its score, when it was first seen and its evidence: where each value came from. The run and its rows are described in Running a playbook.
Pricing
A run costs the units of the work it does, and nothing on top: each scraper call it makes is charged at that scraper's rate, when the call ends ok or partial. It never spends past its unit cap: 20 units unless you give another (at least 1, at most 200).
With the answers above, a run is estimated at about 2 units for about 333 rows, and at most 2: 2 searches across 1 source, about 333 rows. An estimate for no history; POST /v1/formulas/contractor-license-watch/estimate gives yours, free.
A preview, mode: preview, is the first 10 rows, charged at what they cost: about 2 units with the answers above. POST /v1/formulas/contractor-license-watch/estimate with mode: preview gives yours, free.
How a playbook is charged has the rule for every playbook.