Search boundaries
search_boundariesFinds administrative boundaries (countries, states, counties, cities, districts) and postcode areas by name, in any language. Filter by country, kind or admin_level; bias toward a point with near. Free and public. A name we hold (the place's own name or a translation, optionally followed by ", " such as "Paris, France" or "Springfield, IL") is answered from our own index with no upstream call; anything else is looked up in OpenStreetMap. Returns candidates with id, kind, admin_level, country, parents, bbox, centroid and population, but no polygon: pass the id to get_boundary for that. Choose by kind: admin_level is OpenStreetMap's number and is null for a result whose level we do not hold. A street address or a landmark is not a boundary: when nothing is named that but the text matched one, results is empty and located gives its point (name, kind, lat, lon) with a hint to call reverse_boundaries for every boundary containing it (or create_area for a park, reef or region with no boundary). When nothing at all matched, results is empty with a hint naming the call that gets somewhere instead (a city or district name, reverse_boundaries, create_area); do not retry other spellings of a shop or street. A city OpenStreetMap maps only as a point under another name ("Christchurch" inside "Christchurch City") returns the boundaries containing it with matched: "containing" and a hint; check the first result is the area meant. While OpenStreetMap's search is down, a name nobody searched before is answered from the boundaries already cached under it, marked partial: true with retry_after and a hint (others with the same name may be missing), or 503 upstream_unavailable with retry_after when none is cached.
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": {
"q": "<q>"
},
"name": "search_boundaries"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| q | Yes | A place name, e.g. "Berlin", "Alameda County", "75011". A street address returns located (its point) instead of results. | |
| kind | No | Only this kind (normalized across countries): country, state, region, province, county, district, municipality, city, borough, ward, neighbourhood, postal_code. | |
| near | No | lat,lon to prefer results near, e.g. 37.77,-122.42. | |
| limit | No | At most this many results (1–40, default 10). | |
| country | No | Limit to countries: ISO 3166-1 alpha-2, comma-separated (e.g. US or de,at,ch). | |
| admin_level | No | Only this OSM admin_level (2 = country; meaning varies by country below that). Leaves out results whose level we do not hold; prefer kind. |