Automation with condition related to wind speed

Hi,
Not sure if third part integrations is the right place here.
I’m trying to write an automation that will use the current wind speed from the ‘default’ built in Meteorologisk institutt (Met.no). This appears to show wind speed information retrieved:
Wind speed: 27 km/h (ENE)
(When I view the card on lovelace)
But I cannot see this data in any of the automation values or how I could use these.
Is there somewhere/something I’m missing to be able to access this data?
Perhaps writing a binary sensor with threshold could work, something like:

  - platform: template
    sensors:
      windspeed_too_high:
        value_template: "{{ states('weather.home')|float > 15 }}"
        friendly_name: 'Windspeed too high'

NOTE - the “weather.home” part of that is what I do not know, how do I query the value of that? Looking in the code at https://github.com/home-assistant/core/blob/dfe3ee538764ff0d7c146c5a188c99977951ccd1/homeassistant/components/met/const.py
I see the mapping to “wind_speed” so would the code be
weather.home.wind_speed

Anyone any pointers please?
Thanks!

You can use this as your template:
{{ state_attr('weather.home', 'wind_speed') > 15 }}

IN the STATES we have

I think you need to read the wind_speed so

so
I would just

 value_template: "{{ states('weather.home')|float > 15 }}"

to

value_template: "{{ state_attr('weather.home', 'wind_speed')|float > 15 }}"
1 Like

snap BRO

needs more text

Great, thanks both of you. Myle thank you for the detailed info, I’d forgotten about the developer states method of finding values. Thanks for the tutorial :slight_smile:

what about marking it as a “solution”