OpenStreetMap City Search Scraper is a BrowserAct Bot template for collecting structured public place records from OpenStreetMap's Nominatim search endpoint. Configure a Nominatim base URL, a city or place query, and a result count, then run the Bot to return place names, coordinates, OSM identifiers, categories, addresses, and tags for geospatial research, location enrichment, mapping workflows, or automation pipelines.
What Does BrowserAct OpenStreetMap City Search Scraper Do?
This template constructs a public Nominatim search URL, opens the JSON response, parses each returned place object, derives an OpenStreetMap place URL from the OSM type and ID, and returns one structured record per place.
Key Features
- Extract public OpenStreetMap Nominatim search results without requiring a login.
- Capture display name, coordinates, place ID, OSM type, OSM ID, category, type, importance, address, extra tags, and search query.
- Generate a canonical OpenStreetMap URL for each place when OSM identifiers are available.
- Configure the Nominatim base URL, query, and count.
- Handle cases where the public endpoint returns fewer records than requested.
What Data Can I Extract from OpenStreetMap Nominatim?
| Field | Description |
|---|---|
rank |
Result position assigned by the Bot. |
place_rank |
Nominatim place rank when returned. |
display_name |
Full public display name for the place. |
place_url |
Derived OpenStreetMap URL built from OSM type and OSM ID. |
latitude |
Latitude from the Nominatim result. |
longitude |
Longitude from the Nominatim result. |
place_id |
Nominatim place ID. |
osm_type |
OpenStreetMap object type, such as node, way, or relation. |
osm_id |
OpenStreetMap object ID. |
category |
Nominatim category or class. |
type |
Nominatim result type. |
importance |
Nominatim importance score when returned. |
address |
Address details as structured JSON text. |
extratags |
Extra OpenStreetMap tags as structured JSON text. |
search_query |
Query used for the run. |
How to Use OpenStreetMap City Search Scraper
- Click Run task.
- Enter the Nominatim base URL.
- Enter a city, region, address, landmark, or place query.
- Set how many place records to collect.
- Run the Bot and review the structured place results.
- Reuse the Bot with another query or connect the output to your workflow.
Input Parameters
| Parameter | Required | Default | Description |
|---|---|---|---|
base_url |
Yes | https://nominatim.openstreetmap.org |
Nominatim service base URL without a trailing path. |
query |
Yes | Seattle, Washington |
Free-text place search query passed to Nominatim. |
count |
Yes | 10 |
Maximum number of place records to return. Nominatim may return fewer records when fewer matches are available. |
Example Output
{
"results": [
{
"rank": 1,
"place_rank": 16,
"display_name": "Seattle, King County, Washington, United States",
"place_url": "https://www.openstreetmap.org/relation/237385",
"latitude": "47.6038321",
"longitude": "-122.330062",
"place_id": "325809332",
"osm_type": "relation",
"osm_id": "237385",
"category": "boundary",
"type": "administrative",
"importance": "0.7344378062407435",
"address": "{\"city\":\"Seattle\",\"county\":\"King County\",\"state\":\"Washington\",\"country\":\"United States\",\"country_code\":\"us\"}",
"extratags": "{\"website\":\"https://seattle.gov/\",\"wikidata\":\"Q5083\",\"wikipedia\":\"en:Seattle\"}",
"search_query": "Seattle, Washington"
}
]
}
How Does it Work?
BrowserAct builds the public Nominatim URL in the format {base_url}/search?q={query}&format=jsonv2&limit={count}&addressdetails=1&extratags=1. It opens the JSON response directly, reads the response body, and treats each JSON object in the array as one place result.
For each result, BrowserAct extracts the visible JSON fields, including coordinates, identifiers, category, type, importance, address, and extra tags. Because Nominatim does not include a ready-made OpenStreetMap page URL, BrowserAct derives place_url from osm_type and osm_id. The Bot stops when it reaches count or when the public endpoint returns fewer results.
How to Build a New Scraper Bot with Agent Built
Step 1: Describe the Data You Need
Open BrowserAct and start Agent Built from the Home prompt box or from Create -> Build with Agent. Paste a clear request that includes the website, the records to collect, the filters or search conditions, the fields to return, the result limit, and the inputs you want to reuse later.

Step 2: Let BrowserAct Build and Test the Bot
BrowserAct explores the live website, works out the navigation and extraction path, and validates the result. If BrowserAct asks for clarification, reply in the same build conversation with the missing URL, condition, field, example, or expected output.

Step 3: Run the Bot and Review the Result
When the build is complete, run the Bot with the default inputs first. Review the structured records, source URLs, missing fields, and row count before reusing the Bot with new inputs or connecting it to another workflow.


Why Scrape OpenStreetMap Nominatim Results?
OpenStreetMap Nominatim data helps teams enrich locations, normalize place names, collect coordinates, attach OSM identifiers, compare geospatial records, and route public place metadata into maps, databases, dashboards, or agent workflows.
Who Can Use This Template?
- GIS analysts collecting public place metadata.
- Data teams enriching city, address, or landmark records.
- Mapping product teams validating coordinates and OSM IDs.
- Researchers comparing public geographic search results.
- Automation builders routing place data into spreadsheets, databases, APIs, or agents.
How Many Results Can You Scrape?
Use count to control the maximum number of records returned. Nominatim may return fewer records when the query has fewer public matches, and the public endpoint may cap the maximum number of records returned in one request.
Automation and Export
BrowserAct returns structured OpenStreetMap Nominatim records first. You can then use the output through API JSON responses, n8n workflows, Make scenarios, Zapier automations, MCP-based agent workflows configured from the Bot's Integrations tab, or manual CSV review.
Need Help?
Contact us at
Discord: Discord Community
E-mail: service@browseract.com

