About the API
The API helps Web developers publish data from Mapping L.A. on other websites.
The methods here are offered as an experiment. If there are any changes we can make to better provide the data we publish, please contact Ben Welsh with ideas, suggestions or criticisms.
Boundaries
The Times’ regional and neighborhood boundaries are available under a Creative Commons Attribution-Noncommercial-Share Alike license. That means you can share and remix them for non-commercial work as long as you credit The Times and release your creations under the same terms.
All region and neighborhood pages include links to boundaries in WGS 84 projection in KML, KMZ and GeoJSON format. The files are easily portable to other online mapping systems. For instance, here is a Google Map of The Times' definition of Hollywood.
Returns a list of all neighborhoods or regions.
Scheme: /mapping-la/api/v1/<area_type>/getList.<format>/
Area types: neighborhood | region
Formats: xml | json
Example: /mapping-la/api/v1/neighborhood/getList.json/
Returns the boundaries of a single neighborhood or region specified by its unique slug.
Scheme: /mapping-la/api/v1/<area_type>/getBySlug.<format>/?slug=<slug>
Area types: neighborhood | region
Formats: kml | kmz | json
Slugs: Call getList for a complete set
Example: /mapping-la/api/v1/neighborhood/getBySlug.json/?slug=downtown
Returns the boundaries of the neighborhood or region that contains a set of latitude and longitude coordinates.
Scheme: /mapping-la/api/v1/<area_type>/getByLatLng.<format>/?lat=<latitude>&lng=<longitude>
Area types: neighborhood | region
Formats: kml | kmz | json
Latitude & Longitude: Decimal degrees in WGS 84 projection
Example: /mapping-la/api/v1/region/getByLatLng.kml/?lat=34.053&lng=-118.245
Wrappers
A Python wrapper is available on Github at latimes-mappingla-api.
