search_location
Search for any place name to get its latitude and longitude, enabling weather queries without coordinates. Handles typos via fuzzy matching and supports country filtering.
Instructions
Searches for locations by name to get coordinates for weather queries.
Convert location names to coordinates using fuzzy search. Essential for natural language weather queries like "weather in Zurich" instead of requiring latitude/longitude coordinates.
Examples:
"Zurich" → Returns Zurich, Switzerland with coordinates
"Bern" → Returns multiple matches (Bern CH, Bern US, etc.)
"Zermatt" → Returns ski resort with elevation data
"Lake Geneva" → Returns lake coordinates
Features:
Fuzzy matching (handles typos)
Multi-language support
Country filtering (e.g., country="CH" for Switzerland only)
Returns population, timezone, elevation
Enriched with feature type descriptions and elevation categories
Workflow:
Search for location by name
Select result (usually first is best match)
Use latitude/longitude for get_weather or get_snow_conditions
Use this tool when:
User provides location name instead of coordinates
Need to find coordinates for a city, mountain, or landmark
Want to discover locations in a specific country
Args: name: Location name to search (e.g., 'Zurich', 'Eiger', 'Lake Lucerne') count: Number of results to return (1-100, default: 10) language: Language for results (default: 'en', options: 'de', 'fr', 'it', etc.) country: Optional country code filter (e.g., 'CH' for Switzerland, 'DE' for Germany)
Returns: Dictionary containing: - results (list[dict]): List of matching locations, each with: - name (str): Location name - latitude (float): Latitude coordinate - longitude (float): Longitude coordinate - elevation (float | None): Elevation in meters - country (str): Country code - timezone (str): Timezone identifier - population (int | None): Population if applicable - feature_type_description (str): Type of location (City, Mountain, Lake, etc.) - elevation_category (str): Low, Medium, High, or Very High
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | ||
| count | No | ||
| country | No | ||
| language | No | en |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||