This tool is an alternative to Mapbox Studio and lets you easily create or update vector tilesets on Mapbox from your CSV files using command line. It can be especially handy if you need to:
...
MapboxUtils is distributed as a Docker image so you need to have Docker platform installed. You can get Docker here.
MapboxUtils is publicly available on Docker hub: https://hub.docker.com/r/clevermaps/mapbox-utils
...
Running MapboxUtils
Create a new tileset without specifying tilesetname or layernamefrom CSV file
Code Block |
---|
docker run -t -v /home/user/clevermaps/mapbox-utils:/workdir clevermaps/mapbox-utils:latest --inputfile /workdir/countries_wkt.csv --pkeycolumn id --geomcolumn wkt --minzoom 5 --maxzoom 10 --mapboxtoken abcdefgah1234 |
Create a new tileset and specify tilesetname and layernamefrom SHP file
Code Block |
---|
docker run -t -v /home/user/clevermaps/mapbox-utils:/workdir clevermaps/mapbox-utils:latest --inputfile /workdir/countries_wkt.csvshp --pkeycolumn id --geomcolumn wkt --minzoom 5 --maxzoom 10 --mapboxtoken abcdefgah1234 --tilesetname countries_wkt --layername countries_wkt |
Update existing tileset
Code Block |
---|
docker run -t -v /home/user/clevermaps/mapbox-utils:/workdir clevermaps/mapbox-utils:latest --inputfile /workdir/countries_wkt.csv --pkeycolumn id --geomcolumn wkt --minzoom 5 --maxzoom 10 --mapboxtoken abcdefgah1234 --tilesetmapid cleveranalytics.14j1fhp2 --tilesetname countries_wkt-02ssft |
...