A CT around the cable supplying power to the 3-port valve would work for all systems, some 3-port valves even have a microswitch in them designed to be used to provide a signal for applications like this. I’m lucky I can read a boolean register via modbus from my Samsung heatpump which informs the position of the 3-port valves, I’ve used this to separate central heating and DWH in the monitoring.
I post the combined figures DHW + CE to heatpumpmonitor.org so the data is comparable with the other systems on there, since most of them include DHW