Many devices draw a lot of power, washing machine, dish washer, water heater, oven, all draw 3Kw in my case. Stack those and they can overload an inverter very quickly.
If they could be improved, I know my washing machine has wifi, so maybe a bit of new firmware would allow it to check if it can use 3KW now or add itself to a queue and wait for 1 minute.
My hot water could be set up with a smart switch that allows interruption directed by API as it likes 3KW for about an hour and stopping for a minute or two while the washing machine heats water is acceptable.
If an API were part of home assistant then it might catch on and start to be made part of devices.
I think an API that requests:
Load value in watts
Expected duration
Longest time it can wait before the lack of power would be an issue
How interruptable the load is.
Then HA could coordinate nicely maybe with automation layered on so it can be tweaked.
It may be this can be exposed to HA as entities with the future load requirements in standardised load entities and entities to provide load use schedule and interruption notification.
Although not crystal clear, it seems what you describe can be done in an automation, while you seems to ask for HA to expose an API?
What would call this API?
I suppose API is possibly the wrong name, but I am talking about a defined set of attributes/entities and a fairly well defined quinig mechinism.
With Automation the code might be quite complex and everyone would have to do their own thing.
If HA were to standardise an “interface” where the energy management entity names were “well knon names” then a device manufacturer could expose their program code to easy management by including the required entities.
I have 8 devices that are requiring of not clashing to keep load below threshold, then others that stacked could impact others hitting the threshold.
Using automation to manage all these, where some may be interruptible, others not, some may be urgent others not, seems a huge task for something that I think is core to a managed home, though getting device makers to buy into will take time and will only become a thing if there is a simple standard way to do things. Hence my poor use of API when I should have said Interface instead.
Not saying it wouldn’t be complex, but what you are describing is complex, and extremely specific btw.
HA automagically doing it for you, in a generic manner so that it was be usable by the (few?) others having similar requirements but with completely different devices, devices that would be all providing the required information in a standard way (none of them doing that today) in the hope that it will stick seems a bit of wishful thinking
I like this idea, it is correct to want energy to be used in the most efficient way in our homes and even more so if we have a green energy generator at home.
Since self-generated energy is limited, it would be good if home assistan included a standard on/off method for each device in the “energy” panel, which already has a section where you can configure consumption devices.
So we could improve self-consumption.