{
  "title": "Restaurant inspection records — settings",
  "type": "object",
  "schemaVersion": 1,
  "properties": {
    "cities": {
      "title": "Supported city and county portals",
      "type": "array",
      "description": "Pick any subset of the 7 supported city/county portals. Leave empty to scrape all of them. Valid keys are new_york, chicago, cincinnati, austin, king_county, boulder_county, montgomery_county.",
      "editor": "select",
      "default": [
        "new_york",
        "chicago",
        "cincinnati",
        "austin",
        "king_county",
        "boulder_county",
        "montgomery_county"
      ],
      "items": {
        "type": "string",
        "enum": [
          "new_york",
          "chicago",
          "cincinnati",
          "austin",
          "king_county",
          "boulder_county",
          "montgomery_county"
        ],
        "enumTitles": [
          "New York, NY",
          "Chicago, IL",
          "Cincinnati, OH",
          "Austin, TX",
          "King County (Seattle), WA",
          "Boulder County, CO",
          "Montgomery County, MD"
        ]
      },
      "sectionCaption": "Portal, dates and filters"
    },
    "inspectedSince": {
      "title": "Inspection date — from",
      "type": "string",
      "description": "Only inspections on or after this date (YYYY-MM-DD). Great for weekly monitoring.",
      "editor": "textfield",
      "example": "2026-06-01"
    },
    "inspectedUntil": {
      "title": "Inspection date — through",
      "type": "string",
      "description": "Only inspections on or before this date (YYYY-MM-DD). The bound is inclusive, so the whole day counts. Pair it with 'Inspected since' to pull one closed window, e.g. a single month.",
      "editor": "textfield",
      "example": "2026-06-30"
    },
    "businessName": {
      "title": "Establishment name contains",
      "type": "string",
      "description": "Only records whose restaurant name contains this text (case-insensitive), e.g. 'pizza' or 'Starbucks'. Matching happens after records are pulled newest-first, so widen the date range if a rare chain comes back empty.",
      "editor": "textfield",
      "example": "pizza"
    },
    "resultContains": {
      "title": "Published outcome or grade contains",
      "type": "string",
      "description": "Only records whose result or letter grade contains this text (case-insensitive), e.g. 'fail'. Wording differs by portal - Chicago and Montgomery County say 'Fail', Cincinnati says 'Not In Compliance', Boulder says 'Closure', and NYC carries letter grades A/B/C instead of a pass/fail word.",
      "editor": "textfield",
      "example": "fail"
    },
    "maxResultsPerCity": {
      "title": "Maximum records per portal",
      "type": "integer",
      "description": "Cap on records kept per city per run, not a total for the run - the default 500 across all 7 cities returns up to 3,500 records. The cap is applied after the name/result filters, and the hard ceiling is 50,000 per city.",
      "editor": "number",
      "default": 500,
      "minimum": 1
    },
    "maxRunSeconds": {
      "title": "Run time budget (seconds)",
      "type": "integer",
      "description": "Wall-clock budget for this run, in seconds. When it is reached the Actor stops cleanly and finishes successfully with the rows it already collected, instead of being killed mid-run. Cities are fetched one after another, up to 50 pages each; a city not reached in time is reported in the run SUMMARY. Raise it (and the run timeout in Run options) for a deliberately large job.",
      "editor": "number",
      "default": 240,
      "minimum": 30,
      "sectionCaption": "Run budget"
    },
    "socrataAppToken": {
      "title": "Socrata app token (optional)",
      "type": "string",
      "description": "Optional free Socrata app token for higher rate limits on large or scheduled runs. Not required for normal use.",
      "editor": "textfield",
      "isSecret": true
    }
  },
  "description": "For food-safety research and local reporting, collect supported city and county inspection records in a shared field layout. Seven named portals only: NYC, Chicago, Cincinnati, Austin, King County, Boulder County and Montgomery County."
}
