Ask for the visible tiles
Tiles are numbered as XYZ map tiles are: at zoomz the world is 2^z by 2^z tiles, x counted from the west and y from the north. Zoom runs from 0 to 22.
When the map stops moving, work out the tiles that cover the visible area and ask for each:
z. The clusters are sized for a tile drawn 512 px wide. If your library counts zoom for 256 px tiles, as Leaflet and Google Maps do, ask for one zoom lower than the map shows (z = floor(zoom) - 1). A map that crosses the antimeridian needs the tiles on both sides.
Draw clusters and pins
[lat, lng, locations, connectors, available, occupied, out_of_order] at the centroid of its locations. Show a cluster as a bubble with its number of connectors, and colour it by the counts if you like. Tapping a cluster usually zooms in on it.
From zoom 15 every location is a pin. Up to zoom 14 a cell whose locations all share one spot is a pin too. Draw every cluster and pin of every tile: a location is in one tile at each zoom, so nothing shows twice.
Locations at the very same coordinates are one pin with all their ids. The name is the first one’s. If a pin has more than one id, let your user page through them in the detail panel.
Filter
Add filters to the tile’s query string. A filtered tile counts only the connectors that match and leaves out a location none of whose connectors do.422 that names it, for example {"error": "power_type is AC or DC"}.
Open a location
When your user taps a pin, read the location by one of itsids:
occupancy, how busy it usually is per hour of the week, and out_of_order_ratio_30d. See Locations and prices and the reference.
Search by EVSE id
Search for the EVSE id printed on a charger, or for its start, from 3 characters:* and spaces don’t count. Exact matches come first, then ids that start with q, at most 10. Move the map to the result and open its location_id.
The search finds chargers only. For addresses and places, use your map library’s geocoding.
Ask again without downloading again
Keep each answer with itsETag, and send it back in If-None-Match when you ask for the same tile again. If nothing changed, the answer is an empty 304 and you draw what you kept. Browsers do this for you: a fetch revalidates by itself, because every answer is Cache-Control: no-cache.