With blockly I can't help. But there are dzvents scripts in my signature. One of them is just what you need. Very easy.
I recommend you pour over blockly and take a moment to study dzvents. It really isn't difficult. For me, blockly is much more difficult.
I wrote once in your topic with a request for a script someone tried to help but we didn't get to the end and final. How do I get started with dzvents ? How do I figure out where to look for some advice ?
Generally I did what I wanted to achieve but I had to base part of the tasks on integra and the other part on domoticz although I know that one script would probably take care of it.