weather
weather
#
The WeatherKit JSON scalar.
Weather
#
Bases: JSONScalar
A WeatherKit capture at a moment and place.
Every field is required except pressure_trend and wind_gust_mps.
The capture time is stored as epoch seconds through its field transform.
Attributes:
| Name | Type | Description |
|---|---|---|
temperature_celsius |
Annotated[float, Quantity('°C', name=Temperature)]
|
Air temperature. |
apparent_temperature_celsius |
Annotated[float, Quantity('°C', name='Apparent temperature')]
|
"Feels like" temperature. |
dew_point_celsius |
Annotated[float, Quantity('°C', name='Dew point')]
|
Dew point. |
humidity_ratio |
Annotated[float, Quantity(name=Humidity, span=(0.0, 1.0))]
|
Relative humidity, 0 to 1. |
pressure_hpa |
Annotated[float, Quantity(hPa, name=Pressure)]
|
Sea-level pressure in hectopascals. |
wind_speed_mps |
Annotated[float, Quantity(m / s, name='Wind speed')]
|
Sustained wind speed. |
wind_direction_degrees |
Annotated[float, Quantity('°', name='Wind direction', span=(0.0, 360.0))]
|
Wind heading. |
condition |
str
|
WeatherKit condition code — a vendor passthrough string, exempt from the snake_case wire convention. |
symbol_name |
str
|
SF Symbol name for the condition. |
cloud_cover_ratio |
Annotated[float, Quantity(name='Cloud cover', span=(0.0, 1.0))]
|
Cloud cover, 0 to 1. |
precipitation_intensity_mmph |
Annotated[float, Quantity(mm / h, name=Precipitation)]
|
Precipitation rate. |
visibility_meters |
Annotated[float, Quantity(m, name=Visibility)]
|
Visibility distance. |
uv_index |
Annotated[float, Quantity(name='UV index')]
|
Ultraviolet index. |
is_daylight |
bool
|
Whether the capture was during daylight. |
time |
Annotated[datetime, Epoch]
|
The capture time. |
pressure_trend |
PressureTrend | None
|
The pressure's direction, if the provider reports one. |
wind_gust_mps |
Annotated[float | None, Quantity(m / s, name='Wind gust')]
|
Peak gust speed, if reported. |