Examples
Every snippet on these pages assumes you already have const unmap = new Unmap({ key }) from the Quickstart; they show the call, not the setup.
Focused, runnable examples. Each page is one idea: a map, a lookup, or a route. The code beside every live pane is the code that produced it, so you can copy a page into a project and get the same result.
The maps pages follow the same grain as MapLibre GL JS examples and Mapbox GL JS examples: display a map, change how it looks, drop a marker. Geocoding and routing follow the same jobs as the Google Maps Platform and Mapbox guides: forward and reverse geocoding, autocomplete, nearby search, directions, and travel-time areas.
Nothing here assumes you have used a maps API before. If a word like tile, style, or isochrone goes past you, the one-minute glossary on the Overview defines the seven that matter.
Maps
Initialize a map, change its style, mode, or language, apply a theme, show it as a globe, or put a marker on a place.
Initialize a map in an HTML element with the unmap SDK.
OpenSwitch among the twelve structural styles, each in light and dark.
OpenThe same style, drawn for a dark page.
OpenDraw labels in French, English, or any of the 41 languages in the tiles.
OpenRedraw the map with a colour treatment from the theme builder.
OpenThe outdoor style, with terrain shading where the DEM covers.
OpenGeocode a place and drop a MapLibre marker on the answer.
OpenZoom, compass, and how to move or hide them.
OpenThe same map, drawn as a sphere.
OpenCompose a named catalog layer on a basemap with the overlays option.
OpenCompose the energy overlay set with one profile option. Tiles 404 until archives land.
OpenCompose the agriculture overlay set with one profile option. Tiles 404 until archives land.
OpenCompose the remote overlay set with one profile option. Overlay tiles are live on R2.
OpenCompose the mining overlay set with one profile option. Tiles 404 until archives land.
OpenClick anywhere in Canada and read the ground elevation.
Open
Geocoding
Turn text into a coordinate, a coordinate into a place, a partial query into suggestions, a category into the nearest matches, or many addresses into one request.
Forward geocoding. Turn an address or a place name into a coordinate.
OpenType-ahead suggestions from a partial query, for a search box.
OpenTurn a coordinate into the nearest address or place.
OpenCategory search around a point, sorted by distance.
OpenSend up to 100 searches in one POST. The answer is an array aligned to the input.
OpenGeocode a query and pin the first result on the map.
Open
Routing
Ask for a path between two points, pick a travel mode, or draw the area you can reach in a given time.
A driving route between two points, drawn on the map.
OpenA pedestrian route between two points.
OpenDriving, cycling, walking, and truck routing on the same two points.
OpenIsochrones. The area you can reach from a point inside a time budget.
Open