location_search
Resolve any place name into coordinates and IANA timezone, including historical UTC offset for a birth date. Use this first when a user gives a birth city; if ambiguous, ask which place they mean.
Instructions
Resolve a place name to coordinates and IANA timezone — use this first whenever a user gives a birth city rather than latitude/longitude. NEVER recall coordinates from memory; always resolve them here. CREDIT COST: 1 credit per call. Returns display name, region (state/province), latitude, longitude, and IANA timezone. Pass the birth date as date to also get utcOffsetAtDate, the historically-correct UTC offset for that place on that date (1987 DST rules differ from today's). Post-1970 dates resolve locally and cost no extra credits; a pre-1970 date consults the API's historical correction overlay for the top match (1 extra credit) and returns its provenance — tzRuleSource, tzRuleCitation, tzOverlayVersion. When the result is ambiguous (several places share the name, e.g. "portland"), ASK the user which one they mean rather than assuming the first. Optional bias params (country/region/near) improve ranking; a trailing "City, ST" qualifier in the query is also honored.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| date | No | Optional birth/event date as 'YYYY-MM-DD'. When given, each suggestion also carries utcOffsetAtDate / utcOffsetMinutes / isDst — the UTC offset that actually applied at that place on that date, using historical DST rules. Post-1970 is free (local resolution, no API call). Pre-1970, the top match is additionally corrected through the API's historical overlay (1 extra credit) because tzdata models only the zone's reference city before 1970; the remaining suggestions keep their tzdata estimate and are labelled historical_estimate. | |
| near | No | Optional 'lat,lon' proximity hint (e.g. '37.77,-122.42') to bias ranking toward nearby places. | |
| query | Yes | Search query for location, e.g. 'Los Angeles' or 'Wakefield, MI' | |
| admin1 | No | Alias for region (region wins if both supplied). | |
| region | No | Optional admin1 (state/province) qualifier to bias ranking — full name ('Michigan'), ASCII name, or code ('MI'). Boost, not filter. | |
| country | No | Optional ISO 3166-1 alpha-2 country code (e.g. 'US') to bias ranking. Boost, not filter. |