-1

I am facing some issue in NYC department of building API. help me if you know any other API giving the same information
I have used this API but didn't work for me https://data.cityofnewyork.us/resource/83x8-shf7.json

Missing fields permitee detailed address

https://data.cityofnewyork.us/resource/83x8-shf7.json?$where=filing_date BETWEEN '2018-05-01T06:00:00' AND '2018-05-30T10:00:00'

Also i am not able get expected data using filters for "filing_date" from same api expected data should return all data between 2018-05-01 and 2018-05-30 for this API But i am getting only few results.

I am getting this data

[
{ "bin__": "3118313", "bldg_type": "1", "block": "05143", "borough": "BROOKLYN", "city": "BROOKLYN", "community_board": "314", "dobrundate": "2018-05-03T00:00:00.000", "expiration_date": "2018-06-11T00:00:00.000", "filing_date": "2018-05-02T00:00:00.000", "filing_status": "INITIAL", "gis_census_tract": "1522", "gis_council_district": "40", "gis_latitude": "40.641731", "gis_longitude": "-73.966432", "gis_nta_name": "Flatbush", "house__": "328", "issuance_date": "2018-05-02T00:00:00.000", "job__": "321679046", "job_doc___": "01", "job_start_date": "2018-05-02T00:00:00.000", "job_type": "A2", "lot": "00068", "non_profit": "N", "owner_s_business_name": "N/A", "owner_s_business_type": "INDIVIDUAL", "owner_s_first_name": "MATTHEW", "owner_s_house__": "328", "owner_s_house_street_name": "ARGYLE ROAD", "owner_s_last_name": "LIMA", "owner_s_phone__": "3475968096", "owner_s_zip_code": "11218", "permit_sequence__": "01", "permit_si_no": "3452932", "permit_status": "ISSUED", "permit_subtype": "OT", "permit_type": "EW", "permittee_s_business_name": "BMB BUILDER INC", "permittee_s_first_name": "YUAN HANG", "permittee_s_last_name": "XIAO", "permittee_s_license__": "0612790", "permittee_s_license_type": "GC", "permittee_s_phone__": "9175776544", "residential": "YES", "self_cert": "N", "site_fill": "NOT APPLICABLE", "state": "NY", "street_name": "ARGYLE ROAD", "superintendent_business_name": "BMB BUILDER INC", "superintendent_first___last_name": "YUAN HANG XIAO", "work_type": "OT", "zip_code": "11218" }]

Expected Data should be

[{ "bin__": "1090379", "bldg_type": "2", "block": "00760", "borough": "MANHATTAN", "city": "GREAT NECK", "community_board": "104", "dobrundate": "2018-05-02T00:00:00.000", "expiration_date": "2018-10-28T00:00:00.000", "filing_date": "2018-05-01T00:00:00.000", "filing_status": "RENEWAL", "gis_census_tract": "111", "gis_council_district": "3", "gis_latitude": "40.753978", "gis_longitude": "-73.993673", "gis_nta_name": "Hudson Yards-Chelsea-Flatiron-Union Square", "house__": "337", "issuance_date": "2018-05-01T00:00:00.000", "job__": "121187606", "job_doc___": "01", "job_start_date": "2016-02-19T00:00:00.000", "job_type": "NB", "lot": "00020", "non_profit": "N", "owner_s_business_name": "HKONY WEST 36 LLC", "owner_s_business_type": "PARTNERSHIP", "owner_s_first_name": "SAM", "owner_s_house__": "420", "owner_s_house_street_name": "GREAT NECK ROAD", "owner_s_last_name": "CHANG", "owner_s_phone__": "9178380886", "owner_s_zip_code": "11021", "permit_sequence__": "07", "permit_si_no": "3451790", "permit_status": "ISSUED", "permit_type": "NB", "permittee_s_business_name": "OMNIBUILD CONSTRUCTION IN", "permittee_s_first_name": "PETER", "permittee_s_last_name": "SERPICO", "permittee_s_license__": "0608390", "permittee_s_license_type": "GC", "permittee_s_phone__": "2124191930", "self_cert": "N", "site_fill": "ON-SITE", "site_safety_mgr_s_first_name": "ROBERT", "site_safety_mgr_s_last_name": "FILIPPONE", "special_district_1": "GC", "state": "NY", "street_name": "W 36 ST", "zip_code": "10018" }]

1 Answers1

0

Combing through the JSON, it appears that these columns are not matching: permit_subtype, superintendent_business_name, superintendent_first___last_name, site_safety_mgr_s_first_name, site_safety_mgr_s_last_name, and special_district_1.

Looking at the original data sources, the columns that do not match are instances where the field is blank for that field. That is, bin__ = 1090379 does not have a permit_subtype, so it is omitted in the JSON (which is standard practice).

It will, however, be included in the CSV output since that format must include all columns: https://data.cityofnewyork.us/resource/83x8-shf7.csv?$where=filing_date%20BETWEEN%20%272018-05-01T06:00:00%27%20AND%20%272018-05-30T10:00:00%27.

This answer took a bit of digging because it wasn't immediately obvious which columns were different between the two examples. It's always helpful to over-explain to make it easier to track-down the issue.

Likewise, per the filing_date question, please include the query you're attempting to use.

Tom Schenk Jr
  • 478
  • 2
  • 8