Hi
I have a similar setup with eq-3 max! cube and devices, with the boiler controlled with a zwave relay (and I have seen your message on the homematic forum since I’m considering switching to the HomematicIP devices)
What you are suggesting should work. I don’t know about the shelly connections though, but as long as the shelly is just acting as a simple switch for the boiler thermostat input, it should work
you will then have to interface the thermostats with the shelly via an automation in home assistant (or node red in my case)
A downside that I have encountered with my setup is that if the link between the thermostats and home assistant is lost, or if home assistant crashes, there is no command anymore for the boiler! if you’re lucky the switch was closed and the boiler keeps circulating the water and the thermostats keep doing their job, otherwise, you will have no heating until everything is back up!
To solve this, I’m thinking about using this homematic relay switch HMIP PCBS: HomeMatic IP switch circuit board at reichelt elektronik in order to have a direct link b/w the thermostats and the boiler. However I’m not sure if this is 100% independent of the network or not (I’ve posted in the homematic forum to ask this question)