Mapbox
Mapbox gives your app vector maps, address geocoding, and routing. Connect it inside a project and the agent can add maps, search-as-you-type address fields, and route lines to that project using your own token.
What you get by connecting it
Once Mapbox is connected, the agent can wire up:
- Maps - a map view styled with Mapbox's vector tiles.
- Geocoding - turning an address into coordinates, and coordinates back into a readable address, including search-as-you-type.
- Routing - directions between points, drawn as a line on the map.
All of this runs on your public token. The first time the agent uses Mapbox in a conversation, it says so in its opening sentence, so you always know when your connection is in play.
A note on the preview: fully interactive pan-and-zoom maps need a development or production build, so they do not run in the Expo Go preview. In the preview the agent uses static map images instead, which look right and behave for most flows. Ask for a development build when you need the fully interactive map.
Connecting it
Mapbox needs a public token (it starts with pk.). Create a dedicated token for this app and environment with only the public scopes its map, geocoding, and directions calls need.
Find your tokens in your Mapbox account page, under Access tokens.
To connect, open the project build, select Connectors, choose Mapbox, and enter the public token. The in-chat connect card opens the same form when the agent needs it. Connecting requires a paid plan, and the saved connection applies only to that project.
Use Test now to run a bounded geocoding check and Disconnect behind the confirmation step to remove the token from the project. That check does not prove the native SDK or every optional API scope is configured.
Keys and security
Mapbox is a just connect connector. The public token is designed to be visible in a released client, so isolation and least privilege matter: use a different minimum-scope token per app and environment, monitor its usage, and rotate it when needed.
Mapbox URL restrictions accept web referrer URLs. They do not accept iOS bundle IDs or Android package names, and URL-restricted tokens do not work with Mapbox's native mobile SDKs. Use URL restrictions only for a separate web token called from an allowed website.
The connector does not collect an sk. token or publish tilesets and styles. If a server-side publishing job needs one, create a separate minimum-scope secret token and put it directly in that backend's secret manager - never in chat or client code.
Useful links
- Mapbox documentation: https://docs.mapbox.com
- Appsanic guide: Maps and location
Next
Read Maps and location for the full picture of maps, geocoding, and directions across both Mapbox and Google Maps.
