Union Polygons
union_toolMerge multiple polygons into one unified geometry to combine service areas, delivery zones, isochrones, or coverage regions; returns Polygon or MultiPolygon if inputs do not overlap.
Instructions
Merge two or more polygons into a single unified geometry. Useful for combining service areas, delivery zones, isochrones, or coverage regions. Returns a Polygon or MultiPolygon if the inputs do not overlap. Works offline without API calls. INPUT SHAPE: pass polygons as an array of polygons. Each polygon is an array of rings; each ring is an array of [lng, lat] pairs. When chaining with isochrone_tool, extract feature.geometry.coordinates from each isochrone Feature — that is already a valid Polygon value. Skip features whose geometry.type === "MultiPolygon" (pass each inner Polygon separately) or whose geometry.type === "LineString" (set isochrone_tool polygons=true to get Polygon output instead).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"polygons": "<polygons>"
},
"name": "union_tool"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| polygons | Yes | Array of polygons to merge into a single union geometry |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| type | Yes | Geometry type: Polygon or MultiPolygon | |
| geometry | Yes | GeoJSON geometry of the merged polygon (Polygon or MultiPolygon) | |
| mapboxRender | No | Map-payload reference for `render_map_tool`. Surfaced so the LLM can chain the next call without re-emitting geometry. |