GpE’s …

"that we would do we should do when we would" (William Shakespeare)

Italian municipalities’ web service.

2019-01-26 

I wrote a simple WS to query the Italian municipalities dataset.

 

Find below details about the service (call’s syntax, parameters and Json response.

 

 

Request URL

https://www.gerriquez.com/comuni/ws.php?<parametri>

OR

PostgreSQL                                DDL: sì DATI: sì

Json result (dencomune=Roma in the example)

application/json

dencomune = <municipalities name> (es.: dencomune = Roma)

codistat = <municipalitiy’s ISTAT code> (es.: codistat=015146)

OR

region = <region’s name> (es.: regione=liguria)

["{\"Regione\":\"Lazio\",\"CittaMetropolitana\":\"Roma\",\"Provincia\":\"Roma\",\"CodiceComuneAlfanumerico\":\"058091\",\"DenominazioneItaliano\":\"Roma\",\"DenominazioneAltraLingua\":\"\",\"RipartizioneGeografica\":\"Centro\",\"Capoluogo\":\"Y\",\"SiglaAutomobilistica\":\"RM\",\"CodiceCatastaleDelComune\":\"H501\",\"PopolazioneLegale2011\":2617,\"latitude\":41.9028,\"longitude\":12.4964,\"CAP\":\"00118-00199\"}"]

NOTE

  • Latitude and longitude data were downloaded via Google’s geocoding API.
  • Postal codes data were downloaded via Google’s geocoding API. In case of multiple postal codes for each municipality (es.: Milano, Roma ecc.) “PostalCode” field will contain one string with all the postal codes, hyphen separated for sequential p.codes, comma separated for “isolated” postal codes  (es.: <pc_from1>-<pc_to1>,pc2,pc_n …)

Send your feedback…

© 2019 Giampaolo Erriquez

OK