Does a styled map include address search and routes?
Choose a map style and add your own markers for places you already know. If people need to type an address or get a route inside your app, plan search and routing separately.
The browser uses a public token with only the access it needs. Keep secret tokens out of the browser and preserve the required map credits.
What should you count and what can you save?
Mapbox GL JS meters web map loads when a map starts. Search Box has session or request billing depending on the action, and Directions API uses requests. Estimate these separately.
If you use the Geocoding API, default temporary results are for immediate use. Check permanent geocoding terms and pricing before saving a returned coordinate for later. Search Box has its own temporary-use terms.
How can you estimate what one visit uses?
Sketch a directory of fictional venues. Use no account, token, map request or device location.
- Draw the two pathsOne visitor reads the venue list. Another opens the map, searches for a place and asks for directions.
- Mark the separate servicesWrite where a map starts, where search happens and where a route is requested. Use that list to check each billing unit before building.