Awwww yeah 🎉🎉🎉🎉. I now get a call to action when the grid is dirty AND I’m using more than 0.5 kW, which is a wee bit higher than my usual base load and waaaay below what the heat pump uses. Quite happy with my bash and jq wrestling to get me the data of when the grid is next likely to be clean again. 💪
(I’ve commented the if for testing purposes - obviously the prompt doesn’t make sense when consumption is 0 - but you get the idea!)