Linky
Enedis equipment that provides power consumption.
Unfortunately, data are only available on the $à%*!… Enedis website.
Principle
- Scrap (*crap*) the Enedis website using credentials
- Convert data from website to JSON
- Inject JSON in InfluxDB
- Connect Grafana to influxDB instance
- Display Grafana graph in HA iframe
Data scrapping
Thanks to barasher/linky-to-influxdb.
My stack
- Inject the barasher script inside a Docker image
- Create a crontab inside the image that triggers the linky-to-influxdb script.
- To handle missing days, i slightly modify the linky-to-influxdb script
- if a file with the
YYYYMMDD
pattern is detected in the arbitrary./schedule
folder in the image, it will launch the script for this day
- if a file with the
InfluxDB
the hass.io InfluxDB add-on.
The addon can be used to create the right request via the Explore feature.
Grafana
the hass.io Grafana add-on.
The Influxdb database must be configured in Grafana.
After creating the panel using the previous Influxdb request, Grafana can provide a share link that can be integrated in a Home assitant iframe.