Government — entry 015 of 90
City, New York Open Data
NYC Open Data runs on Socrata; a live keyless GET against the SODA endpoint for the 311 service-request dataset (`data.cityofnewyork.us/resource/erm2-nwe9.json`) returned full JSON with a wildcard `Access-Control-Allow-Origin` header, and the same resource is fetchable as CSV by swapping the file extension. Anonymous reads work without any credential; registering a free Socrata app token is optional and only raises the per-IP throttling limit.
NYC Open Data runs on Socrata's SODA (Socrata Open Data API) — the same query idiom used by dozens of other city and state open-data portals. A live keyless GET this run against /resource/erm2-nwe9.json?$limit=1 (the 311 service-request dataset) returned a genuine 801 B record at HTTP 200 with a wildcard Access-Control-Allow-Origin header, no key or app token required.
GreatAPIs Score
Auth quickstart
- No API key or app token required for anonymous reads — a live GET this run against
/resource/erm2-nwe9.json?$limit=1returned HTTP 200 on the first anonymous try. Registering a free Socrata app token is optional and only raises the per-IP throttling ceiling; it does not gate access.
Your key is stored only in this browser (localStorage) and sent directly to the API — never to greatapis.
Fetch one 311 service-request record
GEThttps://data.cityofnewyork.us/resource/erm2-nwe9.json?$limit=1
[{"unique_key":"69897843","created_date":"2026-07-31T02:36:32.000","agency":"DOT","agency_name":"Department of Transportation","complaint_type":"Street Condition","descriptor":"Pothole","incident_zip":"11434","incident_address":"ROCKAWAY BOULEVARD","street_name":"ROCKAWAY BOULEVARD","cross_street_1":"132 AVENUE","cross_street_2":"BAISLEY BOULEVARD","address_type":"BLOCKFACE","city":"QUEENS","facility_type":"N/A","status":"Open","resolution_description":"The Department of Transportation referred this complaint to the appropriate Maintenance Unit for repair.","resolution_action_updated_date":"2026-07-31T02:36:32.000","community_board":"12 QUEENS","police_precinct":"Precinct 113","borough":"QUEENS","open_data_channel_type":"UNKNOWN","park_facility_name":"Unspecified","park_borough":"QUEENS"}]A live GET this run against the same resource with $select=complaint_type,borough&$limit=2 returned exactly [{"complaint_type":"Request Large Bulky Item Collection","borough":"QUEENS"}
,{"complaint_type":"Noise - Residential","borough":"BROOKLYN"}] — confirming SODA's $select field projection works identically across every dataset resource on the portal, not just this one.
Try it
Developer reference
https://data.cityofnewyork.us- GET/resource/{dataset-id}.json
- GET/resource/{dataset-id}.csv
- GET/api/views/metadata/v1/{dataset-id}
Gotchas & limits
- An unknown resource ID is a real HTTP 404 with a typed JSON error, not an HTML page — a live GET this run against
/resource/xxxx-yyyy.jsonreturned exactly{"code":"dataset.missing","error":true,"message":"Not found","data":{"id":"xxxx-yyyy"}}(119 B). - A
$whereclause referencing a column that doesn't exist on the dataset is a real HTTP 400, and the error body echoes the entire rewritten SQL query back at you — a live GET this run against/resource/erm2-nwe9.json?$where=nonexistent_column=1returned a 3,586 B body with"errorCode":"query.soql.no-such-column"and alinefield containing the full generatedSELECT ... WHEREstatement with a^pointer at the bad column. - Swapping
.jsonfor.csvon the same resource does not return an identical column set — a live comparison this run showed the.jsonexport'sX-SODA2-Fieldsheader ends with four Socrata-computed geography columns (:@computed_region_f5dn_yrerand three siblings) that the.csvexport's ownX-SODA2-Fieldsheader omits entirely, even though both requests hit the same resource with no query params. - Omitting
$limitdoes not return the whole dataset — a live GET this run against/resource/erm2-nwe9.jsonwith zero query parameters returned exactly 1,000 records, Socrata's silent default page cap, not the dataset's real row count. Paging past it requires an explicit$limit/$offset(or$orderfor stable pagination).