Open StefanW86 opened 11 months ago
I've got same problem. All cover automations stopped working.
Help please.
Perhaps it is possible to change to datasource https://openholidaysapi.org/
Perhaps it is possible to change to datasource https://openholidaysapi.org/
i use this for the moment:
sensor:
- platform: rest
resource: https://openholidaysapi.org/SchoolHolidays?countryIsoCode=DE&languageIsoCode=DE&validFrom={{ now().strftime('%Y-%m-%d') }}&validTo={{ now().strftime('%Y-%m-%d') }}&subdivisionCode=DE-TH
method: GET
name: openholidayapi_ferien_th
value_template: >
{% if value_json["name"] %}
true
{% else %}
false
{% endif %}
scan_interval: 10
The sensor look for the current day for Thuringia in Germany.
Perhaps it is possible to change to datasource https://openholidaysapi.org/
i use this for the moment:
sensor: - platform: rest resource: https://openholidaysapi.org/SchoolHolidays?countryIsoCode=DE&languageIsoCode=DE&validFrom={{ now().strftime('%Y-%m-%d') }}&validTo={{ now().strftime('%Y-%m-%d') }}&subdivisionCode=DE-TH method: GET name: openholidayapi_ferien_th value_template: > {% if value_json["name"] %} true {% else %} false {% endif %} scan_interval: 10
The sensor look for the current day for Thuringia in Germany.
this sensor do not work
here is an working replacement as binary sensor like original
- platform: rest
name: openholidayapi_ferien_by_binary # today
resource_template: >
https://openholidaysapi.org/SchoolHolidays?countryIsoCode=DE&languageIsoCode=DE&validFrom={{ now().strftime('%Y-%m-%d') }}&validTo={{ now().strftime('%Y-%m-%d') }}&subdivisionCode=DE-BY
value_template: "{{ not value_json[0].id is none }}"
scan_interval: 300
- platform: rest
name: openholidayapi_ferien_by_morgen_binary #tomorrow
resource_template: >
https://openholidaysapi.org/SchoolHolidays?countryIsoCode=DE&languageIsoCode=DE&validFrom={{ (now() + timedelta(days=1) ).strftime('%Y-%m-%d') }}&validTo={{ (now() + timedelta(days=1) ).strftime('%Y-%m-%d') }}&subdivisionCode=DE-BY
value_template: "{{ not value_json[0].id is none }}"
scan_interval: 300
ferien-api.de seems to be back online
@tombrain very nice, could this rest-call be used to create a home assistant (local) calendar "on the fly"?
@tombrain very nice, could this rest-call be used to create a home assistant (local) calendar "on the fly"?
@ecdlguy can you describe your situation? what do you mean "on the fly"?
what do you mean "on the fly"?
I'm trying to have a "school holiday" calendar in home assistant that automatically keeps up-to-date.
Using the REST platform one can fetch school holidays for an entire year for example. I'm not an expert regarding home assistant templates, but maybe it's possible to create events for e.g. a local calendar from the REST response?
@ecdlguy You can still use the REST interface to query whether a particular day is a vacation or not.
If you want an annual calendar with all vacations, you may have to go via the Google calendar.
Hello,
since today there seems to be an issue with the url ferien-api.de. The url is not reachable anymore.