2024-04-17 10:09:34 +02:00

1.8 KiB

title, description, ha_category, ha_release, ha_iot_class, ha_codeowners, ha_domain, ha_quality_scale, ha_config_flow, ha_platforms, ha_integration_type
title description ha_category ha_release ha_iot_class ha_codeowners ha_domain ha_quality_scale ha_config_flow ha_platforms ha_integration_type
National Weather Service (NWS) Instructions on how to integrate National Weather Service data within Home Assistant.
Weather
0.99 Cloud Polling
@MatthewFlamm
@kamiyo
nws platinum true
sensor
weather
integration

The nws platform uses the National Weather Service web API as a source for meteorological data for your location.

{% include integrations/config_flow.md %}

According to the API documentation, a string is required for the API key, and an email address is suggested to be included within the string.

Providing a METAR station code is optional, and if not supplied, the closest station to the latitude and longitude will be chosen. A list of nearby stations is printed to the log with level DEBUG if no station is supplied. Stations can also be found on the NOAA website. Codes with only three characters, for example, ADW should be prefixed with the letter K, KADW.

One weather entity is created for each entry in the configuration. Hourly and day/night forecasts are provided through the weather.get_forecasts service. The time supplied for each forecast is the start time for the forecast. Sensors are also created as disabled entities after configuration and can be enabled by the user.

Details about the API are available in the NWS API documentation. The pynws library is used to retrieve data.

Details about the weather.get_forecasts service are available in the weather documentation.