Hello @paulbernardr we are hoping to do similar but are some way off everything you are after there. There’s a longer discussion of our intentions here: OpenEnergyMonitor Demand Side Response Development and info on demand shaper module which has an octopus forecast input for their agile tariff Emoncms Demand Shaper module.
I imagine however that it will be easier for you to achieve what you are after, at least in the meantime, with MQTT, NodeRed? @glyn.hudson might have some more ideas.