diff --git a/weather-api-widget/README.md b/weather-api-widget/README.md index f752dbb..9bfc5bc 100644 --- a/weather-api-widget/README.md +++ b/weather-api-widget/README.md @@ -18,7 +18,8 @@ following config parameters: | units | `metric` | `metric` for celsius, `imperial` for fahrenheit | | icon_pack_name | `weather-underground-icons` | Name of the icon pack, could be `weather-underground-icon` or `VitalyGorbachev` or create your own, more details below | | icons_extension | `.png` | File extension of icons in the pack | -| show_forecast | false | Show forecast for next three days | +| show_daily_forecast | false | Show forecast for next three days | +| show_hourly_forecast | false | Show hourly forecast section | | timeout | 120 | How often in seconds the widget refreshes | ### Icons: diff --git a/weather-api-widget/example_response.json b/weather-api-widget/example_response.json new file mode 100644 index 0000000..dfc8e8d --- /dev/null +++ b/weather-api-widget/example_response.json @@ -0,0 +1,3057 @@ +{ + "location": { + "name": "Toronto", + "region": "Ontario", + "country": "Canada", + "lat": 43.667, + "lon": -79.417, + "tz_id": "America/Toronto", + "localtime_epoch": 1729581202, + "localtime": "2024-10-22 03:13" + }, + "current": { + "last_updated_epoch": 1729580400, + "last_updated": "2024-10-22 03:00", + "temp_c": 13.2, + "temp_f": 55.8, + "is_day": 0, + "condition": { + "text": "Clear", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 5.1, + "wind_kph": 8.3, + "wind_degree": 226, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.17, + "precip_mm": 0.0, + "precip_in": 0.0, + "humidity": 88, + "cloud": 0, + "feelslike_c": 12.7, + "feelslike_f": 54.9, + "windchill_c": 14.6, + "windchill_f": 58.2, + "heatindex_c": 14.8, + "heatindex_f": 58.6, + "dewpoint_c": 12.9, + "dewpoint_f": 55.2, + "vis_km": 14.0, + "vis_miles": 8.0, + "uv": 0.0, + "gust_mph": 10.8, + "gust_kph": 17.4 + }, + "forecast": { + "forecastday": [ + { + "date": "2024-10-22", + "date_epoch": 1729555200, + "day": { + "maxtemp_c": 22.1, + "maxtemp_f": 71.8, + "mintemp_c": 12.7, + "mintemp_f": 54.9, + "avgtemp_c": 17.2, + "avgtemp_f": 62.9, + "maxwind_mph": 9.6, + "maxwind_kph": 15.5, + "totalprecip_mm": 0.0, + "totalprecip_in": 0.0, + "totalsnow_cm": 0.0, + "avgvis_km": 10.0, + "avgvis_miles": 6.0, + "avghumidity": 76, + "daily_will_it_rain": 0, + "daily_chance_of_rain": 0, + "daily_will_it_snow": 0, + "daily_chance_of_snow": 0, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "uv": 0.6 + }, + "astro": { + "sunrise": "07:42 AM", + "sunset": "06:22 PM", + "moonrise": "10:20 PM", + "moonset": "02:02 PM", + "moon_phase": "Waning Gibbous", + "moon_illumination": 74, + "is_moon_up": 0, + "is_sun_up": 0 + }, + "hour": [ + { + "time_epoch": 1729569600, + "time": "2024-10-22 00:00", + "temp_c": 16.6, + "temp_f": 61.8, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 4.9, + "wind_kph": 7.9, + "wind_degree": 247, + "wind_dir": "WSW", + "pressure_mb": 1021.0, + "pressure_in": 30.16, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 84, + "cloud": 0, + "feelslike_c": 16.6, + "feelslike_f": 61.8, + "windchill_c": 16.6, + "windchill_f": 61.8, + "heatindex_c": 16.6, + "heatindex_f": 61.8, + "dewpoint_c": 13.7, + "dewpoint_f": 56.6, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.3, + "gust_kph": 16.6, + "uv": 0 + }, + { + "time_epoch": 1729573200, + "time": "2024-10-22 01:00", + "temp_c": 15.9, + "temp_f": 60.6, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 4.7, + "wind_kph": 7.6, + "wind_degree": 238, + "wind_dir": "WSW", + "pressure_mb": 1021.0, + "pressure_in": 30.15, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 86, + "cloud": 0, + "feelslike_c": 15.9, + "feelslike_f": 60.6, + "windchill_c": 15.9, + "windchill_f": 60.6, + "heatindex_c": 15.9, + "heatindex_f": 60.6, + "dewpoint_c": 13.5, + "dewpoint_f": 56.3, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 9.8, + "gust_kph": 15.8, + "uv": 0 + }, + { + "time_epoch": 1729576800, + "time": "2024-10-22 02:00", + "temp_c": 15.3, + "temp_f": 59.5, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 5.1, + "wind_kph": 8.3, + "wind_degree": 233, + "wind_dir": "SW", + "pressure_mb": 1021.0, + "pressure_in": 30.16, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 88, + "cloud": 0, + "feelslike_c": 15.2, + "feelslike_f": 59.3, + "windchill_c": 15.2, + "windchill_f": 59.3, + "heatindex_c": 15.3, + "heatindex_f": 59.5, + "dewpoint_c": 13.2, + "dewpoint_f": 55.7, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.8, + "gust_kph": 17.4, + "uv": 0 + }, + { + "time_epoch": 1729580400, + "time": "2024-10-22 03:00", + "temp_c": 13.2, + "temp_f": 55.8, + "is_day": 0, + "condition": { + "text": "Clear", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 5.1, + "wind_kph": 8.3, + "wind_degree": 226, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.17, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 88, + "cloud": 0, + "feelslike_c": 14.6, + "feelslike_f": 58.2, + "windchill_c": 14.6, + "windchill_f": 58.2, + "heatindex_c": 14.8, + "heatindex_f": 58.6, + "dewpoint_c": 12.9, + "dewpoint_f": 55.2, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 14.0, + "vis_miles": 8.0, + "gust_mph": 10.8, + "gust_kph": 17.4, + "uv": 0 + }, + { + "time_epoch": 1729584000, + "time": "2024-10-22 04:00", + "temp_c": 14.3, + "temp_f": 57.7, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 5.1, + "wind_kph": 8.3, + "wind_degree": 227, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.17, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 89, + "cloud": 0, + "feelslike_c": 14.0, + "feelslike_f": 57.2, + "windchill_c": 14.0, + "windchill_f": 57.2, + "heatindex_c": 14.3, + "heatindex_f": 57.7, + "dewpoint_c": 12.6, + "dewpoint_f": 54.7, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.8, + "gust_kph": 17.4, + "uv": 0 + }, + { + "time_epoch": 1729587600, + "time": "2024-10-22 05:00", + "temp_c": 13.8, + "temp_f": 56.9, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 5.1, + "wind_kph": 8.3, + "wind_degree": 225, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.17, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 90, + "cloud": 1, + "feelslike_c": 13.5, + "feelslike_f": 56.3, + "windchill_c": 13.5, + "windchill_f": 56.3, + "heatindex_c": 13.8, + "heatindex_f": 56.9, + "dewpoint_c": 12.2, + "dewpoint_f": 54.0, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.8, + "gust_kph": 17.4, + "uv": 0 + }, + { + "time_epoch": 1729591200, + "time": "2024-10-22 06:00", + "temp_c": 13.4, + "temp_f": 56.2, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 5.1, + "wind_kph": 8.3, + "wind_degree": 228, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.18, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 91, + "cloud": 1, + "feelslike_c": 13.0, + "feelslike_f": 55.4, + "windchill_c": 13.0, + "windchill_f": 55.4, + "heatindex_c": 13.4, + "heatindex_f": 56.2, + "dewpoint_c": 12.0, + "dewpoint_f": 53.6, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.7, + "gust_kph": 17.2, + "uv": 0 + }, + { + "time_epoch": 1729594800, + "time": "2024-10-22 07:00", + "temp_c": 13.1, + "temp_f": 55.5, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 5.4, + "wind_kph": 8.6, + "wind_degree": 227, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.19, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 92, + "cloud": 7, + "feelslike_c": 12.5, + "feelslike_f": 54.5, + "windchill_c": 12.5, + "windchill_f": 54.5, + "heatindex_c": 13.1, + "heatindex_f": 55.5, + "dewpoint_c": 11.7, + "dewpoint_f": 53.1, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 11.1, + "gust_kph": 17.9, + "uv": 0 + }, + { + "time_epoch": 1729598400, + "time": "2024-10-22 08:00", + "temp_c": 13.0, + "temp_f": 55.5, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 5.8, + "wind_kph": 9.4, + "wind_degree": 224, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.19, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 92, + "cloud": 8, + "feelslike_c": 12.5, + "feelslike_f": 54.5, + "windchill_c": 12.5, + "windchill_f": 54.5, + "heatindex_c": 13.0, + "heatindex_f": 55.5, + "dewpoint_c": 11.5, + "dewpoint_f": 52.6, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 11.8, + "gust_kph": 18.9, + "uv": 0.0 + }, + { + "time_epoch": 1729602000, + "time": "2024-10-22 09:00", + "temp_c": 13.9, + "temp_f": 57.0, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 5.8, + "wind_kph": 9.4, + "wind_degree": 217, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.19, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 87, + "cloud": 11, + "feelslike_c": 13.5, + "feelslike_f": 56.3, + "windchill_c": 13.5, + "windchill_f": 56.3, + "heatindex_c": 13.9, + "heatindex_f": 57.0, + "dewpoint_c": 10.9, + "dewpoint_f": 51.7, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.5, + "gust_kph": 16.9, + "uv": 0.2 + }, + { + "time_epoch": 1729605600, + "time": "2024-10-22 10:00", + "temp_c": 16.0, + "temp_f": 60.9, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 6.9, + "wind_kph": 11.2, + "wind_degree": 219, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.19, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 76, + "cloud": 11, + "feelslike_c": 15.8, + "feelslike_f": 60.5, + "windchill_c": 15.8, + "windchill_f": 60.5, + "heatindex_c": 16.0, + "heatindex_f": 60.9, + "dewpoint_c": 10.5, + "dewpoint_f": 51.0, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.4, + "gust_kph": 16.7, + "uv": 0.8 + }, + { + "time_epoch": 1729609200, + "time": "2024-10-22 11:00", + "temp_c": 18.1, + "temp_f": 64.5, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 7.4, + "wind_kph": 11.9, + "wind_degree": 217, + "wind_dir": "SW", + "pressure_mb": 1022.0, + "pressure_in": 30.19, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 67, + "cloud": 4, + "feelslike_c": 18.0, + "feelslike_f": 64.4, + "windchill_c": 18.0, + "windchill_f": 64.4, + "heatindex_c": 18.1, + "heatindex_f": 64.5, + "dewpoint_c": 11.9, + "dewpoint_f": 53.5, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.3, + "gust_kph": 16.6, + "uv": 1.7 + }, + { + "time_epoch": 1729612800, + "time": "2024-10-22 12:00", + "temp_c": 19.5, + "temp_f": 67.2, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 7.6, + "wind_kph": 12.2, + "wind_degree": 213, + "wind_dir": "SSW", + "pressure_mb": 1022.0, + "pressure_in": 30.17, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 62, + "cloud": 3, + "feelslike_c": 19.5, + "feelslike_f": 67.1, + "windchill_c": 19.5, + "windchill_f": 67.1, + "heatindex_c": 19.5, + "heatindex_f": 67.2, + "dewpoint_c": 12.6, + "dewpoint_f": 54.8, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.7, + "gust_kph": 17.2, + "uv": 2.6 + }, + { + "time_epoch": 1729616400, + "time": "2024-10-22 13:00", + "temp_c": 20.4, + "temp_f": 68.7, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 7.6, + "wind_kph": 12.2, + "wind_degree": 208, + "wind_dir": "SSW", + "pressure_mb": 1021.0, + "pressure_in": 30.15, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 60, + "cloud": 4, + "feelslike_c": 20.4, + "feelslike_f": 68.7, + "windchill_c": 20.4, + "windchill_f": 68.7, + "heatindex_c": 22.0, + "heatindex_f": 71.6, + "dewpoint_c": 13.0, + "dewpoint_f": 55.5, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 11.4, + "gust_kph": 18.3, + "uv": 3.0 + }, + { + "time_epoch": 1729620000, + "time": "2024-10-22 14:00", + "temp_c": 21.3, + "temp_f": 70.3, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 8.3, + "wind_kph": 13.3, + "wind_degree": 202, + "wind_dir": "SSW", + "pressure_mb": 1020.0, + "pressure_in": 30.13, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 60, + "cloud": 10, + "feelslike_c": 21.2, + "feelslike_f": 70.2, + "windchill_c": 21.2, + "windchill_f": 70.2, + "heatindex_c": 23.3, + "heatindex_f": 73.9, + "dewpoint_c": 13.3, + "dewpoint_f": 55.9, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 12.9, + "gust_kph": 20.7, + "uv": 2.9 + }, + { + "time_epoch": 1729623600, + "time": "2024-10-22 15:00", + "temp_c": 21.5, + "temp_f": 70.8, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 9.4, + "wind_kph": 15.1, + "wind_degree": 192, + "wind_dir": "SSW", + "pressure_mb": 1020.0, + "pressure_in": 30.11, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 59, + "cloud": 8, + "feelslike_c": 21.5, + "feelslike_f": 70.7, + "windchill_c": 21.5, + "windchill_f": 70.7, + "heatindex_c": 23.9, + "heatindex_f": 75.0, + "dewpoint_c": 13.8, + "dewpoint_f": 56.8, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 15.2, + "gust_kph": 24.4, + "uv": 2.2 + }, + { + "time_epoch": 1729627200, + "time": "2024-10-22 16:00", + "temp_c": 21.6, + "temp_f": 70.8, + "is_day": 1, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/116.png", + "code": 1003 + }, + "wind_mph": 9.6, + "wind_kph": 15.5, + "wind_degree": 191, + "wind_dir": "SSW", + "pressure_mb": 1019.0, + "pressure_in": 30.09, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 59, + "cloud": 26, + "feelslike_c": 21.6, + "feelslike_f": 70.8, + "windchill_c": 21.6, + "windchill_f": 70.8, + "heatindex_c": 24.2, + "heatindex_f": 75.6, + "dewpoint_c": 13.4, + "dewpoint_f": 56.1, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 16.1, + "gust_kph": 25.9, + "uv": 1.3 + }, + { + "time_epoch": 1729630800, + "time": "2024-10-22 17:00", + "temp_c": 21.4, + "temp_f": 70.6, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 9.4, + "wind_kph": 15.1, + "wind_degree": 189, + "wind_dir": "S", + "pressure_mb": 1019.0, + "pressure_in": 30.08, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 61, + "cloud": 18, + "feelslike_c": 21.4, + "feelslike_f": 70.6, + "windchill_c": 21.4, + "windchill_f": 70.6, + "heatindex_c": 24.3, + "heatindex_f": 75.8, + "dewpoint_c": 13.8, + "dewpoint_f": 56.8, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 16.9, + "gust_kph": 27.3, + "uv": 0.5 + }, + { + "time_epoch": 1729634400, + "time": "2024-10-22 18:00", + "temp_c": 20.6, + "temp_f": 69.1, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 8.9, + "wind_kph": 14.4, + "wind_degree": 189, + "wind_dir": "S", + "pressure_mb": 1019.0, + "pressure_in": 30.08, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 67, + "cloud": 6, + "feelslike_c": 20.6, + "feelslike_f": 69.1, + "windchill_c": 20.6, + "windchill_f": 69.1, + "heatindex_c": 22.1, + "heatindex_f": 71.7, + "dewpoint_c": 15.0, + "dewpoint_f": 59.0, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 17.3, + "gust_kph": 27.9, + "uv": 0.0 + }, + { + "time_epoch": 1729638000, + "time": "2024-10-22 19:00", + "temp_c": 19.0, + "temp_f": 66.2, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 8.1, + "wind_kph": 13.0, + "wind_degree": 185, + "wind_dir": "S", + "pressure_mb": 1019.0, + "pressure_in": 30.08, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 73, + "cloud": 9, + "feelslike_c": 19.0, + "feelslike_f": 66.2, + "windchill_c": 19.0, + "windchill_f": 66.2, + "heatindex_c": 19.7, + "heatindex_f": 67.5, + "dewpoint_c": 14.8, + "dewpoint_f": 58.7, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 16.3, + "gust_kph": 26.3, + "uv": 0 + }, + { + "time_epoch": 1729641600, + "time": "2024-10-22 20:00", + "temp_c": 17.9, + "temp_f": 64.1, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 7.2, + "wind_kph": 11.5, + "wind_degree": 181, + "wind_dir": "S", + "pressure_mb": 1018.0, + "pressure_in": 30.07, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 75, + "cloud": 8, + "feelslike_c": 17.9, + "feelslike_f": 64.1, + "windchill_c": 17.9, + "windchill_f": 64.1, + "heatindex_c": 18.2, + "heatindex_f": 64.8, + "dewpoint_c": 13.0, + "dewpoint_f": 55.3, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 14.7, + "gust_kph": 23.6, + "uv": 0 + }, + { + "time_epoch": 1729645200, + "time": "2024-10-22 21:00", + "temp_c": 17.1, + "temp_f": 62.8, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 6.5, + "wind_kph": 10.4, + "wind_degree": 182, + "wind_dir": "S", + "pressure_mb": 1017.0, + "pressure_in": 30.04, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 79, + "cloud": 30, + "feelslike_c": 17.1, + "feelslike_f": 62.8, + "windchill_c": 17.1, + "windchill_f": 62.8, + "heatindex_c": 17.3, + "heatindex_f": 63.1, + "dewpoint_c": 12.9, + "dewpoint_f": 55.3, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 13.1, + "gust_kph": 21.1, + "uv": 0 + }, + { + "time_epoch": 1729648800, + "time": "2024-10-22 22:00", + "temp_c": 17.1, + "temp_f": 62.8, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 5.6, + "wind_kph": 9.0, + "wind_degree": 176, + "wind_dir": "S", + "pressure_mb": 1017.0, + "pressure_in": 30.03, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 80, + "cloud": 41, + "feelslike_c": 17.1, + "feelslike_f": 62.8, + "windchill_c": 17.1, + "windchill_f": 62.8, + "heatindex_c": 17.2, + "heatindex_f": 62.9, + "dewpoint_c": 12.9, + "dewpoint_f": 55.3, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 11.2, + "gust_kph": 18.0, + "uv": 0 + }, + { + "time_epoch": 1729652400, + "time": "2024-10-22 23:00", + "temp_c": 16.4, + "temp_f": 61.5, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 5.4, + "wind_kph": 8.6, + "wind_degree": 177, + "wind_dir": "S", + "pressure_mb": 1016.0, + "pressure_in": 29.99, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 58, + "cloud": 5, + "feelslike_c": 16.4, + "feelslike_f": 61.5, + "windchill_c": 16.4, + "windchill_f": 61.5, + "heatindex_c": 16.4, + "heatindex_f": 61.5, + "dewpoint_c": 8.9, + "dewpoint_f": 47.9, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.5, + "gust_kph": 17.0, + "uv": 0 + } + ] + }, + { + "date": "2024-10-23", + "date_epoch": 1729641600, + "day": { + "maxtemp_c": 20.1, + "maxtemp_f": 68.2, + "mintemp_c": 9.2, + "mintemp_f": 48.5, + "avgtemp_c": 15.5, + "avgtemp_f": 60.0, + "maxwind_mph": 18.1, + "maxwind_kph": 29.2, + "totalprecip_mm": 0.0, + "totalprecip_in": 0.0, + "totalsnow_cm": 0.0, + "avgvis_km": 10.0, + "avgvis_miles": 6.0, + "avghumidity": 71, + "daily_will_it_rain": 0, + "daily_chance_of_rain": 0, + "daily_will_it_snow": 0, + "daily_chance_of_snow": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/116.png", + "code": 1003 + }, + "uv": 0.5 + }, + "astro": { + "sunrise": "07:43 AM", + "sunset": "06:20 PM", + "moonrise": "11:29 PM", + "moonset": "02:47 PM", + "moon_phase": "Waning Gibbous", + "moon_illumination": 64, + "is_moon_up": 0, + "is_sun_up": 0 + }, + "hour": [ + { + "time_epoch": 1729656000, + "time": "2024-10-23 00:00", + "temp_c": 15.9, + "temp_f": 60.7, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 6.7, + "wind_kph": 10.8, + "wind_degree": 194, + "wind_dir": "SSW", + "pressure_mb": 1015.0, + "pressure_in": 29.98, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 80, + "cloud": 51, + "feelslike_c": 15.9, + "feelslike_f": 60.7, + "windchill_c": 15.9, + "windchill_f": 60.7, + "heatindex_c": 15.9, + "heatindex_f": 60.7, + "dewpoint_c": 12.2, + "dewpoint_f": 54.0, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 12.7, + "gust_kph": 20.4, + "uv": 0 + }, + { + "time_epoch": 1729659600, + "time": "2024-10-23 01:00", + "temp_c": 15.6, + "temp_f": 60.1, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 9.4, + "wind_kph": 15.1, + "wind_degree": 204, + "wind_dir": "SSW", + "pressure_mb": 1015.0, + "pressure_in": 29.96, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 79, + "cloud": 50, + "feelslike_c": 15.6, + "feelslike_f": 60.1, + "windchill_c": 15.6, + "windchill_f": 60.1, + "heatindex_c": 15.6, + "heatindex_f": 60.1, + "dewpoint_c": 11.9, + "dewpoint_f": 53.4, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 17.3, + "gust_kph": 27.9, + "uv": 0 + }, + { + "time_epoch": 1729663200, + "time": "2024-10-23 02:00", + "temp_c": 15.4, + "temp_f": 59.6, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 10.1, + "wind_kph": 16.2, + "wind_degree": 209, + "wind_dir": "SSW", + "pressure_mb": 1014.0, + "pressure_in": 29.95, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 78, + "cloud": 49, + "feelslike_c": 15.0, + "feelslike_f": 59.0, + "windchill_c": 15.0, + "windchill_f": 59.0, + "heatindex_c": 15.4, + "heatindex_f": 59.6, + "dewpoint_c": 11.5, + "dewpoint_f": 52.8, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 18.2, + "gust_kph": 29.3, + "uv": 0 + }, + { + "time_epoch": 1729666800, + "time": "2024-10-23 03:00", + "temp_c": 15.2, + "temp_f": 59.3, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 11.2, + "wind_kph": 18.0, + "wind_degree": 210, + "wind_dir": "SSW", + "pressure_mb": 1013.0, + "pressure_in": 29.92, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 78, + "cloud": 29, + "feelslike_c": 14.5, + "feelslike_f": 58.0, + "windchill_c": 14.5, + "windchill_f": 58.0, + "heatindex_c": 15.2, + "heatindex_f": 59.3, + "dewpoint_c": 11.3, + "dewpoint_f": 52.3, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 19.4, + "gust_kph": 31.2, + "uv": 0 + }, + { + "time_epoch": 1729670400, + "time": "2024-10-23 04:00", + "temp_c": 15.0, + "temp_f": 59.1, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 12.1, + "wind_kph": 19.4, + "wind_degree": 208, + "wind_dir": "SSW", + "pressure_mb": 1013.0, + "pressure_in": 29.9, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 78, + "cloud": 19, + "feelslike_c": 14.0, + "feelslike_f": 57.1, + "windchill_c": 14.0, + "windchill_f": 57.1, + "heatindex_c": 15.0, + "heatindex_f": 59.1, + "dewpoint_c": 11.2, + "dewpoint_f": 52.1, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 20.6, + "gust_kph": 33.1, + "uv": 0 + }, + { + "time_epoch": 1729674000, + "time": "2024-10-23 05:00", + "temp_c": 15.0, + "temp_f": 59.1, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 12.8, + "wind_kph": 20.5, + "wind_degree": 212, + "wind_dir": "SSW", + "pressure_mb": 1012.0, + "pressure_in": 29.88, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 78, + "cloud": 9, + "feelslike_c": 14.1, + "feelslike_f": 57.4, + "windchill_c": 14.1, + "windchill_f": 57.4, + "heatindex_c": 15.0, + "heatindex_f": 59.1, + "dewpoint_c": 11.1, + "dewpoint_f": 51.9, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 20.8, + "gust_kph": 33.6, + "uv": 0 + }, + { + "time_epoch": 1729677600, + "time": "2024-10-23 06:00", + "temp_c": 15.1, + "temp_f": 59.2, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 13.4, + "wind_kph": 21.6, + "wind_degree": 210, + "wind_dir": "SSW", + "pressure_mb": 1011.0, + "pressure_in": 29.86, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 80, + "cloud": 19, + "feelslike_c": 14.5, + "feelslike_f": 58.0, + "windchill_c": 14.5, + "windchill_f": 58.0, + "heatindex_c": 15.1, + "heatindex_f": 59.2, + "dewpoint_c": 11.6, + "dewpoint_f": 52.8, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 21.6, + "gust_kph": 34.8, + "uv": 0 + }, + { + "time_epoch": 1729681200, + "time": "2024-10-23 07:00", + "temp_c": 15.1, + "temp_f": 59.3, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 14.3, + "wind_kph": 23.0, + "wind_degree": 213, + "wind_dir": "SSW", + "pressure_mb": 1011.0, + "pressure_in": 29.84, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 81, + "cloud": 25, + "feelslike_c": 14.8, + "feelslike_f": 58.7, + "windchill_c": 14.8, + "windchill_f": 58.7, + "heatindex_c": 15.1, + "heatindex_f": 59.3, + "dewpoint_c": 11.8, + "dewpoint_f": 53.3, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 22.7, + "gust_kph": 36.6, + "uv": 0 + }, + { + "time_epoch": 1729684800, + "time": "2024-10-23 08:00", + "temp_c": 15.8, + "temp_f": 60.4, + "is_day": 1, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/116.png", + "code": 1003 + }, + "wind_mph": 15.0, + "wind_kph": 24.1, + "wind_degree": 218, + "wind_dir": "SW", + "pressure_mb": 1010.0, + "pressure_in": 29.83, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 81, + "cloud": 30, + "feelslike_c": 15.6, + "feelslike_f": 60.1, + "windchill_c": 15.6, + "windchill_f": 60.1, + "heatindex_c": 15.8, + "heatindex_f": 60.4, + "dewpoint_c": 12.1, + "dewpoint_f": 53.7, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 23.1, + "gust_kph": 37.1, + "uv": 0.0 + }, + { + "time_epoch": 1729688400, + "time": "2024-10-23 09:00", + "temp_c": 16.4, + "temp_f": 61.5, + "is_day": 1, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/116.png", + "code": 1003 + }, + "wind_mph": 15.4, + "wind_kph": 24.8, + "wind_degree": 219, + "wind_dir": "SW", + "pressure_mb": 1009.0, + "pressure_in": 29.81, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 77, + "cloud": 47, + "feelslike_c": 16.3, + "feelslike_f": 61.4, + "windchill_c": 16.3, + "windchill_f": 61.4, + "heatindex_c": 16.4, + "heatindex_f": 61.5, + "dewpoint_c": 12.3, + "dewpoint_f": 54.2, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 22.9, + "gust_kph": 36.8, + "uv": 0.2 + }, + { + "time_epoch": 1729692000, + "time": "2024-10-23 10:00", + "temp_c": 17.0, + "temp_f": 62.6, + "is_day": 1, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/116.png", + "code": 1003 + }, + "wind_mph": 16.1, + "wind_kph": 25.9, + "wind_degree": 222, + "wind_dir": "SW", + "pressure_mb": 1009.0, + "pressure_in": 29.79, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 75, + "cloud": 55, + "feelslike_c": 17.0, + "feelslike_f": 62.5, + "windchill_c": 17.0, + "windchill_f": 62.5, + "heatindex_c": 17.0, + "heatindex_f": 62.6, + "dewpoint_c": 12.5, + "dewpoint_f": 54.4, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 22.4, + "gust_kph": 36.1, + "uv": 0.7 + }, + { + "time_epoch": 1729695600, + "time": "2024-10-23 11:00", + "temp_c": 17.9, + "temp_f": 64.3, + "is_day": 1, + "condition": { + "text": "Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/119.png", + "code": 1006 + }, + "wind_mph": 15.9, + "wind_kph": 25.6, + "wind_degree": 227, + "wind_dir": "SW", + "pressure_mb": 1009.0, + "pressure_in": 29.78, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 72, + "cloud": 63, + "feelslike_c": 17.9, + "feelslike_f": 64.2, + "windchill_c": 17.9, + "windchill_f": 64.2, + "heatindex_c": 17.9, + "heatindex_f": 64.3, + "dewpoint_c": 12.6, + "dewpoint_f": 54.7, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 21.5, + "gust_kph": 34.6, + "uv": 1.3 + }, + { + "time_epoch": 1729699200, + "time": "2024-10-23 12:00", + "temp_c": 18.7, + "temp_f": 65.7, + "is_day": 1, + "condition": { + "text": "Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/119.png", + "code": 1006 + }, + "wind_mph": 15.2, + "wind_kph": 24.5, + "wind_degree": 239, + "wind_dir": "WSW", + "pressure_mb": 1008.0, + "pressure_in": 29.76, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 67, + "cloud": 58, + "feelslike_c": 18.7, + "feelslike_f": 65.6, + "windchill_c": 18.7, + "windchill_f": 65.6, + "heatindex_c": 18.7, + "heatindex_f": 65.7, + "dewpoint_c": 12.7, + "dewpoint_f": 54.8, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 20.7, + "gust_kph": 33.4, + "uv": 1.9 + }, + { + "time_epoch": 1729702800, + "time": "2024-10-23 13:00", + "temp_c": 19.4, + "temp_f": 66.9, + "is_day": 1, + "condition": { + "text": "Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/119.png", + "code": 1006 + }, + "wind_mph": 15.0, + "wind_kph": 24.1, + "wind_degree": 246, + "wind_dir": "WSW", + "pressure_mb": 1007.0, + "pressure_in": 29.74, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 65, + "cloud": 55, + "feelslike_c": 19.4, + "feelslike_f": 66.9, + "windchill_c": 19.4, + "windchill_f": 66.9, + "heatindex_c": 19.4, + "heatindex_f": 66.9, + "dewpoint_c": 12.7, + "dewpoint_f": 54.8, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 20.8, + "gust_kph": 33.4, + "uv": 2.3 + }, + { + "time_epoch": 1729706400, + "time": "2024-10-23 14:00", + "temp_c": 18.9, + "temp_f": 66.1, + "is_day": 1, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/116.png", + "code": 1003 + }, + "wind_mph": 15.7, + "wind_kph": 25.2, + "wind_degree": 263, + "wind_dir": "W", + "pressure_mb": 1007.0, + "pressure_in": 29.73, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 62, + "cloud": 52, + "feelslike_c": 18.9, + "feelslike_f": 66.1, + "windchill_c": 18.9, + "windchill_f": 66.1, + "heatindex_c": 18.9, + "heatindex_f": 66.1, + "dewpoint_c": 12.7, + "dewpoint_f": 54.9, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 20.9, + "gust_kph": 33.7, + "uv": 2.2 + }, + { + "time_epoch": 1729710000, + "time": "2024-10-23 15:00", + "temp_c": 18.3, + "temp_f": 65.0, + "is_day": 1, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/116.png", + "code": 1003 + }, + "wind_mph": 17.0, + "wind_kph": 27.4, + "wind_degree": 285, + "wind_dir": "WNW", + "pressure_mb": 1008.0, + "pressure_in": 29.77, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 63, + "cloud": 75, + "feelslike_c": 18.3, + "feelslike_f": 65.0, + "windchill_c": 18.3, + "windchill_f": 65.0, + "heatindex_c": 18.3, + "heatindex_f": 65.0, + "dewpoint_c": 11.4, + "dewpoint_f": 52.6, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 21.0, + "gust_kph": 33.8, + "uv": 1.6 + }, + { + "time_epoch": 1729713600, + "time": "2024-10-23 16:00", + "temp_c": 17.6, + "temp_f": 63.7, + "is_day": 1, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/116.png", + "code": 1003 + }, + "wind_mph": 17.7, + "wind_kph": 28.4, + "wind_degree": 302, + "wind_dir": "WNW", + "pressure_mb": 1009.0, + "pressure_in": 29.79, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 64, + "cloud": 86, + "feelslike_c": 17.6, + "feelslike_f": 63.7, + "windchill_c": 17.6, + "windchill_f": 63.7, + "heatindex_c": 17.6, + "heatindex_f": 63.7, + "dewpoint_c": 10.8, + "dewpoint_f": 51.4, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 21.2, + "gust_kph": 34.1, + "uv": 0.9 + }, + { + "time_epoch": 1729717200, + "time": "2024-10-23 17:00", + "temp_c": 15.9, + "temp_f": 60.6, + "is_day": 1, + "condition": { + "text": "Overcast ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/122.png", + "code": 1009 + }, + "wind_mph": 17.0, + "wind_kph": 27.4, + "wind_degree": 305, + "wind_dir": "NW", + "pressure_mb": 1009.0, + "pressure_in": 29.81, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 64, + "cloud": 97, + "feelslike_c": 15.1, + "feelslike_f": 59.2, + "windchill_c": 15.1, + "windchill_f": 59.2, + "heatindex_c": 15.9, + "heatindex_f": 60.6, + "dewpoint_c": 10.2, + "dewpoint_f": 50.3, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 19.8, + "gust_kph": 31.8, + "uv": 0.4 + }, + { + "time_epoch": 1729720800, + "time": "2024-10-23 18:00", + "temp_c": 14.3, + "temp_f": 57.8, + "is_day": 1, + "condition": { + "text": "Overcast ", + "icon": "//cdn.weatherapi.com/weather/64x64/day/122.png", + "code": 1009 + }, + "wind_mph": 16.1, + "wind_kph": 25.9, + "wind_degree": 304, + "wind_dir": "NW", + "pressure_mb": 1012.0, + "pressure_in": 29.88, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 63, + "cloud": 58, + "feelslike_c": 12.7, + "feelslike_f": 54.9, + "windchill_c": 12.7, + "windchill_f": 54.9, + "heatindex_c": 14.3, + "heatindex_f": 57.8, + "dewpoint_c": 7.2, + "dewpoint_f": 45.0, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 19.6, + "gust_kph": 31.5, + "uv": 0.0 + }, + { + "time_epoch": 1729724400, + "time": "2024-10-23 19:00", + "temp_c": 12.9, + "temp_f": 55.2, + "is_day": 0, + "condition": { + "text": "Overcast ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/122.png", + "code": 1009 + }, + "wind_mph": 18.1, + "wind_kph": 29.2, + "wind_degree": 308, + "wind_dir": "NW", + "pressure_mb": 1013.0, + "pressure_in": 29.91, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 62, + "cloud": 39, + "feelslike_c": 10.5, + "feelslike_f": 50.9, + "windchill_c": 10.5, + "windchill_f": 50.9, + "heatindex_c": 12.9, + "heatindex_f": 55.2, + "dewpoint_c": 5.7, + "dewpoint_f": 42.3, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 21.6, + "gust_kph": 34.7, + "uv": 0 + }, + { + "time_epoch": 1729728000, + "time": "2024-10-23 20:00", + "temp_c": 11.4, + "temp_f": 52.5, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 17.4, + "wind_kph": 28.1, + "wind_degree": 304, + "wind_dir": "NW", + "pressure_mb": 1014.0, + "pressure_in": 29.95, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 61, + "cloud": 19, + "feelslike_c": 8.3, + "feelslike_f": 47.0, + "windchill_c": 8.3, + "windchill_f": 47.0, + "heatindex_c": 11.4, + "heatindex_f": 52.5, + "dewpoint_c": 4.3, + "dewpoint_f": 39.7, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 21.5, + "gust_kph": 34.6, + "uv": 0 + }, + { + "time_epoch": 1729731600, + "time": "2024-10-23 21:00", + "temp_c": 10.3, + "temp_f": 50.5, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 17.0, + "wind_kph": 27.4, + "wind_degree": 308, + "wind_dir": "NW", + "pressure_mb": 1016.0, + "pressure_in": 29.99, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 61, + "cloud": 10, + "feelslike_c": 6.8, + "feelslike_f": 44.2, + "windchill_c": 6.8, + "windchill_f": 44.2, + "heatindex_c": 10.3, + "heatindex_f": 50.5, + "dewpoint_c": 2.7, + "dewpoint_f": 36.9, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 21.3, + "gust_kph": 34.3, + "uv": 0 + }, + { + "time_epoch": 1729735200, + "time": "2024-10-23 22:00", + "temp_c": 13.1, + "temp_f": 55.6, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 15.9, + "wind_kph": 25.6, + "wind_degree": 310, + "wind_dir": "NW", + "pressure_mb": 1017.0, + "pressure_in": 30.02, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 61, + "cloud": 5, + "feelslike_c": 11.4, + "feelslike_f": 52.5, + "windchill_c": 11.4, + "windchill_f": 52.5, + "heatindex_c": 13.1, + "heatindex_f": 55.6, + "dewpoint_c": 2.0, + "dewpoint_f": 35.5, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 19.7, + "gust_kph": 31.8, + "uv": 0 + }, + { + "time_epoch": 1729738800, + "time": "2024-10-23 23:00", + "temp_c": 10.5, + "temp_f": 51.0, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 14.3, + "wind_kph": 23.0, + "wind_degree": 311, + "wind_dir": "NW", + "pressure_mb": 1016.0, + "pressure_in": 30.01, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 82, + "cloud": 52, + "feelslike_c": 7.6, + "feelslike_f": 45.7, + "windchill_c": 7.6, + "windchill_f": 45.7, + "heatindex_c": 10.5, + "heatindex_f": 51.0, + "dewpoint_c": 12.9, + "dewpoint_f": 55.2, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 18.3, + "gust_kph": 29.4, + "uv": 0 + } + ] + }, + { + "date": "2024-10-24", + "date_epoch": 1729728000, + "day": { + "maxtemp_c": 12.3, + "maxtemp_f": 54.1, + "mintemp_c": 4.5, + "mintemp_f": 40.1, + "avgtemp_c": 8.6, + "avgtemp_f": 47.5, + "maxwind_mph": 13.2, + "maxwind_kph": 21.2, + "totalprecip_mm": 0.0, + "totalprecip_in": 0.0, + "totalsnow_cm": 0.0, + "avgvis_km": 10.0, + "avgvis_miles": 6.0, + "avghumidity": 55, + "daily_will_it_rain": 0, + "daily_chance_of_rain": 0, + "daily_will_it_snow": 0, + "daily_chance_of_snow": 0, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "uv": 0.6 + }, + "astro": { + "sunrise": "07:44 AM", + "sunset": "06:19 PM", + "moonrise": "No moonrise", + "moonset": "03:21 PM", + "moon_phase": "Last Quarter", + "moon_illumination": 53, + "is_moon_up": 0, + "is_sun_up": 0 + }, + "hour": [ + { + "time_epoch": 1729742400, + "time": "2024-10-24 00:00", + "temp_c": 9.1, + "temp_f": 48.4, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 13.2, + "wind_kph": 21.2, + "wind_degree": 311, + "wind_dir": "NW", + "pressure_mb": 1018.0, + "pressure_in": 30.06, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 62, + "cloud": 18, + "feelslike_c": 5.6, + "feelslike_f": 42.2, + "windchill_c": 5.6, + "windchill_f": 42.2, + "heatindex_c": 9.1, + "heatindex_f": 48.4, + "dewpoint_c": 1.1, + "dewpoint_f": 33.9, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 16.9, + "gust_kph": 27.2, + "uv": 0 + }, + { + "time_epoch": 1729746000, + "time": "2024-10-24 01:00", + "temp_c": 8.3, + "temp_f": 47.0, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 11.9, + "wind_kph": 19.1, + "wind_degree": 312, + "wind_dir": "NW", + "pressure_mb": 1018.0, + "pressure_in": 30.07, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 62, + "cloud": 27, + "feelslike_c": 4.6, + "feelslike_f": 40.3, + "windchill_c": 4.6, + "windchill_f": 40.3, + "heatindex_c": 8.3, + "heatindex_f": 47.0, + "dewpoint_c": 1.0, + "dewpoint_f": 33.8, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 15.2, + "gust_kph": 24.4, + "uv": 0 + }, + { + "time_epoch": 1729749600, + "time": "2024-10-24 02:00", + "temp_c": 7.7, + "temp_f": 45.9, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 10.5, + "wind_kph": 16.9, + "wind_degree": 311, + "wind_dir": "NW", + "pressure_mb": 1018.0, + "pressure_in": 30.07, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 63, + "cloud": 36, + "feelslike_c": 4.0, + "feelslike_f": 39.2, + "windchill_c": 4.0, + "windchill_f": 39.2, + "heatindex_c": 7.7, + "heatindex_f": 45.9, + "dewpoint_c": 1.0, + "dewpoint_f": 33.7, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 13.5, + "gust_kph": 21.8, + "uv": 0 + }, + { + "time_epoch": 1729753200, + "time": "2024-10-24 03:00", + "temp_c": 7.4, + "temp_f": 45.2, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 9.8, + "wind_kph": 15.8, + "wind_degree": 309, + "wind_dir": "NW", + "pressure_mb": 1020.0, + "pressure_in": 30.11, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 64, + "cloud": 55, + "feelslike_c": 3.7, + "feelslike_f": 38.6, + "windchill_c": 3.7, + "windchill_f": 38.6, + "heatindex_c": 7.4, + "heatindex_f": 45.2, + "dewpoint_c": 0.9, + "dewpoint_f": 33.6, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 12.9, + "gust_kph": 20.7, + "uv": 0 + }, + { + "time_epoch": 1729756800, + "time": "2024-10-24 04:00", + "temp_c": 7.1, + "temp_f": 44.7, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 8.9, + "wind_kph": 14.4, + "wind_degree": 319, + "wind_dir": "NW", + "pressure_mb": 1020.0, + "pressure_in": 30.13, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 65, + "cloud": 64, + "feelslike_c": 3.5, + "feelslike_f": 38.3, + "windchill_c": 3.5, + "windchill_f": 38.3, + "heatindex_c": 7.1, + "heatindex_f": 44.7, + "dewpoint_c": 0.8, + "dewpoint_f": 33.5, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 11.7, + "gust_kph": 18.9, + "uv": 0 + }, + { + "time_epoch": 1729760400, + "time": "2024-10-24 05:00", + "temp_c": 6.4, + "temp_f": 43.5, + "is_day": 0, + "condition": { + "text": "Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/119.png", + "code": 1006 + }, + "wind_mph": 8.1, + "wind_kph": 13.0, + "wind_degree": 338, + "wind_dir": "NNW", + "pressure_mb": 1021.0, + "pressure_in": 30.15, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 65, + "cloud": 73, + "feelslike_c": 2.8, + "feelslike_f": 37.1, + "windchill_c": 2.8, + "windchill_f": 37.1, + "heatindex_c": 6.4, + "heatindex_f": 43.5, + "dewpoint_c": 0.8, + "dewpoint_f": 33.4, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.5, + "gust_kph": 17.0, + "uv": 0 + }, + { + "time_epoch": 1729764000, + "time": "2024-10-24 06:00", + "temp_c": 5.7, + "temp_f": 42.3, + "is_day": 0, + "condition": { + "text": "Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/119.png", + "code": 1006 + }, + "wind_mph": 6.7, + "wind_kph": 10.8, + "wind_degree": 355, + "wind_dir": "N", + "pressure_mb": 1022.0, + "pressure_in": 30.19, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 64, + "cloud": 39, + "feelslike_c": 2.2, + "feelslike_f": 35.9, + "windchill_c": 2.2, + "windchill_f": 35.9, + "heatindex_c": 5.7, + "heatindex_f": 42.3, + "dewpoint_c": -0.5, + "dewpoint_f": 31.1, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 8.8, + "gust_kph": 14.2, + "uv": 0 + }, + { + "time_epoch": 1729767600, + "time": "2024-10-24 07:00", + "temp_c": 5.1, + "temp_f": 41.2, + "is_day": 0, + "condition": { + "text": "Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/119.png", + "code": 1006 + }, + "wind_mph": 7.6, + "wind_kph": 12.2, + "wind_degree": 356, + "wind_dir": "N", + "pressure_mb": 1023.0, + "pressure_in": 30.21, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 64, + "cloud": 22, + "feelslike_c": 1.6, + "feelslike_f": 34.8, + "windchill_c": 1.6, + "windchill_f": 34.8, + "heatindex_c": 5.1, + "heatindex_f": 41.2, + "dewpoint_c": -1.2, + "dewpoint_f": 29.9, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.0, + "gust_kph": 16.1, + "uv": 0 + }, + { + "time_epoch": 1729771200, + "time": "2024-10-24 08:00", + "temp_c": 5.8, + "temp_f": 42.4, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 8.5, + "wind_kph": 13.7, + "wind_degree": 356, + "wind_dir": "N", + "pressure_mb": 1024.0, + "pressure_in": 30.23, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 63, + "cloud": 5, + "feelslike_c": 2.6, + "feelslike_f": 36.7, + "windchill_c": 2.6, + "windchill_f": 36.7, + "heatindex_c": 5.8, + "heatindex_f": 42.4, + "dewpoint_c": -1.8, + "dewpoint_f": 28.7, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 11.1, + "gust_kph": 17.8, + "uv": 0.0 + }, + { + "time_epoch": 1729774800, + "time": "2024-10-24 09:00", + "temp_c": 6.7, + "temp_f": 44.0, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 8.3, + "wind_kph": 13.3, + "wind_degree": 359, + "wind_dir": "N", + "pressure_mb": 1024.0, + "pressure_in": 30.24, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 54, + "cloud": 2, + "feelslike_c": 3.9, + "feelslike_f": 38.9, + "windchill_c": 3.9, + "windchill_f": 38.9, + "heatindex_c": 6.7, + "heatindex_f": 44.0, + "dewpoint_c": -2.5, + "dewpoint_f": 27.6, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.3, + "gust_kph": 16.5, + "uv": 0.2 + }, + { + "time_epoch": 1729778400, + "time": "2024-10-24 10:00", + "temp_c": 7.6, + "temp_f": 45.6, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 5.4, + "wind_kph": 8.6, + "wind_degree": 3, + "wind_dir": "N", + "pressure_mb": 1024.0, + "pressure_in": 30.24, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 49, + "cloud": 1, + "feelslike_c": 5.2, + "feelslike_f": 41.3, + "windchill_c": 5.2, + "windchill_f": 41.3, + "heatindex_c": 7.6, + "heatindex_f": 45.6, + "dewpoint_c": -2.8, + "dewpoint_f": 27.0, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 6.4, + "gust_kph": 10.2, + "uv": 0.8 + }, + { + "time_epoch": 1729782000, + "time": "2024-10-24 11:00", + "temp_c": 8.8, + "temp_f": 47.8, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 2.7, + "wind_kph": 4.3, + "wind_degree": 343, + "wind_dir": "NNW", + "pressure_mb": 1024.0, + "pressure_in": 30.24, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 44, + "cloud": 0, + "feelslike_c": 6.8, + "feelslike_f": 44.2, + "windchill_c": 6.8, + "windchill_f": 44.2, + "heatindex_c": 8.8, + "heatindex_f": 47.8, + "dewpoint_c": -3.1, + "dewpoint_f": 26.4, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 3.1, + "gust_kph": 5.0, + "uv": 1.6 + }, + { + "time_epoch": 1729785600, + "time": "2024-10-24 12:00", + "temp_c": 9.7, + "temp_f": 49.5, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 2.0, + "wind_kph": 3.2, + "wind_degree": 299, + "wind_dir": "WNW", + "pressure_mb": 1023.0, + "pressure_in": 30.22, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 41, + "cloud": 0, + "feelslike_c": 8.1, + "feelslike_f": 46.5, + "windchill_c": 8.1, + "windchill_f": 46.5, + "heatindex_c": 9.7, + "heatindex_f": 49.5, + "dewpoint_c": -2.5, + "dewpoint_f": 27.5, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 2.3, + "gust_kph": 3.7, + "uv": 2.4 + }, + { + "time_epoch": 1729789200, + "time": "2024-10-24 13:00", + "temp_c": 10.6, + "temp_f": 51.0, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 3.6, + "wind_kph": 5.8, + "wind_degree": 263, + "wind_dir": "W", + "pressure_mb": 1023.0, + "pressure_in": 30.21, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 40, + "cloud": 0, + "feelslike_c": 9.2, + "feelslike_f": 48.6, + "windchill_c": 9.2, + "windchill_f": 48.6, + "heatindex_c": 10.6, + "heatindex_f": 51.0, + "dewpoint_c": -2.2, + "dewpoint_f": 28.0, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 4.1, + "gust_kph": 6.6, + "uv": 2.9 + }, + { + "time_epoch": 1729792800, + "time": "2024-10-24 14:00", + "temp_c": 11.2, + "temp_f": 52.2, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 3.6, + "wind_kph": 5.8, + "wind_degree": 252, + "wind_dir": "WSW", + "pressure_mb": 1023.0, + "pressure_in": 30.2, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 39, + "cloud": 0, + "feelslike_c": 10.2, + "feelslike_f": 50.4, + "windchill_c": 10.2, + "windchill_f": 50.4, + "heatindex_c": 11.2, + "heatindex_f": 52.2, + "dewpoint_c": -1.9, + "dewpoint_f": 28.5, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 4.1, + "gust_kph": 6.6, + "uv": 2.7 + }, + { + "time_epoch": 1729796400, + "time": "2024-10-24 15:00", + "temp_c": 11.6, + "temp_f": 53.0, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 3.4, + "wind_kph": 5.4, + "wind_degree": 205, + "wind_dir": "SSW", + "pressure_mb": 1022.0, + "pressure_in": 30.19, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 43, + "cloud": 0, + "feelslike_c": 11.0, + "feelslike_f": 51.8, + "windchill_c": 11.0, + "windchill_f": 51.8, + "heatindex_c": 11.6, + "heatindex_f": 53.0, + "dewpoint_c": -0.4, + "dewpoint_f": 31.2, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 3.9, + "gust_kph": 6.2, + "uv": 2.1 + }, + { + "time_epoch": 1729800000, + "time": "2024-10-24 16:00", + "temp_c": 12.0, + "temp_f": 53.5, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 4.7, + "wind_kph": 7.6, + "wind_degree": 181, + "wind_dir": "S", + "pressure_mb": 1022.0, + "pressure_in": 30.18, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 44, + "cloud": 0, + "feelslike_c": 11.6, + "feelslike_f": 52.8, + "windchill_c": 11.6, + "windchill_f": 52.8, + "heatindex_c": 12.0, + "heatindex_f": 53.5, + "dewpoint_c": 0.3, + "dewpoint_f": 32.6, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 5.5, + "gust_kph": 8.9, + "uv": 1.2 + }, + { + "time_epoch": 1729803600, + "time": "2024-10-24 17:00", + "temp_c": 11.2, + "temp_f": 52.1, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 5.8, + "wind_kph": 9.4, + "wind_degree": 170, + "wind_dir": "S", + "pressure_mb": 1022.0, + "pressure_in": 30.18, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 46, + "cloud": 0, + "feelslike_c": 10.8, + "feelslike_f": 51.4, + "windchill_c": 10.8, + "windchill_f": 51.4, + "heatindex_c": 11.2, + "heatindex_f": 52.1, + "dewpoint_c": 1.1, + "dewpoint_f": 33.9, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 7.4, + "gust_kph": 12.0, + "uv": 0.5 + }, + { + "time_epoch": 1729807200, + "time": "2024-10-24 18:00", + "temp_c": 10.3, + "temp_f": 50.6, + "is_day": 1, + "condition": { + "text": "Sunny", + "icon": "//cdn.weatherapi.com/weather/64x64/day/113.png", + "code": 1000 + }, + "wind_mph": 6.9, + "wind_kph": 11.2, + "wind_degree": 165, + "wind_dir": "SSE", + "pressure_mb": 1022.0, + "pressure_in": 30.18, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 53, + "cloud": 2, + "feelslike_c": 9.8, + "feelslike_f": 49.6, + "windchill_c": 9.8, + "windchill_f": 49.6, + "heatindex_c": 10.3, + "heatindex_f": 50.6, + "dewpoint_c": 1.2, + "dewpoint_f": 34.1, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 9.3, + "gust_kph": 15.0, + "uv": 0.0 + }, + { + "time_epoch": 1729810800, + "time": "2024-10-24 19:00", + "temp_c": 9.4, + "temp_f": 48.9, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 6.0, + "wind_kph": 9.7, + "wind_degree": 171, + "wind_dir": "S", + "pressure_mb": 1022.0, + "pressure_in": 30.19, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 57, + "cloud": 4, + "feelslike_c": 8.8, + "feelslike_f": 47.8, + "windchill_c": 8.8, + "windchill_f": 47.8, + "heatindex_c": 9.4, + "heatindex_f": 48.9, + "dewpoint_c": 1.2, + "dewpoint_f": 34.2, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 8.2, + "gust_kph": 13.2, + "uv": 0 + }, + { + "time_epoch": 1729814400, + "time": "2024-10-24 20:00", + "temp_c": 9.8, + "temp_f": 49.6, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 6.9, + "wind_kph": 11.2, + "wind_degree": 178, + "wind_dir": "S", + "pressure_mb": 1022.0, + "pressure_in": 30.19, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 60, + "cloud": 5, + "feelslike_c": 8.6, + "feelslike_f": 47.5, + "windchill_c": 8.6, + "windchill_f": 47.5, + "heatindex_c": 9.8, + "heatindex_f": 49.6, + "dewpoint_c": 1.3, + "dewpoint_f": 34.3, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 9.7, + "gust_kph": 15.6, + "uv": 0 + }, + { + "time_epoch": 1729818000, + "time": "2024-10-24 21:00", + "temp_c": 9.9, + "temp_f": 49.8, + "is_day": 0, + "condition": { + "text": "Partly Cloudy ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/116.png", + "code": 1003 + }, + "wind_mph": 7.6, + "wind_kph": 12.2, + "wind_degree": 189, + "wind_dir": "S", + "pressure_mb": 1022.0, + "pressure_in": 30.18, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 55, + "cloud": 42, + "feelslike_c": 8.5, + "feelslike_f": 47.3, + "windchill_c": 8.5, + "windchill_f": 47.3, + "heatindex_c": 9.9, + "heatindex_f": 49.8, + "dewpoint_c": 1.6, + "dewpoint_f": 34.8, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.8, + "gust_kph": 17.4, + "uv": 0 + }, + { + "time_epoch": 1729821600, + "time": "2024-10-24 22:00", + "temp_c": 9.2, + "temp_f": 48.5, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 7.2, + "wind_kph": 11.5, + "wind_degree": 201, + "wind_dir": "SSW", + "pressure_mb": 1022.0, + "pressure_in": 30.18, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 59, + "cloud": 5, + "feelslike_c": 6.3, + "feelslike_f": 43.4, + "windchill_c": 6.3, + "windchill_f": 43.4, + "heatindex_c": 9.2, + "heatindex_f": 48.5, + "dewpoint_c": 2.5, + "dewpoint_f": 36.4, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 10.2, + "gust_kph": 16.4, + "uv": 0 + }, + { + "time_epoch": 1729825200, + "time": "2024-10-24 23:00", + "temp_c": 9.3, + "temp_f": 48.7, + "is_day": 0, + "condition": { + "text": "Clear ", + "icon": "//cdn.weatherapi.com/weather/64x64/night/113.png", + "code": 1000 + }, + "wind_mph": 6.3, + "wind_kph": 10.1, + "wind_degree": 213, + "wind_dir": "SSW", + "pressure_mb": 1017.0, + "pressure_in": 30.04, + "precip_mm": 0.0, + "precip_in": 0.0, + "snow_cm": 0.0, + "humidity": 60, + "cloud": 0, + "feelslike_c": 7.2, + "feelslike_f": 44.9, + "windchill_c": 7.2, + "windchill_f": 44.9, + "heatindex_c": 9.3, + "heatindex_f": 48.8, + "dewpoint_c": 1.2, + "dewpoint_f": 34.1, + "will_it_rain": 0, + "chance_of_rain": 0, + "will_it_snow": 0, + "chance_of_snow": 0, + "vis_km": 10.0, + "vis_miles": 6.0, + "gust_mph": 9.2, + "gust_kph": 14.8, + "uv": 0 + } + ] + } + ] + } +} diff --git a/weather-api-widget/icons/VitalyGorbachev/broken-clouds-night.svg b/weather-api-widget/icons/VitalyGorbachev/broken-clouds-night.svg new file mode 100644 index 0000000..8b7fc48 --- /dev/null +++ b/weather-api-widget/icons/VitalyGorbachev/broken-clouds-night.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/weather-api-widget/icons/VitalyGorbachev/clear-sky-night.svg b/weather-api-widget/icons/VitalyGorbachev/clear-sky-night.svg new file mode 100644 index 0000000..44f096c --- /dev/null +++ b/weather-api-widget/icons/VitalyGorbachev/clear-sky-night.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/weather-api-widget/icons/VitalyGorbachev/few-clouds-night.svg b/weather-api-widget/icons/VitalyGorbachev/few-clouds-night.svg new file mode 100644 index 0000000..8b7fc48 --- /dev/null +++ b/weather-api-widget/icons/VitalyGorbachev/few-clouds-night.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/weather-api-widget/icons/VitalyGorbachev/mist-night.svg b/weather-api-widget/icons/VitalyGorbachev/mist-night.svg new file mode 100644 index 0000000..960b07d --- /dev/null +++ b/weather-api-widget/icons/VitalyGorbachev/mist-night.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/weather-api-widget/icons/VitalyGorbachev/rain-night.svg b/weather-api-widget/icons/VitalyGorbachev/rain-night.svg new file mode 100644 index 0000000..11ecf00 --- /dev/null +++ b/weather-api-widget/icons/VitalyGorbachev/rain-night.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/weather-api-widget/icons/VitalyGorbachev/scattered-clouds-night.svg b/weather-api-widget/icons/VitalyGorbachev/scattered-clouds-night.svg new file mode 100644 index 0000000..8b7fc48 --- /dev/null +++ b/weather-api-widget/icons/VitalyGorbachev/scattered-clouds-night.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/weather-api-widget/icons/VitalyGorbachev/shower-rain-night.svg b/weather-api-widget/icons/VitalyGorbachev/shower-rain-night.svg new file mode 100644 index 0000000..4d1897c --- /dev/null +++ b/weather-api-widget/icons/VitalyGorbachev/shower-rain-night.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/weather-api-widget/icons/VitalyGorbachev/snow-night.svg b/weather-api-widget/icons/VitalyGorbachev/snow-night.svg new file mode 100644 index 0000000..bee891e --- /dev/null +++ b/weather-api-widget/icons/VitalyGorbachev/snow-night.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/weather-api-widget/icons/VitalyGorbachev/thunderstorm-night.svg b/weather-api-widget/icons/VitalyGorbachev/thunderstorm-night.svg new file mode 100644 index 0000000..1813197 --- /dev/null +++ b/weather-api-widget/icons/VitalyGorbachev/thunderstorm-night.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/weather-api-widget/icons/weather-underground-icons/broken-clouds-night.png b/weather-api-widget/icons/weather-underground-icons/broken-clouds-night.png new file mode 100644 index 0000000..061d1cd Binary files /dev/null and b/weather-api-widget/icons/weather-underground-icons/broken-clouds-night.png differ diff --git a/weather-api-widget/icons/weather-underground-icons/broken-clouds.png b/weather-api-widget/icons/weather-underground-icons/broken-clouds.png old mode 100755 new mode 100644 diff --git a/weather-api-widget/icons/weather-underground-icons/clear-sky-night.png b/weather-api-widget/icons/weather-underground-icons/clear-sky-night.png new file mode 100644 index 0000000..cc40d0f Binary files /dev/null and b/weather-api-widget/icons/weather-underground-icons/clear-sky-night.png differ diff --git a/weather-api-widget/icons/weather-underground-icons/clear-sky.png b/weather-api-widget/icons/weather-underground-icons/clear-sky.png old mode 100755 new mode 100644 diff --git a/weather-api-widget/icons/weather-underground-icons/few-clouds-night.png b/weather-api-widget/icons/weather-underground-icons/few-clouds-night.png new file mode 100644 index 0000000..9c34fab Binary files /dev/null and b/weather-api-widget/icons/weather-underground-icons/few-clouds-night.png differ diff --git a/weather-api-widget/icons/weather-underground-icons/few-clouds.png b/weather-api-widget/icons/weather-underground-icons/few-clouds.png old mode 100755 new mode 100644 diff --git a/weather-api-widget/icons/weather-underground-icons/mist-night.png b/weather-api-widget/icons/weather-underground-icons/mist-night.png new file mode 100644 index 0000000..102142a Binary files /dev/null and b/weather-api-widget/icons/weather-underground-icons/mist-night.png differ diff --git a/weather-api-widget/icons/weather-underground-icons/mist.png b/weather-api-widget/icons/weather-underground-icons/mist.png old mode 100755 new mode 100644 diff --git a/weather-api-widget/icons/weather-underground-icons/rain-night.png b/weather-api-widget/icons/weather-underground-icons/rain-night.png new file mode 100644 index 0000000..49f0903 Binary files /dev/null and b/weather-api-widget/icons/weather-underground-icons/rain-night.png differ diff --git a/weather-api-widget/icons/weather-underground-icons/rain.png b/weather-api-widget/icons/weather-underground-icons/rain.png old mode 100755 new mode 100644 diff --git a/weather-api-widget/icons/weather-underground-icons/scattered-clouds-night.png b/weather-api-widget/icons/weather-underground-icons/scattered-clouds-night.png new file mode 100644 index 0000000..63cb1b2 Binary files /dev/null and b/weather-api-widget/icons/weather-underground-icons/scattered-clouds-night.png differ diff --git a/weather-api-widget/icons/weather-underground-icons/scattered-clouds.png b/weather-api-widget/icons/weather-underground-icons/scattered-clouds.png old mode 100755 new mode 100644 diff --git a/weather-api-widget/icons/weather-underground-icons/shower-rain-night.png b/weather-api-widget/icons/weather-underground-icons/shower-rain-night.png new file mode 100644 index 0000000..49f0903 Binary files /dev/null and b/weather-api-widget/icons/weather-underground-icons/shower-rain-night.png differ diff --git a/weather-api-widget/icons/weather-underground-icons/shower-rain.png b/weather-api-widget/icons/weather-underground-icons/shower-rain.png old mode 100755 new mode 100644 diff --git a/weather-api-widget/icons/weather-underground-icons/snow-night.png b/weather-api-widget/icons/weather-underground-icons/snow-night.png new file mode 100644 index 0000000..0a7f006 Binary files /dev/null and b/weather-api-widget/icons/weather-underground-icons/snow-night.png differ diff --git a/weather-api-widget/icons/weather-underground-icons/snow.png b/weather-api-widget/icons/weather-underground-icons/snow.png old mode 100755 new mode 100644 diff --git a/weather-api-widget/icons/weather-underground-icons/thunderstorm-night.png b/weather-api-widget/icons/weather-underground-icons/thunderstorm-night.png new file mode 100644 index 0000000..2102104 Binary files /dev/null and b/weather-api-widget/icons/weather-underground-icons/thunderstorm-night.png differ diff --git a/weather-api-widget/icons/weather-underground-icons/thunderstorm.png b/weather-api-widget/icons/weather-underground-icons/thunderstorm.png old mode 100755 new mode 100644 diff --git a/weather-api-widget/weather.lua b/weather-api-widget/weather.lua index 34a542f..821b097 100644 --- a/weather-api-widget/weather.lua +++ b/weather-api-widget/weather.lua @@ -66,6 +66,7 @@ local weather_popup = awful.popup { --- Maps WeatherAPI condition code to file name w/o extension --- See https://www.weatherapi.com/docs/#weather-icons +--- Day/Night is determined at time of mapping the weather to an icon local icon_map = { [1000] = "clear-sky", [1003] = "few-clouds", @@ -171,14 +172,16 @@ local function worker(user_args) local api_key = args.api_key local font_name = args.font_name or beautiful.font:gsub("%s%d+$", "") local units = args.units or 'metric' + local time_format_12h = args.time_format_12h local both_units_widget = args.both_units_widget or false local icon_pack_name = args.icons or 'weather-underground-icons' local icons_extension = args.icons_extension or '.png' - local show_forecast = args.show_forecast or false + local show_daily_forecast = args.show_daily_forecast or false + local show_hourly_forecast = args.show_hourly_forecast or false local timeout = args.timeout or 120 local ICONS_DIR = WIDGET_DIR .. '/icons/' .. icon_pack_name .. '/' - -- Forecast endpoint includes current. I could map show_forecast to days here. + -- Forecast endpoint includes current. I could map show_daily_forecast to days here. -- Currently overfetching but only showing when opting in. local weather_api = ('https://api.weatherapi.com/v1/forecast.json' .. @@ -291,8 +294,13 @@ local function worker(user_args) forced_width = 300, layout = wibox.layout.flex.horizontal, update = function(self, weather) + local day_night_extension = "" + if not weather.is_day then + day_night_extension = "-night" + end + self:get_children_by_id('icon')[1]:set_image( - ICONS_DIR .. icon_map[weather.condition.code] .. icons_extension) + ICONS_DIR .. icon_map[weather.condition.code] .. day_night_extension .. icons_extension) self:get_children_by_id('temp')[1]:set_text(gen_temperature_str(weather.temp_c, '%.0f', false, units)) self:get_children_by_id('feels_like_temp')[1]:set_text( LCLE.feels_like .. gen_temperature_str(weather.feelslike_c, '%.0f', false, units)) @@ -304,7 +312,7 @@ local function worker(user_args) end } - local forecast_widget = { + local daily_forecast_widget = { forced_width = 300, layout = wibox.layout.flex.horizontal, update = function(self, forecast) @@ -313,6 +321,11 @@ local function worker(user_args) for i, day in ipairs(forecast) do -- Free plan allows forecast for up to three days, each with hours if i > 3 then break end + local day_night_extension = "" + if not day.is_day then + day_night_extension = "-night" + end + local day_forecast = wibox.widget { { text = os.date('%a', tonumber(day.date_epoch)), @@ -323,7 +336,10 @@ local function worker(user_args) { { { - image = ICONS_DIR .. icon_map[day.day.condition.code] .. icons_extension, + image = ICONS_DIR + .. icon_map[day.day.condition.code] + .. day_night_extension + .. icons_extension, resize = true, forced_width = 48, forced_height = 48, @@ -364,6 +380,181 @@ local function worker(user_args) end } + local hourly_forecast_graph = wibox.widget { + step_width = 12, + color = '#EBCB8B', + background_color = beautiful.bg_normal, + forced_height = 100, + forced_width = 300, + widget = wibox.widget.graph, + set_max_value = function(self, new_max_value) + self.max_value = new_max_value + end, + set_min_value = function(self, new_min_value) + self.min_value = new_min_value + end, + } + + local hourly_forecast_negative_graph = wibox.widget { + step_width = 12, + color = '#5E81AC', + background_color = beautiful.bg_normal, + forced_height = 100, + forced_width = 300, + widget = wibox.widget.graph, + set_max_value = function(self, new_max_value) + self.max_value = new_max_value + end, + set_min_value = function(self, new_min_value) + self.min_value = new_min_value + end, + } + + local hourly_forecast_widget = { + layout = wibox.layout.fixed.vertical, + update = function(self, hourly) + local hours_below = { + id = 'hours', + forced_width = 300, + layout = wibox.layout.flex.horizontal + } + local temp_below = { + id = 'temp', + forced_width = 300, + layout = wibox.layout.flex.horizontal + } + + local max_temp = -1000 + local min_temp = 1000 + local values= {} + + -- Yeah, this looks weird. I would expect to have to use ipairs + for i, hour in pairs(hourly) do + if i > 25 then + break + end + + values[i] = hour.temp_c + + if max_temp < hour.temp_c then + max_temp = hour.temp_c + end + + if min_temp > hour.temp_c then + min_temp = hour.temp_c + end + + if (i - 1) % 5 == 0 then + table.insert(hours_below, wibox.widget { + text = os.date(time_format_12h and '%I%p' or '%H:00', tonumber(hour.time_epoch)), + align = 'center', + font = font_name .. ' 9', + widget = wibox.widget.textbox + }) + + table.insert(temp_below, wibox.widget { + markup = '' + .. string.format('%.0f', hour.temp_c) .. '°' .. '', + align = 'center', + font = font_name .. ' 9', + widget = wibox.widget.textbox + }) + end + end + + hourly_forecast_graph:set_max_value(math.max(max_temp, math.abs(min_temp))) + hourly_forecast_graph:set_min_value(min_temp > 0 and min_temp * 0.7 or 0) -- move graph a bit up + + hourly_forecast_negative_graph:set_max_value(math.abs(min_temp)) + hourly_forecast_negative_graph:set_min_value(max_temp < 0 and math.abs(max_temp) * 0.7 or 0) + + for _, value in ipairs(values) do + if value >= 0 then + hourly_forecast_graph:add_value(value) + hourly_forecast_negative_graph:add_value(0) + else + hourly_forecast_graph:add_value(0) + hourly_forecast_negative_graph:add_value(math.abs(value)) + end + end + + local count = #self + for i = 0, count do + self[i] = nil + end + + -- all temperatures are positive + if min_temp > 0 then + table.insert(self, wibox.widget { + { + hourly_forecast_graph, + reflection = { horizontal = true }, + widget = wibox.container.mirror + }, + { + temp_below, + valign = 'bottom', + widget = wibox.container.place + }, + id = 'graph', + layout = wibox.layout.stack + }) + table.insert(self, hours_below) + + -- all temperatures are negative + elseif max_temp < 0 then + table.insert(self, hours_below) + table.insert(self, wibox.widget { + { + hourly_forecast_negative_graph, + reflection = { horizontal = true, vertical = true }, + widget = wibox.container.mirror + }, + { + temp_below, + valign = 'top', + widget = wibox.container.place + }, + id = 'graph', + layout = wibox.layout.stack + }) + + -- mixed temperatures + else + table.insert(self, wibox.widget { + { + hourly_forecast_graph, + reflection = { horizontal = true }, + widget = wibox.container.mirror + }, + { + temp_below, + valign = 'bottom', + widget = wibox.container.place + }, + id = 'graph', + layout = wibox.layout.stack + }) + + table.insert(self, wibox.widget { + { + hourly_forecast_negative_graph, + reflection = { horizontal = true, vertical = true }, + widget = wibox.container.mirror + }, + { + temp_below, + valign = 'top', + widget = wibox.container.place + }, + id = 'graph', + layout = wibox.layout.stack + }) + end + end + } + local function update_widget(widget, stdout, stderr) if stderr ~= '' then if not warning_shown then @@ -398,7 +589,13 @@ local function worker(user_args) widget:is_ok(true) local result = json.decode(stdout) - widget:set_image(ICONS_DIR .. icon_map[result.current.condition.code] .. icons_extension) + + local day_night_extension = "" + if not result.current.is_day then + day_night_extension = "-night" + end + + widget:set_image(ICONS_DIR .. icon_map[result.current.condition.code] .. day_night_extension .. icons_extension) -- TODO: if units isn't "metric", read temp_f instead widget:set_text(gen_temperature_str(result.current.temp_c, '%.0f', both_units_widget, units)) @@ -411,9 +608,14 @@ local function worker(user_args) } - if show_forecast then - forecast_widget:update(result.forecast.forecastday) - table.insert(final_widget, forecast_widget) + if show_hourly_forecast then + hourly_forecast_widget:update(result.forecast.forecastday[1].hour) + table.insert(final_widget, hourly_forecast_widget) + end + + if show_daily_forecast then + daily_forecast_widget:update(result.forecast.forecastday) + table.insert(final_widget, daily_forecast_widget) end weather_popup:setup({ @@ -437,6 +639,18 @@ local function worker(user_args) end end))) + weather_widget:connect_signal("mouse::enter", function() + weather_widget:set_bg(beautiful.bg_focus) + weather_popup:move_next_to(mouse.current_widget_geometry) + end) + + weather_widget:connect_signal("mouse::leave", function() + if weather_popup.visible then + weather_widget:set_bg('#00000000') + weather_popup.visible = not weather_popup.visible + end + end) + watch( string.format(GET_FORECAST_CMD, weather_api), timeout, -- API limit is 1k req/day; day has 1440 min; every 2 min is good