Skip to contents

API token, style, and data management

mapboxapi-package mapboxapi
An R interface to Mapbox web services
mb_access_token() get_mb_access_token() list_tokens()
Install or retrieve a Mapbox access token in your .Renviron for repeated use
get_style() list_styles()
Get information about a style or list styles from a Mapbox account
upload_tiles()
Upload dataset to your Mapbox account
check_upload_status()
Check the status of a Mapbox upload

Geocoding

mb_geocode() mb_reverse_geocode()
Geocode an address or place description using the Mapbox Geocoding API
mb_batch_geocode()
Geocode addresses or locations in bulk using the Mapbox Batch Geocoding API
mapboxGeocoderInput()
Use Mapbox's Geocoder widget in a Shiny application
geocoder_as_sf()
Convert the result of a mapboxGeocoderInput() geocoded location to an sf object
geocoder_as_xy()
Convert the results of a mapboxGeocoderInput() geocoded location to XY coordinates
mb_directions()
Make a request to the Mapbox Directions API
mb_matrix()
Retrieve a matrix of travel times from the Mapbox Directions API
mb_isochrone()
Generate isochrones using the Mapbox Navigation Service Isochrone API
mb_optimized_route()
Return an optimized route for a series of input coordinates

Tilequery API and tippecanoe

get_vector_tiles()
Retrieve vector tiles from a given Mapbox tileset
query_tiles()
Get information about features in a tileset using the Tilequery API
tippecanoe()
Generate an .mbtiles file with tippecanoe

Static Tiles and Static Maps APIs

addMapboxTiles()
Use a Mapbox style in a Leaflet map
get_static_tiles()
Get static tiles from a Mapbox style for use as a basemap
static_mapbox()
Return a static Mapbox map from a specified style
layer_static_mapbox() tm_static_mapbox()
Make a static Mapbox ggplot2 layer or tmap basemap
prep_overlay_markers()
Prepare overlay markers for use in a Mapbox static map

Mapbox Tiling Service

mts_create_source()
Create a Mapbox tileset source from a sf object using the Mapbox Tiling Service API
feature_options()
Specify feature options for an MTS recipe layer
mts_create_tileset()
Create a tileset with the Mapbox Tiling Service API
mts_get_recipe()
Retrieve the recipe for an MTS tileset in your Mapbox account
mts_list_sources()
List tileset sources in your Mapbox account
mts_list_tilesets()
List tilesets in a Mapbox account
mts_make_recipe()
Prepare a recipe for use with the Mapbox Tiling Service
mts_publish_tileset()
Publish a tileset with Mapbox Tiling Service
mts_update_recipe()
Update a tileset's MTS recipe
mts_validate_recipe()
Validate a Mapbox Tiling Service recipe
recipe_layer()
Prepare a formatted recipe layer for use in a Mapbox Tiling Service recipe
tile_options()
Specify tile options for an MTS recipe layer