If you normally set an alarm when you leave the house, use that to trigger an action that'll shut off the water 1 hour later (in case the washer or dishwasher is running). Use the Disarm action to open the valve when you return. Why not just rely on the leak sensors? You can IF you have one under each and every sink, toilet, dishwasher, washing machine and ice maker/refrigerator (with water) in your house.
We once had a home where the plastic toilet supply line connector cracked while we were away for two days. The water took out my wife's walk-in closet and contents, the master bedroom ceiling, furniture and carpeting, the living room hardwood floors, the garage ceiling and a light fixture that then fell on the hood of our car. Total insurance claim was $84,000 and it took almost 6 months to do the work which also required a new beam to correct the then sagging 2nd floor! Two of the other connectors in that home were also cracked but hadn't started leaking! It could have been worse if a neighbor hadn't noticed water coming out under the garage door and turned off our water.
Turns out there was a class action suit against the manufacturer of the toilet supply lines and our insurance company was one of the plaintiffs. They won and a few years later we received a check for the deductible we had to pay. I also only allow toilet supply lines with brass connectors in my home now.