Mapbox Surface API

  • View
    82

  • Download
    2

Embed Size (px)

Transcript

Mapbox Surface ApiYour own custom geo api

A REST API that allows users to programmatically query data within a map

a.tiles.mapbox.com/v4/bobbysud.iia43k9m/5/16/10.png

http://wiki.openstreetmap.org/wiki/Tile_Disk_Usagea.tiles.mapbox.com/v4/bobbysud.iia43k9m/5/16/10.vector.pbf

40m50m45m

RecapAll data stored as vector tilesCoordinate converted to ZXYLoad corresponding tileParse data of vector tileFind 2 closest objects to in tileInterpolate All done asynchronously

mapbox.com/developers/api/surfacehttps://api.tiles.mapbox.com/v4/surface/mapbox.mapbox-terrain-v1.json?layer=contour&fields=ele&points=-112.084004,36.05322;-112.083914,36.053573;-112.083965,36.053845Sample Requesthttps://api.tiles.mapbox.com/v4/surfacebase urlmapbox.mapbox-terrain-v1.jsonMapbox mapidRequired. Only can specify 1 mapid.layerlayer=contourRequired. Only can specify 1 layer.

fields=elefieldsAt least 1 field required. Can add more separated via a comma.

layerfieldfieldfields=house_num,osm_idfieldsAt least 1 field required. Can add more separated via a comma.points=-112.084004,36.05322;-112.083914,36.053573;-112.083965,36.053845pointsAt least 1 point required. Can add more separated via a semi-colon.

Volume demohttps://www.mapbox.com/labs/surface/drone/#16/46.6545/6.5388StatsThousands of features300 PointsAverage response time: 400ms*

Limitations

6 tiles, ~1,000 features

1 tile, potentially many more features> zoom level = more tiles but less featuresLimitsmax 300 point limitmax 70 vector tilesExtremely dense tilesFuture

@bobwsmapbox.com/developers/api/surface

Recommended

View more >