Find NOAA Climate Locations
noaa_climate_find_locationsSearch for geographic locations by category (CITY, ST, CNTY, CNTRY, ZIP, CLIM_REG, etc.). Returns location IDs used in station search and data queries. Without locationCategoryId, returns all location types; noaa_climate_list_location_categories lists the valid values. Use locationCategoryId=ST to list US states (51 entries — small enough to retrieve completely). To find a location by name, pass nameContains alongside locationCategoryId — the CDO API has no name parameter, so this server enumerates the category and matches the substring itself. It works for any category under the size limit stated on nameContains, which is every category except ZIP; a datasetId or datacategoryId filter can bring a category back under that limit. For a category still too large, sort alphabetically with sortField=name and page through results. Location IDs: states as FIPS:37 (NC), cities as CITY:US530018 (Seattle), zip codes as ZIP:98101, countries as FIPS:US. Obtain location IDs here, then pass them to noaa_climate_find_stations or noaa_climate_fetch_data.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Maximum number of results to return (1–1000). Defaults to 25. | |
| offset | No | Zero-based index of the first result to return for pagination. Defaults to 0. | |
| endDate | No | Filter to locations with data on or before this ISO date (YYYY-MM-DD). Optional. | |
| datasetId | No | Filter to locations covered by this dataset (e.g., "GHCND"). Optional. | |
| sortField | No | Sort results by this field. Use name with sortOrder=asc to browse alphabetically when searching for a specific city or location name. Optional. | |
| sortOrder | No | Sort direction. Optional; defaults to asc. | |
| startDate | No | Filter to locations with data on or after this ISO date (YYYY-MM-DD). Optional. | |
| nameContains | No | Case-insensitive substring match on the location name. The CDO API has no name parameter, so this server applies the match itself, across the whole category rather than one page — which bounds it to a category holding at most 4000 locations. Requires locationCategoryId; adding datasetId or datacategoryId narrows a category that is otherwise too large. Example: locationCategoryId="CITY" with nameContains="seattle". Optional. | |
| datacategoryId | No | Filter to locations with this data category (e.g., "TEMP"). Optional. | |
| locationCategoryId | No | Category filter. Use ST for states (51 entries), CNTY for counties, CITY for cities (large set — thousands of entries), CNTRY for countries, ZIP for zip codes, US_TERR for US territories, CLIM_REG for NOAA climate regions, CLIM_DIV for climate divisions, HYD_ACC/HYD_CAT/HYD_REG/HYD_SUB for hydrological categories. Call noaa_climate_list_location_categories when you do not know which category to use — it returns the authoritative set. Optional — omit to return all location types. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | No | Present when the call failed. Absent on success. | |
| notice | No | Guidance when no locations matched — echoes applied filters and suggests how to broaden. | |
| results | No | Matching locations. | |
| metadata | No | Pagination metadata. Present when the API returns it. | |
| exhausted | No | True when the requested offset is past the end of a non-empty result set — the page is empty but matches exist. Omitted otherwise. | |
| totalCount | No | Total number of matching locations before the page limit. | |
| appliedNameFilter | No | The nameContains value this response was filtered by. Present only when nameContains was supplied; every count below then describes the filtered set, not the whole category. |