Sorry about that. Almost all the alarms, battery or line operated, have two contacts to sense the water. I noticed one was just set on the floor and both contacts were probably hidden underneath. Most have a cable that connects the alarm box to a pair of metal contacts that are placed where water would be a problem. Here is what I was visualizing:
https://www.defensedevices.com/flood-alarm.html
The cable coming out of it has two tires. You would cut off the little do-dad on the end and use these two wires for your sensor. One would go to the metal(?) pipe. The other wire would be attacked to a metal rod (insulated from the pipe) that is attached to your micrometer, and is moved into the pipe like you original sensor example.
Ken