US Code Violations - 9 jurisdictions, one case model
Pricing
from $2.00 / 1,000 code violations
US Code Violations - 9 jurisdictions, one case model
Property, housing and code violations from 9 US jurisdictions (~4.2M records) normalised into one schema with separate case-status and resolution fields.
Pricing
from $2.00 / 1,000 code violations
Rating
0.0
(0)
Developer
Rishi Vinodkumar
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
12 hours ago
Last modified
Categories
Share
US Code Violations — 9 jurisdictions, one case model
Property, housing and building code violations from nine US jurisdictions, normalised into a single schema.
~4,249,022 violation records across 9 actively-maintained sources.
| Source | State | Records | Last verified |
|---|---|---|---|
| Chicago | IL | ~2,020,658 | 2026-07-29 |
| Montgomery County | MD | ~954,255 | 2026-07-22 |
| Chicago (ordinance hearings) | IL | ~838,859 | 2026-07-30 |
| Kansas City | MO | ~174,999 | 2026-07-01 |
| New Orleans | LA | ~111,441 | 2026-07-30 |
| Mesa | AZ | ~80,580 | 2026-07-28 |
| Norfolk | VA | ~44,835 | 2026-07-29 |
| New York City (BIC) | NY | ~18,026 | 2026-07-29 |
| Cambridge | MA | ~5,369 | 2026-07-22 |
Why this is harder than it looks
The other actors in this repo reconcile spellings. This one reconciles processes. All nine publish a "status" field, and they are not describing the same thing:
| Jurisdiction | Field | Vocabulary | What it actually means |
|---|---|---|---|
| Chicago | violation_status | OPEN / COMPLIED / NO ENTRY | violation state |
| Montgomery County | disposition | Triennial Completed / Citation issued | inspection outcome |
| Kansas City | case_status | In-Compliance / In-Violation | case state |
| Norfolk | status | Closed - Corrected / Work in Progress | case state |
| NYC BIC | violation_disposition | Settled / Barred by CPLR / Judgement | court outcome |
| Cambridge | violation_status | Corrected / Cited | violation state |
| Chicago ordinance | case_disposition | Liable / Non-Suit / Default / Not Liable | hearing outcome |
| New Orleans | currentstatus | Violations Abated / Payment Received | abatement pipeline |
| Mesa | status | In Violation / Legal Action / Closed | case state |
Collapsing those into one enum would look tidy and be a lie — a court settlement is not a re-inspection result. So the schema carries two orthogonal fields:
case_status OPEN | CLOSED | UNKNOWNresolution CORRECTED | CITED | DISMISSED | NO_ACCESS | OTHER | NONE
plus raw_status (always the original string) and status_semantics
(case / inspection / legal) so you never silently compare a court
judgement against a housing re-inspection.
The mapping is substring-based and order-sensitive: "Closed - Corrected"
contains both closed and corrected; "Not Corrected" contains
corrected; "Settled - Pending" contains settled; and "Not Liable"
contains "Liable", where a flipped order would turn ~107k dismissals into
citations. test_status.py pins all 43 observed strings.
Four traps found while building this
1. Montgomery County is mostly not violations. Its 954k rows are dominated
by routine triennial inspections (Triennial Completed, 547k of them). Filter
resolution = CITED to find actual enforcement. Auto-inference also picked
date_closed as the event date, which would have silently excluded every
open case — we use date_filed.
2. Kansas City's dates run into the future. date_found contains
data-entry typos as far ahead as October 2029. Set violatedBefore if you are
building time series. verify.py flags this rather than reporting the feed
healthy.
3. Chicago has two violation feeds. chicago is building violations;
chicago_ordinance is administrative hearing outcomes — what the city actually
did about them. Its violation_date contains typos reaching year 6111, so
always set violatedBefore.
4. NYC BIC is not what you expect. It is the Business Integrity Commission — trade waste and public markets — not the Department of Buildings. Narrow, but the only source here with monetary penalties and court dispositions.
Who this is for
- Real-estate investors sourcing distressed-property leads
- Contractors (roofing, façade, abatement) finding properties under order
- Property managers and compliance vendors monitoring portfolios
- Journalists and researchers tracking enforcement patterns
Usage
Open violations with an address, last quarter:
{"sources": ["chicago", "norfolk", "cambridge"],"violatedAfter": "2026-05-01","openOnly": true,"requireAddress": true,"maxResults": 5000}
Actual enforcement actions only (skips routine inspections):
{ "violatedAfter": "2026-01-01", "violatedBefore": "2026-07-31", "resolution": ["CITED"] }
Local development
pip install requestspython local_run.py --coveragepython local_run.py --after 2026-05-01 --limit 10python local_run.py --open-only --after 2026-01-01 --limit 20python local_run.py --resolution CITED --after 2026-01-01python verify.py # health-check every sourcepython test_status.py # status-classification regression tests
Legal
Public, logged-out municipal open-data endpoints via each jurisdiction's
official Socrata API. No authentication, no account, no terms accepted, no
anti-bot circumvention. Code violations are public records attached to
properties; property_owner is populated only where the jurisdiction
publishes it as part of that public record. Rate limits respected with
exponential backoff.