How to use RESTful Sensor availability option

I’m unclear on how to use the availability variable when using the RESTful Sensor. I’ve read through the doc page, but there are no examples and what I’ve found here so far does not definitively tell me how to use it.

I’m either over thinking it or just missing it. Ultimately, I’m wondering if it is something that can help me tell my template sensors to not update if the payload is not there or malformed, or if that JSON part is missing.

Thank you for any direction on this.

Hi ,

I’m not sure but there is a plethora of info on the subject here. Look at the more recent ones first.
Try to put this search term in your search engine:

site:home-assistant.io restful availability

Not really, if the availability template detects those issues it can set the sensor state to unavailable.

You can detect the issues and use this.state in your template to retain the state though.

Great. Thanks for the insight.