A leak sensor is the simplest home automation sensor possible. Its literally just a bare wire connected to ground, another connecting to a digital IO. You put the two bare wires on the floor a little distance apart and write some code to fire off an alert if the IO ever reports being connected, because if it is that means something conductive is sitting between the two wires.