# OSHA Injury Data Scraper - US Employer & Workplace-Safety Leads (`scrapesage/osha-injury-data-scraper`) Actor

Scrape OSHA ITA Form 300A injury data: every US establishment that filed an annual injury summary — name, EIN, address, NAICS, employee count, injury counts, TRIR/DART rates & lead score. Filter by state, NAICS, size & injury rate. Firmographic B2B leads + monitoring, no browser.

- **URL**: https://apify.com/scrapesage/osha-injury-data-scraper.md
- **Developed by:** [Scrape Sage](https://apify.com/scrapesage) (community)
- **Categories:** Lead generation, Automation, Developer tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$5.00 / 1,000 establishment injury record scrapeds

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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js/docs.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python/docs.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## OSHA Injury Data Scraper — US Employer & Workplace-Safety Leads

Turn the official **OSHA Injury Tracking Application (ITA) Form 300A** dataset into a clean, structured **US employer database with verified employee counts and workplace-injury intelligence**. Every record is one establishment that filed an annual injury & illness summary — with **company name, EIN, full address, NAICS/industry, annual-average employees, hours worked, the full injury & illness breakdown, computed TRIR/DART rates, and a 0–100 lead score**.

No login, no API key, no browser — fast streaming extraction straight from OSHA's open-data files.

### Why this OSHA scraper?

Other "OSHA" scrapers only return **enforcement inspections** (violations & penalties). This actor ships the dataset none of them do — the **annual Form 300A injury summaries that employers self-report to OSHA** — which is both a far larger universe and a genuine firmographic goldmine:

| Data | Inspection scrapers | This actor |
|---|---|---|
| Source | OSHA enforcement inspections | OSHA **ITA Form 300A** self-reported summaries |
| Coverage | Inspected sites only | **Every establishment that files** (~350k+/yr) |
| Annual-average **employee count** | ❌ | ✅ rare public firmographic |
| Total hours worked | ❌ | ✅ |
| **TRIR / DART injury rates** (computed) | ❌ | ✅ |
| Injury vs illness breakdown (skin, respiratory, hearing…) | ❌ | ✅ |
| Employer **EIN** | ❌ | ✅ |
| NAICS code + industry + sector | partial | ✅ |
| Fatality / lost-workday flags | ❌ | ✅ |
| Lead score (0–100) | ❌ | ✅ |
| Filter by state, NAICS, size & injury rate | partial | ✅ |
| Only-new monitoring | ❌ | ✅ |

### Who buys these leads?

- **Workplace-safety & PPE vendors** — target high-TRIR establishments in high-hazard NAICS codes that clearly need safety solutions.
- **Workers' compensation insurance brokers & carriers** — underwrite and prospect by industry, employee count and injury rate.
- **EHS / safety-management software** — sell compliance, recordkeeping and incident-tracking tools to employers that file 300As.
- **Occupational health clinics & drug-testing providers** — find large local employers by NAICS and headcount.
- **Industrial supply, training & safety consultants** — reach the exact sites with elevated injury burden.
- **Sales & RevOps teams** — use it as a clean **employer database** to size and segment accounts by verified employee count, industry and location.

### Use cases

- **Lead generation** — build targeted lists of employers by state, industry (NAICS), company size and injury rate, scored for outreach.
- **Account sizing & ICP targeting** — one of the only public datasets with real **annual-average employee counts** per establishment.
- **Risk & underwriting intelligence** — rank prospects by TRIR, DART rate, fatalities and lost workdays.
- **Market research** — analyze injury trends by industry, geography and company size across years 2016–present.
- **Monitoring** — schedule recurring runs and capture only newly filed establishments as a fresh-leads feed.

### How to use

1. [Sign up for Apify](https://console.apify.com/sign-up) — the free plan is enough to try this actor.
2. Open the **OSHA Injury Data Scraper**, choose filters (state, NAICS, employee range, injury rate…), and click **Start**.
3. Watch establishment records stream into the dataset table.
4. **Export** as JSON, CSV, Excel, or XML — or pull results via the [Apify API](https://docs.apify.com/api/v2).

### Input

```json
{
    "states": ["TX"],
    "naicsSectors": ["23"],
    "minEmployees": 50,
    "minTrir": 4,
    "sortBy": "leadScore",
    "maxResults": 500
}
````

- **states** — 2-letter codes (`TX`, `CA`, `OH`). Empty = whole national file.
- **naicsCodes** — NAICS prefixes (`23` construction, `2382` building-equipment contractors, `311` food manufacturing).
- **naicsSectors** — 2-digit sector shortcuts (`23`, `31`/`32`/`33`, `48`/`49`, `62`, `21`, `22`).
- **cities / zipCodes / industryQuery / companyNameQuery** — extra targeting filters.
- **establishmentTypes** — `private`, `stateGovernment`, `localGovernment`.
- **minEmployees / maxEmployees** — target larger (or smaller) employers.
- **minRecordableCases / minTrir / hasInjuriesOnly / hasFatalitiesOnly / hasLostTimeOnly** — surface high-injury, high-intent sites.
- **withEinOnly / minLeadScore** — quality gates.
- **yearFilingFor** — reporting year (default: latest available; OSHA publishes 2016–present).
- **sortBy** — `leadScore`, `employeesHigh`, `trirHigh`, `recordableCasesHigh`, `lostWorkdaysHigh`, `fatalities`, `name`, `none`.
- **maxResults / deduplicateResults** — output controls.
- **monitorMode / monitorKey** — only-new-establishments feed (see below).

### Output

One record per establishment:

```json
{
    "recordType": "establishment",
    "establishmentName": "Acme Roofing & Sheet Metal",
    "companyName": "Acme Roofing LLC",
    "ein": "742318890",
    "einFormatted": "74-2318890",
    "street": "1200 Industrial Blvd",
    "city": "Houston",
    "state": "TX",
    "zipCode": "77032",
    "fullAddress": "1200 Industrial Blvd, Houston, TX, 77032",
    "naicsCode": "238160",
    "naicsSector": "Construction",
    "industryDescription": "Roofing contractors",
    "establishmentType": "1",
    "establishmentTypeLabel": "Private",
    "annualAverageEmployees": 240,
    "employeeSizeTier": "Medium (50-249)",
    "totalHoursWorked": 498000,
    "yearFilingFor": 2025,
    "totalDeaths": 0,
    "totalDafwCases": 9,
    "totalDjtrCases": 4,
    "totalOtherCases": 6,
    "totalRecordableCases": 19,
    "dartCases": 13,
    "totalLostWorkdays": 187,
    "totalInjuries": 17,
    "totalIllnesses": 2,
    "trir": 7.63,
    "dartRate": 5.22,
    "hasInjuries": true,
    "hasFatalities": false,
    "hasLostTimeInjuries": true,
    "leadScore": 71,
    "leadSignals": ["High injury rate (TRIR 7.63)", "Many lost-time cases"],
    "sourceUrl": "https://www.osha.gov/Establishment-Specific-Injury-and-Illness-Data",
    "sourceFields": { "id": "...", "establishment_id": "...", "...": "every raw OSHA column" },
    "scrapedAt": "2026-06-20T12:00:00.000Z"
}
```

Every raw OSHA column is preserved under `sourceFields`, so no source data is ever lost.

### Automate & schedule

Run this actor on autopilot and pull results into your own stack:

- **[Apify API](https://docs.apify.com/api/v2)** — start runs, fetch datasets, manage schedules over REST.
- **[apify-client for JavaScript](https://docs.apify.com/api/client/js/)** and **[apify-client for Python](https://docs.apify.com/api/client/python/)** — official SDKs.
- **[Schedules](https://docs.apify.com/platform/schedules)** — run weekly/monthly with `monitorMode` to capture newly filed establishments as a fresh-leads pipeline.
- **[Webhooks](https://docs.apify.com/platform/integrations/webhooks)** — trigger downstream actions (CRM import, Slack alert) the moment a run finishes.

```js
import { ApifyClient } from 'apify-client';

const client = new ApifyClient({ token: 'MY_APIFY_TOKEN' });

const run = await client.actor('scrapesage/osha-injury-data-scraper').call({
    states: ['CA'],
    naicsSectors: ['31', '32', '33'],
    minEmployees: 100,
    sortBy: 'trirHigh',
    maxResults: 1000,
});

const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(`Got ${items.length} establishment leads`);
```

### Integrate with any app

Connect the dataset to 5,000+ apps — no code required:

- **[Make](https://docs.apify.com/platform/integrations/make)** — multi-step automation scenarios.
- **[Zapier](https://docs.apify.com/platform/integrations/zapier)** — push new leads straight into your CRM.
- **[Slack](https://docs.apify.com/platform/integrations/slack)** — get notified when a monitored search finds new establishments.
- **[Google Drive / Sheets](https://docs.apify.com/platform/integrations/drive)** — auto-export every run to a spreadsheet.
- **[Airbyte](https://docs.apify.com/platform/integrations/airbyte)** — pipe results into your data warehouse.
- **[GitHub](https://docs.apify.com/platform/integrations/github)** — trigger runs from commits or releases.

### Use with AI assistants (MCP)

The output is clean, LLM-ready JSON. Call this actor from Claude, ChatGPT, or any agent framework through the **[Apify MCP server](https://docs.apify.com/platform/integrations/mcp)** — ask your assistant to "find Texas construction employers with 50+ staff and a TRIR above 4" and let it run this scraper for you.

### Agent-ready: autonomous payments (x402 & Skyfire)

This actor is **agent-ready** — AI agents can discover it, run it, and **pay for it autonomously**, with no Apify account and no human in the loop. It uses [pay-per-event](https://docs.apify.com/platform/actors/publishing/monetize/pay-per-event) pricing and [limited permissions](https://docs.apify.com/platform/actors/development/permissions), so it qualifies for Apify's agentic-payment standards:

- **[x402](https://docs.apify.com/platform/integrations/x402)** — an open, HTTP-native payment protocol. Agents pay per run in USDC on the Base network directly through the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp) — no account, no API key.
- **[Skyfire](https://docs.apify.com/platform/integrations/skyfire)** — agent-to-service payments for fully autonomous AI-agent workflows.

Building an AI agent, MCP tool, or autonomous data pipeline? This scraper is ready to plug in and pay as it goes.

### More scrapers from scrapesage

Build a complete **US-B2B & compliance lead-gen stack** from official public data:

- **[EPA ECHO Scraper](https://apify.com/scrapesage/epa-echo-scraper)** — facility environmental-compliance & violation leads.
- **[MSHA Mine Operations Scraper](https://apify.com/scrapesage/msha-mine-operations-scraper)** — mine, quarry & aggregate operator leads.
- **[FMCSA Trucking Scraper](https://apify.com/scrapesage/fmcsa-trucking-scraper)** — motor carrier & trucking-company leads.
- **[USDA FSIS Establishment Scraper](https://apify.com/scrapesage/fsis-establishment-scraper)** — meat, poultry & egg plant leads.
- **[SBA Loan Leads Scraper](https://apify.com/scrapesage/sba-loan-leads-scraper)** — financed small-business leads.
- **[PPP Loan Data Scraper](https://apify.com/scrapesage/ppp-loan-data-scraper)** — PPP borrower firmographics.
- **[Form 5500 ERISA Scraper](https://apify.com/scrapesage/form-5500-erisa-scraper)** — 401(k) & benefit-plan sponsor leads.
- **[Visa Sponsor Leads Scraper](https://apify.com/scrapesage/visa-sponsor-leads-scraper)** — PERM, H-2A & H-2B sponsoring employers.
- **[US Business Formation Scraper](https://apify.com/scrapesage/us-business-formation-scraper)** — newly registered companies.

### Tips

- **Memory**: the latest year is a single ~85 MB CSV (~350k rows) and runs comfortably at the default. Older years are ZIP files — give the run **4 GB** for the fastest scan.
- **High-intent lists**: combine `minTrir` (4–8) with a high-hazard `naicsSectors` value (`23` construction, `31`–`33` manufacturing, `48`/`49` transportation) to find sites that most need safety/insurance solutions.
- **Big employers**: set `minEmployees` and `sortBy: "employeesHigh"` to build an account list of the largest local employers by industry.
- **Cost control**: filters are applied before the cap, so a tight filter + small `maxResults` keeps runs fast and cheap.

### FAQ

**What is OSHA ITA Form 300A data?** Under OSHA's recordkeeping rule, establishments in covered industries electronically submit their annual "Summary of Work-Related Injuries and Illnesses" (Form 300A) each year. OSHA publishes the de-identified establishment summaries as open data — this actor structures and enriches them.

**How is this different from OSHA inspection scrapers?** Inspection scrapers return enforcement events (citations & penalties) for the minority of sites OSHA inspected. This actor returns the **self-reported annual injury summaries from every establishment that files** — a much larger universe, plus employee counts, hours, EIN and computed injury rates.

**Does it include contact emails or phone numbers?** No — OSHA's 300A dataset is firmographic (name, address, industry, size, injuries) and does not contain emails or phones. Pair it with a contact-enrichment step if you need direct contacts. Fields are `null` only when the source omits them.

**Which years are available?** OSHA publishes data from 2016 to the present. Leave `yearFilingFor` empty for the latest year, or set a specific year.

**What are TRIR and DART rate?** TRIR (Total Recordable Incident Rate) = recordable cases × 200,000 ÷ hours worked. DART rate counts only days-away/restricted/transfer cases. 200,000 = 100 full-time workers × 2,000 hours/year — so both are "per 100 full-time workers."

**Can I export to Google Sheets, CSV, or Excel?** Yes — one click in the dataset view, or automatically on every run via the [Google Drive integration](https://docs.apify.com/platform/integrations/drive).

**How do I get only new establishments?** Turn on `monitorMode`, set a `monitorKey`, and schedule the run — the actor remembers what it has already emitted and outputs only newly filed establishments.

**Is this legal?** This actor collects publicly available US-government open data. You are responsible for using the data in compliance with applicable laws and OSHA's terms.

### Need help?

Open an issue on the actor's **Issues** tab, or visit the [Apify help center](https://help.apify.com/). Feature requests are welcome — this actor is actively maintained.

# Actor input Schema

## `states` (type: `array`):

Filter to one or more US states by 2-letter code (e.g. `TX`, `CA`, `OH`). Leave empty to scan the whole national file.

## `cities` (type: `array`):

Filter by city name (case-insensitive, substring match).

## `zipCodes` (type: `array`):

Filter by ZIP code. A 5-digit value matches exactly; a shorter prefix (e.g. `770`) matches a region.

## `naicsCodes` (type: `array`):

Filter by NAICS industry code. A prefix matches a whole branch — e.g. `23` = all construction, `2382` = building-equipment contractors, `311` = food manufacturing.

## `naicsSectors` (type: `array`):

Quick filter by top-level NAICS sector. Examples: `23` Construction, `31`/`32`/`33` Manufacturing, `48`/`49` Transportation & Warehousing, `62` Health Care, `21` Mining/Oil & Gas, `22` Utilities.

## `industryQuery` (type: `string`):

Free-text filter on the industry description (e.g. `roofing`, `nursing`, `warehousing`, `meat`).

## `companyNameQuery` (type: `string`):

Filter to establishments whose establishment name or company name contains this text (case-insensitive).

## `establishmentTypes` (type: `array`):

Keep only private, state-government or local-government establishments.

## `minEmployees` (type: `integer`):

Keep only establishments with at least this many annual-average employees. Great for targeting larger employers with bigger budgets.

## `maxEmployees` (type: `integer`):

Keep only establishments with at most this many annual-average employees.

## `minRecordableCases` (type: `integer`):

Keep only establishments reporting at least this many total OSHA-recordable cases for the year.

## `minTrir` (type: `integer`):

Keep only establishments with a Total Recordable Incident Rate at or above this value (cases per 100 full-time workers). The US private-industry average is ~2.7 — set 4–8 to find high-injury sites.

## `hasInjuriesOnly` (type: `boolean`):

Keep only establishments that reported at least one recordable injury or illness.

## `hasFatalitiesOnly` (type: `boolean`):

Keep only establishments that reported one or more work-related deaths.

## `hasLostTimeOnly` (type: `boolean`):

Keep only establishments with days-away or job-transfer/restriction (DART) cases.

## `withEinOnly` (type: `boolean`):

Keep only records that include the employer EIN (useful for B2B record matching).

## `minLeadScore` (type: `integer`):

Keep only establishments with a lead score (0–100) at or above this value.

## `yearFilingFor` (type: `integer`):

Which reporting year to scrape (the year the Form 300A summarizes). Leave empty for the latest year available. Years 2016–present are published by OSHA.

## `sortBy` (type: `string`):

Order of returned records (the cap is applied after sorting).

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

Maximum number of establishment records to return. The full national file holds roughly 350,000+ establishments per year.

## `deduplicateResults` (type: `boolean`):

Drop duplicate establishments (by OSHA establishment ID) within a run, keeping the first seen.

## `monitorMode` (type: `boolean`):

Remember establishments seen in previous runs (per Monitor key) and only output NEW ones. Ideal with Apify Schedules for a fresh-leads feed as more employers file each year. Works independently of the platform scheduler.

## `monitorKey` (type: `string`):

Names the saved monitor state, so different filter sets keep separate memories. Use a distinct key per saved search.

## `proxyConfiguration` (type: `object`):

Proxy settings. The OSHA open-data files are public and download fine without a proxy (the default). If a run is blocked, enable Apify Proxy — the actor automatically escalates to US residential when needed.

## Actor input object example

```json
{
  "states": [
    "TX"
  ],
  "hasInjuriesOnly": false,
  "hasFatalitiesOnly": false,
  "hasLostTimeOnly": false,
  "withEinOnly": false,
  "sortBy": "leadScore",
  "maxResults": 1000,
  "deduplicateResults": true,
  "monitorMode": false,
  "monitorKey": "default",
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `results` (type: `string`):

All scraped establishment records in the default dataset.

# 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 = {
    "states": [
        "TX"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapesage/osha-injury-data-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 = { "states": ["TX"] }

# Run the Actor and wait for it to finish
run = client.actor("scrapesage/osha-injury-data-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "states": [
    "TX"
  ]
}' |
apify call scrapesage/osha-injury-data-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=scrapesage/osha-injury-data-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "OSHA Injury Data Scraper - US Employer & Workplace-Safety Leads",
        "description": "Scrape OSHA ITA Form 300A injury data: every US establishment that filed an annual injury summary — name, EIN, address, NAICS, employee count, injury counts, TRIR/DART rates & lead score. Filter by state, NAICS, size & injury rate. Firmographic B2B leads + monitoring, no browser.",
        "version": "0.1",
        "x-build-id": "ZKeuuc5rRIgq7VS7I"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/scrapesage~osha-injury-data-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-scrapesage-osha-injury-data-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/scrapesage~osha-injury-data-scraper/runs": {
            "post": {
                "operationId": "runs-sync-scrapesage-osha-injury-data-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/scrapesage~osha-injury-data-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-scrapesage-osha-injury-data-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "properties": {
                    "states": {
                        "title": "States",
                        "type": "array",
                        "description": "Filter to one or more US states by 2-letter code (e.g. `TX`, `CA`, `OH`). Leave empty to scan the whole national file.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "cities": {
                        "title": "Cities",
                        "type": "array",
                        "description": "Filter by city name (case-insensitive, substring match).",
                        "items": {
                            "type": "string"
                        }
                    },
                    "zipCodes": {
                        "title": "ZIP codes",
                        "type": "array",
                        "description": "Filter by ZIP code. A 5-digit value matches exactly; a shorter prefix (e.g. `770`) matches a region.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "naicsCodes": {
                        "title": "NAICS codes / prefixes",
                        "type": "array",
                        "description": "Filter by NAICS industry code. A prefix matches a whole branch — e.g. `23` = all construction, `2382` = building-equipment contractors, `311` = food manufacturing.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "naicsSectors": {
                        "title": "NAICS sectors (2-digit)",
                        "type": "array",
                        "description": "Quick filter by top-level NAICS sector. Examples: `23` Construction, `31`/`32`/`33` Manufacturing, `48`/`49` Transportation & Warehousing, `62` Health Care, `21` Mining/Oil & Gas, `22` Utilities.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "industryQuery": {
                        "title": "Industry contains",
                        "type": "string",
                        "description": "Free-text filter on the industry description (e.g. `roofing`, `nursing`, `warehousing`, `meat`)."
                    },
                    "companyNameQuery": {
                        "title": "Establishment / company name contains",
                        "type": "string",
                        "description": "Filter to establishments whose establishment name or company name contains this text (case-insensitive)."
                    },
                    "establishmentTypes": {
                        "title": "Establishment type",
                        "type": "array",
                        "description": "Keep only private, state-government or local-government establishments.",
                        "items": {
                            "type": "string",
                            "enum": [
                                "private",
                                "stateGovernment",
                                "localGovernment"
                            ],
                            "enumTitles": [
                                "Private industry",
                                "State government",
                                "Local government"
                            ]
                        }
                    },
                    "minEmployees": {
                        "title": "Minimum employees",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Keep only establishments with at least this many annual-average employees. Great for targeting larger employers with bigger budgets."
                    },
                    "maxEmployees": {
                        "title": "Maximum employees",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Keep only establishments with at most this many annual-average employees."
                    },
                    "minRecordableCases": {
                        "title": "Minimum recordable cases",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Keep only establishments reporting at least this many total OSHA-recordable cases for the year."
                    },
                    "minTrir": {
                        "title": "Minimum TRIR",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Keep only establishments with a Total Recordable Incident Rate at or above this value (cases per 100 full-time workers). The US private-industry average is ~2.7 — set 4–8 to find high-injury sites."
                    },
                    "hasInjuriesOnly": {
                        "title": "Only establishments with recordable injuries",
                        "type": "boolean",
                        "description": "Keep only establishments that reported at least one recordable injury or illness.",
                        "default": false
                    },
                    "hasFatalitiesOnly": {
                        "title": "Only establishments with a fatality",
                        "type": "boolean",
                        "description": "Keep only establishments that reported one or more work-related deaths.",
                        "default": false
                    },
                    "hasLostTimeOnly": {
                        "title": "Only establishments with lost-time cases",
                        "type": "boolean",
                        "description": "Keep only establishments with days-away or job-transfer/restriction (DART) cases.",
                        "default": false
                    },
                    "withEinOnly": {
                        "title": "Only establishments with an EIN",
                        "type": "boolean",
                        "description": "Keep only records that include the employer EIN (useful for B2B record matching).",
                        "default": false
                    },
                    "minLeadScore": {
                        "title": "Minimum lead score",
                        "minimum": 0,
                        "maximum": 100,
                        "type": "integer",
                        "description": "Keep only establishments with a lead score (0–100) at or above this value."
                    },
                    "yearFilingFor": {
                        "title": "Filing year",
                        "type": "integer",
                        "description": "Which reporting year to scrape (the year the Form 300A summarizes). Leave empty for the latest year available. Years 2016–present are published by OSHA."
                    },
                    "sortBy": {
                        "title": "Sort by",
                        "enum": [
                            "leadScore",
                            "employeesHigh",
                            "trirHigh",
                            "recordableCasesHigh",
                            "lostWorkdaysHigh",
                            "fatalities",
                            "name",
                            "none"
                        ],
                        "type": "string",
                        "description": "Order of returned records (the cap is applied after sorting).",
                        "default": "leadScore"
                    },
                    "maxResults": {
                        "title": "Max results",
                        "minimum": 1,
                        "type": "integer",
                        "description": "Maximum number of establishment records to return. The full national file holds roughly 350,000+ establishments per year.",
                        "default": 1000
                    },
                    "deduplicateResults": {
                        "title": "Deduplicate",
                        "type": "boolean",
                        "description": "Drop duplicate establishments (by OSHA establishment ID) within a run, keeping the first seen.",
                        "default": true
                    },
                    "monitorMode": {
                        "title": "Monitor mode (only new establishments)",
                        "type": "boolean",
                        "description": "Remember establishments seen in previous runs (per Monitor key) and only output NEW ones. Ideal with Apify Schedules for a fresh-leads feed as more employers file each year. Works independently of the platform scheduler.",
                        "default": false
                    },
                    "monitorKey": {
                        "title": "Monitor key",
                        "type": "string",
                        "description": "Names the saved monitor state, so different filter sets keep separate memories. Use a distinct key per saved search.",
                        "default": "default"
                    },
                    "proxyConfiguration": {
                        "title": "Proxy configuration",
                        "type": "object",
                        "description": "Proxy settings. The OSHA open-data files are public and download fine without a proxy (the default). If a run is blocked, enable Apify Proxy — the actor automatically escalates to US residential when needed.",
                        "default": {
                            "useApifyProxy": false
                        }
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
