# US Machine Shop & Fabricator Lead Scraper (`forged_mussel/machine-shop-directory-scraper`) Actor

US machine-shop, CNC, precision machining & fabricator leads from ThomasNet and YellowPages. CRM-ready rows with company, phone, website, address, certifications, and source links. PPE $2.49/1k.

- **URL**: https://apify.com/forged\_mussel/machine-shop-directory-scraper.md
- **Developed by:** [Dan Ferden](https://apify.com/forged_mussel) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.49 / 1,000 results

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

## US Machine Shop & Fabricator Lead Scraper

Pull **public** US machine-shop and fabricator directory listings into flat, CRM-ready rows. Built for procurement shortlists, industrial outbound, and supplier discovery — not a generic Maps clone.

### What you get

Each dataset row is one supplier listing with stable fields:

- Company **name**, **primary phone**, **website** (when published)
- Structured **address** (street, city, state, ZIP)
- Category **headings**, **sourceUrl**, stable **supplierId**
- Optional fields when the source exposes them: company type, employee/sales bands, year founded, certifications

### Sources

| Source | Role |
|--------|------|
| **ThomasNet** | Primary industrial supplier directory (`source=auto` or `thomasnet`) |
| **YellowPages** | Reliable fallback / `source=yellowpages` — organic SERP cards |

`source=auto` tries ThomasNet first and falls back to YellowPages on block, captcha, or empty results. **ThomasNet often returns HTTP 403 / DataDome from datacenter IPs** — enable **Apify residential proxies** for ThomasNet or `auto` on cloud. YellowPages typically works from datacenter IPs.

### Shop-floor presets

- Machine shop pack
- CNC machining
- Sheet metal fabrication
- Welding / fab
- Precision grinding
- Injection molding
- Or custom free-text query

### Pricing

**Pay per event** · event name `supplier-scraped` · **$2.49 per 1,000** events (= $0.00249 per supplier row). Charged once per real dataset row. Dry-run / fixture rows are not charged.

### Honest limits

- Public directory pages only. Field completeness varies by listing.
- No login walls, cookie farms, LinkedIn private data, or email-waterfall enrichment.
- Directory HTML can change; re-test after major site updates.
- **Not affiliated with** ThomasNet, Thomas Publishing, or Yellow Pages.

### Disclaimer

Data is collected from publicly available directory pages. You are responsible for compliance with applicable laws and each source site’s terms of use. Provided as-is for informational / B2B research. Not legal advice.

### Who it's for

1. **Procurement shortlists** — build metro-scoped machine-shop / fab supplier lists for RFQs
2. **Industrial outbound** — seed CRM pipelines with public phone/website from directory cards
3. **Market mapping** — compare density of shops across geos (e.g. Chicago vs Dallas) for territory planning

### Feature highlights

1. ThomasNet primary with YellowPages auto-fallback (`source=auto`)
2. Shop-floor presets: machine shop, CNC, sheet metal, welding, grinding, molding
3. CRM-ready fields: name, phone, website, address, headings, sourceUrl, supplierId
4. Polite crawl (1–2s delays, concurrency 1) — no login / cookie farm
5. Dedupe by directory id and name+phone
6. Pagination until `maxResults` on YellowPages organic cards (ads/sponsored chrome skipped)
7. Pay-per-event billing: `supplier-scraped` @ $2.49 / 1,000 rows
8. Dry-run fixture mode for input validation without network

### Example input

```json
{
  "query": "CNC machining",
  "preset": "machine_shop",
  "source": "auto",
  "geo": "Chicago, IL",
  "area": "NA",
  "maxResults": 50,
  "companyType": "custom_manufacturer",
  "dryRun": false,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": ["RESIDENTIAL"]
  }
}
```

YellowPages-only smoke test (usually fine on datacenter IPs):

```json
{
  "preset": "machine_shop",
  "source": "yellowpages",
  "geo": "Dallas, TX",
  "maxResults": 20,
  "dryRun": false
}
```

### Search context

Search buyers looking for a **US machine shop scraper**, **CNC machining directory scraper**, or **fabricator lead scraper** need metro-scoped public supplier lists — not generic Maps dumps. This Actor targets industrial directory cards (ThomasNet primary, YellowPages fallback) so procurement and outbound teams can build **Houston**, **Dallas**, **Chicago**, and other US geo shortlists with CRM-ready name, phone, website, and address fields. Keywords that map to real Store queries: machine shop leads, sheet metal fabrication leads, welding fabricator directory, custom manufacturer leads, industrial supplier leads, YellowPages machine shop, ThomasNet suppliers scraper, B2B manufacturer leads, shop-floor supplier list, precision grinding / injection molding presets.

# Actor input Schema

## `query` (type: `string`):

Product/service or company name (e.g. "CNC machining", "sheet metal fabrication", "Siemens"). Ignored when preset supplies the query pack unless overrideQuery is true.

## `preset` (type: `string`):

Optional query pack for industrial buyers. 'custom' uses the query field only.

## `overrideQuery` (type: `boolean`):

If true, use query even when a preset is selected.

## `source` (type: `string`):

auto = try ThomasNet first, fall back to YellowPages on captcha/block or empty. thomasnet = ThomasNet only (needs residential proxies on Apify). yellowpages = YellowPages machine-shop search only (works from most datacenter IPs).

## `geo` (type: `string`):

City/state for YellowPages search (e.g. "Houston, TX"). If empty, derived from area or defaults to Houston, TX.

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

all = category/product search; name = company name search (ThomasNet).

## `area` (type: `string`):

ThomasNet-style area code. NA = all US/Canada. State codes (TX, OH, …) also seed YellowPages geo when geo is empty.

## `companyType` (type: `string`):

Prefer custom manufacturers / machine shops when available on the source.

## `certifications` (type: `array`):

Prefer suppliers with these certs when the source exposes filters; otherwise filter client-side from returned cert arrays.

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

Maximum supplier rows to return. Start small (20–50) to validate. 0 = uncapped (use with care — costs scale).

## `dryRun` (type: `boolean`):

If true, push one labeled fixture row and exit — no live scrape.

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

Apify proxy settings. Residential recommended for ThomasNet (DataDome). YellowPages often works without.

## Actor input object example

```json
{
  "query": "CNC machining",
  "preset": "machine_shop",
  "overrideQuery": false,
  "source": "yellowpages",
  "geo": "Dallas, TX",
  "mode": "all",
  "area": "NA",
  "companyType": "any",
  "certifications": [],
  "maxResults": 10,
  "dryRun": false,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `suppliers` (type: `string`):

Dataset of flat CRM-ready supplier objects

# 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 = {
    "query": "CNC machining",
    "geo": "Dallas, TX",
    "area": "NA"
};

// Run the Actor and wait for it to finish
const run = await client.actor("forged_mussel/machine-shop-directory-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 = {
    "query": "CNC machining",
    "geo": "Dallas, TX",
    "area": "NA",
}

# Run the Actor and wait for it to finish
run = client.actor("forged_mussel/machine-shop-directory-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 '{
  "query": "CNC machining",
  "geo": "Dallas, TX",
  "area": "NA"
}' |
apify call forged_mussel/machine-shop-directory-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,forged_mussel/machine-shop-directory-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/rWga1SrVqPe3S9G3U/builds/iyuXFjkt7jDZRtea7/openapi.json
