Closed brianjking closed 7 years ago
# Pollen - platform: rest name: pollen_percentage resource: https://www.pollen.com/api/forecast/current/pollen/##### <--- ZIP CODE value_template: "{{value_json.Location.periods[1].Index}}" scan_interval: 21600 headers: Referer: "https://www.pollen.com" - platform: template sensors: pollen_level: friendly_name: 'Pollen Level' value_template: > {% if states.sensor.pollen_percentage.state|float <= 2.4 %}Low {% elif states.sensor.pollen_percentage.state|float <= 4.8 %}Low to Medium {% elif states.sensor.pollen_percentage.state|float <= 7.2 %}Medium {% elif states.sensor.pollen_percentage.state|float <= 9.6 %}Medium to High {% elif states.sensor.pollen_percentage.state|float <= 12.0 %}High {% else %}Unknown {% endif %} # Flu Sensor - platform: rest name: cold_flu_percentage resource: https://www.pollen.com/api/forecast/extended/cold/##### <--- ZIP CODE value_template: "{{value_json.Location.periods[1].Index}}" scan_interval: 21600 headers: Referer: "https://www.pollen.com" - platform: template sensors: cold_flu_risk: friendly_name: 'Cold & Flu Risk' value_template: > {% if states.sensor.cold_flu_percentage.state|float <= 2.4 %}Low {% elif states.sensor.cold_flu_percentage.state|float <= 4.8 %}Low to Medium {% elif states.sensor.cold_flu_percentage.state|float <= 7.2 %}Medium {% elif states.sensor.cold_flu_percentage.state|float <= 9.6 %}Medium to High {% elif states.sensor.cold_flu_percentage.state|float <= 12.0 %}High {% else %}Unknown {% endif %}
source: https://community.home-assistant.io/t/pollen-allergy-sensor/10033/6
source: https://community.home-assistant.io/t/pollen-allergy-sensor/10033/6