Concepts
Stations
Every observation, forecast, and settlement row keys to a station. The registry ships in the SDK as a typed catalog: 94 stations today (29 US, 65 international), each carrying the identifiers and timezone that make settlement math work.
from mostlyright.weather import stations
info = stations.CATALOG.get("KNYC")# StationInfo(code='NYC', ghcnh_id='USW00094728', icao='KNYC',# name='Central Park, New York', tz='America/New_York',# latitude=40.7789, longitude=-73.9692, country='US',# venues=frozenset({'kalshi'}))That output is real, captured from the installed package. Use the public catalog; the old from mostlyright._internal._stations import STATIONS path is private and unstable.
What an entry carries
Section titled “What an entry carries”| Field | Why it exists |
|---|---|
code | 3-letter NWS id (NYC): what settlement products key on |
icao | 4-letter id (KNYC): what METAR feeds key on |
ghcnh_id | NOAA identifier used to fetch archived reports |
tz | IANA timezone: mints the LST settlement calendar |
latitude / longitude | Grid lookups for NWP and satellite |
country | Registry filter axis |
venues | Which prediction-market venues settle on this station |
One station, several identifier systems: the catalog is the crosswalk, so you never hand-map NYC to KNYC to USW00094728.
Lookups and filters
Section titled “Lookups and filters”C = stations.CATALOG
C.get("KNYC") # by ICAOC.filter_by_venue("kalshi") # stations a venue settles onC.filter_by_country("US") # by country codeC.venues() # the venue set the registry knowsget() raises KeyError for an unknown station and includes examples of accepted registry-key and ICAO forms.
Venue filtering is the supported way to ask “which stations does Kalshi settle on”: link-time truth from the installed version, never a hardcoded city table in prose (city universes shift by release; the installed package carries the current mapping).
International coverage
Section titled “International coverage”International stations are full registry entries. They use ICAO keys, carry the correct timezone (Tokyo uses Asia/Tokyo), and work with every method that accepts a station id. Two practical differences from US sites: Polymarket’s international cities settle on daily extremes in whole degrees C, and code can be absent where no NWS id exists. Use icao as the universal key.
Adding a station
Section titled “Adding a station”The registry is data in the SDK repo (schemas/stations.json, codegen-shared to both languages). Adding coverage is an upstream contribution, not a runtime patch; a city-first index over this registry is tracked as an SDK feature request.
See also
Section titled “See also”- Daily windows: what the
tzfield is for - Markets: venue resolution built on these entries
- API reference: domains and signatures