osm_get_bbox
Download OpenStreetMap data inside a bounding box as complete, paged JSON, filtering by tags and element types to retrieve only the map features you need.
Instructions
Download the OSM data in a bounding box, filtered and paged so the result is always complete valid JSON. The API limits the area (see osm_capabilities, default 0.25 square degrees) and returns every node of every way that touches the box, so even a tiny box in a dense city can hold thousands of elements. Use tag_filters (for example ["railway=subway_entrance", "highway=elevator"]), types, tagged_only, inside_bbox_only and compact to get just what you need, and page with next_offset when it is not null. Unfiltered results are sorted as the API sends them (by type, then id), so tagged features can sit on later pages.
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": {
"min_lon": "<min_lon>",
"min_lat": "<min_lat>",
"max_lon": "<max_lon>",
"max_lat": "<max_lat>"
},
"name": "osm_get_bbox"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Maximum elements per page; a page may be shorter to stay within the size cap | |
| types | No | Keep only these element types | |
| offset | No | Start at this element of the filtered list (use the previous next_offset) | |
| compact | No | Return only type, id, lat, lon, tags, nodes and members (drops version, timestamp, changeset, uid, user) | |
| max_lat | Yes | ||
| max_lon | Yes | ||
| min_lat | Yes | ||
| min_lon | Yes | ||
| tag_filters | No | Keep elements with ANY of these tags: "key" (any value) or "key=value" | |
| tagged_only | No | Skip elements without tags (for example the untagged nodes of ways) | |
| inside_bbox_only | No | Drop nodes outside the box; the API also returns far-away nodes of ways that merely touch it. Ways keep their full node id lists. |