NYC Restaurant Inspection Results Scraper avatar

NYC Restaurant Inspection Results Scraper

Pricing

Pay per event

Go to Apify Store
NYC Restaurant Inspection Results Scraper

NYC Restaurant Inspection Results Scraper

Export NYC restaurant inspection grades, violations, scores, cuisine, address, phone, and geo fields from the official DOHMH Open Data API.

Pricing

Pay per event

Rating

0.0

(0)

Developer

Stas Persiianenko

Stas Persiianenko

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

3 days ago

Last modified

Categories

Share

Export NYC restaurant health inspection grades, violations, scores, cuisine, addresses, phone numbers, and source metadata from the public NYC Open Data DOHMH restaurant inspection API.

What does NYC Restaurant Inspection Results Scraper do?

NYC Restaurant Inspection Results Scraper turns the public New York City Department of Health restaurant inspection dataset into clean Apify dataset rows.

It queries the Socrata Open Data API, applies your borough, ZIP code, cuisine, grade, date, CAMIS, or violation filters, and saves inspection records that are ready for spreadsheets, CRMs, BI tools, and compliance dashboards.

Use it when you need repeatable restaurant inspection data without building your own Socrata pagination, field mapping, and Apify export workflow.

Who is it for?

  • ๐Ÿ™๏ธ Local SEO agencies tracking restaurant reputation and grade changes.
  • ๐Ÿฝ๏ธ Restaurant consultants finding operators with repeat violations or poor scores.
  • ๐Ÿงพ Compliance teams monitoring health inspection outcomes by borough or ZIP code.
  • ๐Ÿ“ Local lead generation teams enriching restaurant account lists.
  • ๐Ÿ›ก๏ธ Insurance, lending, and risk teams screening food-service businesses.
  • ๐Ÿ“Š Data analysts building NYC restaurant quality dashboards.

Why use this restaurant inspection scraper?

  • โœ… Uses the official public NYC Open Data API.
  • โœ… No browser automation or login required.
  • โœ… Saves restaurant identity, address, cuisine, grade, score, violation, and geo fields.
  • โœ… Supports incremental recordDateFrom workflows.
  • โœ… Works with Apify datasets, API clients, webhooks, integrations, and MCP.
  • โœ… Bounded by maxItems so test runs stay cheap.

What data can you extract?

FieldDescription
camisNYC DOHMH restaurant identifier
dbaRestaurant name
boroughNYC borough
addressCombined building, street, borough, and ZIP
zipcodeRestaurant ZIP code
phonePhone number from the city dataset
cuisineNYC cuisine description
inspectionDateInspection date
inspectionTypeCycle inspection, re-inspection, initial inspection, etc.
actionDOHMH action text
violationCodeViolation code such as 08A
violationDescriptionViolation description
criticalFlagCritical / Not Critical / Not Applicable
scoreInspection score as a number
gradePosted grade where available
gradeDateGrade date
recordDateDataset record update date
latitudeLatitude
longitudeLongitude
sourceApiUrlExact API URL used for that page

How much does it cost to scrape NYC restaurant inspection results?

This actor uses pay-per-event pricing.

You pay a small start fee for each run and a per-record fee for every inspection row saved to the dataset.

Because the source is a public API and does not require residential proxies or browser automation, runs are designed to be lightweight and predictable.

How to scrape NYC restaurant inspection data

  1. Open the actor on Apify.
  2. Set maxItems to the number of inspection rows you need.
  3. Optionally choose a borough such as Manhattan, Brooklyn, Queens, Bronx, or Staten Island.
  4. Add ZIP code filters such as 10002 or 11211.
  5. Add cuisine, grade, date, CAMIS, or violation filters if needed.
  6. Run the actor.
  7. Download the dataset as JSON, CSV, Excel, XML, or HTML.
  8. Connect the run to webhooks or integrations for scheduled monitoring.

Input options

Search scope

  • maxItems limits the number of inspection rows.
  • borough filters to one NYC borough.
  • zipCodes filters to one or more postal codes.
  • cuisines filters by exact NYC Open Data cuisine description.
  • grades filters by grade values such as A, B, or C.

Date and compliance filters

  • inspectionDateFrom includes inspections on or after a date.
  • inspectionDateTo includes inspections on or before a date.
  • recordDateFrom supports incremental refreshes based on NYC Open Data updates.
  • criticalOnly keeps only rows with critical violations.
  • violationCodes filters exact violation codes.

Restaurant identifiers

  • camisIds lets you monitor specific restaurants by official NYC DOHMH CAMIS ID.

Advanced sorting

  • inspection_date_desc returns the newest inspection dates first.
  • record_date_desc returns the newest dataset updates first.
  • grade_date_desc returns the newest grade dates first.
  • score_desc returns highest inspection scores first.

Example input

{
"maxItems": 100,
"borough": "Manhattan",
"zipCodes": ["10002"],
"grades": ["A", "B", "C"],
"orderBy": "inspection_date_desc"
}

Example output

{
"camis": "40732665",
"dba": "KATZ'S DELICATESSEN",
"borough": "Manhattan",
"address": "205, EAST HOUSTON STREET, Manhattan, 10002",
"zipcode": "10002",
"phone": "2122542246",
"cuisine": "Sandwiches",
"inspectionDate": "2024-04-24T00:00:00.000",
"inspectionType": "Cycle Inspection / Re-inspection",
"violationCode": "08A",
"criticalFlag": "Not Critical",
"score": 12,
"grade": "A",
"recordDate": "2026-07-02T06:00:15.000",
"sourceDatasetId": "43nn-pn8j"
}

Tips for better restaurant inspection exports

  • Use recordDateFrom for scheduled monitoring jobs.
  • Use ZIP codes for neighborhood prospecting.
  • Use criticalOnly to focus on more serious compliance issues.
  • Use camisIds when you already have a restaurant account list.
  • Keep first runs small, inspect the dataset, then scale up.
  • Combine borough, cuisine, and grade for targeted lead lists.

Integrations and workflow patterns

  • ๐Ÿ“Š Send inspection records to Google Sheets for account research.
  • ๐Ÿงฉ Push results into Airtable for sales operations.
  • ๐Ÿ“ Join latitude and longitude with maps for territory planning.
  • ๐Ÿ”” Trigger Slack alerts when a scheduled run finds critical violations.
  • ๐Ÿงพ Export CSV files for compliance reviews.
  • ๐Ÿง  Use Apify MCP to let AI agents query recent inspection results.

API usage with Node.js

import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('automation-lab/nyc-restaurant-inspection-results-scraper').call({
maxItems: 100,
borough: 'Manhattan',
zipCodes: ['10002'],
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

API usage with Python

from apify_client import ApifyClient
client = ApifyClient('YOUR_APIFY_TOKEN')
run = client.actor('automation-lab/nyc-restaurant-inspection-results-scraper').call(run_input={
'maxItems': 100,
'borough': 'Manhattan',
'zipCodes': ['10002'],
})
items = client.dataset(run['defaultDatasetId']).list_items().items
print(items)

API usage with cURL

curl -X POST 'https://api.apify.com/v2/acts/automation-lab~nyc-restaurant-inspection-results-scraper/runs?token=YOUR_APIFY_TOKEN' \
-H 'Content-Type: application/json' \
-d '{"maxItems":100,"borough":"Manhattan","zipCodes":["10002"]}'

MCP usage

You can use this actor through Apify MCP in Claude Code, Claude Desktop, and other MCP-compatible clients.

MCP server URL:

https://mcp.apify.com/?tools=automation-lab/nyc-restaurant-inspection-results-scraper

Claude Code setup:

$claude mcp add apify-nyc-inspections https://mcp.apify.com/?tools=automation-lab/nyc-restaurant-inspection-results-scraper

Claude Desktop JSON config:

{
"mcpServers": {
"apify-nyc-inspections": {
"url": "https://mcp.apify.com/?tools=automation-lab/nyc-restaurant-inspection-results-scraper"
}
}
}

Example prompts:

  • "Run the NYC restaurant inspection scraper for Manhattan ZIP 10002 and summarize restaurants with critical violations."
  • "Export 500 Brooklyn restaurant inspection rows and group them by cuisine and grade."
  • "Monitor CAMIS IDs in this restaurant list and tell me which records changed since last week."

Scheduling

Create a saved task on Apify when you need recurring monitoring.

Useful scheduled workflows include:

  • Daily critical violation monitoring for client restaurants.
  • Weekly grade changes by borough.
  • Monthly restaurant lead enrichment for a sales territory.
  • Incremental syncs using recordDateFrom.

Data quality notes

The actor returns the fields published by NYC Open Data.

Some records can have missing grades, missing violation descriptions, or null location fields because the source dataset itself is incomplete for those rows.

The actor keeps those records instead of hiding them so analysts can make their own filtering decisions.

FAQ

Why do I see multiple rows for the same restaurant?

The NYC dataset is inspection/violation based, not one row per restaurant. A restaurant can appear multiple times across inspections and violations.

Why is the grade empty?

Not every inspection row has a posted grade. Use gradeDate and inspectionType to understand when grades were assigned.

Why did my cuisine filter return no records?

Cuisine filters must match NYC Open Data cuisine descriptions exactly. Try running without a cuisine filter first, then copy the value from the dataset.

Legality and responsible use

This actor uses a public NYC Open Data API endpoint. It does not bypass login, paywalls, or anti-bot controls.

You are responsible for using exported data in compliance with applicable laws, platform terms, and your own data governance rules.

Explore related Automation Lab actors:

Changelog

  • Initial version: public NYC Open Data restaurant inspection export with filters, pagination, and per-record billing.

Support

If you need a new filter, output field, saved task example, or city inspection dataset added, open an issue from the Apify actor page.

Summary

NYC Restaurant Inspection Results Scraper gives agencies, analysts, and compliance teams a reliable way to export New York City restaurant inspection records from the official public dataset.

It is built for repeatable monitoring, lead enrichment, and compliance workflows on Apify.