Linking a Photon to a 12v Doorbel

Hi Folks… i’m a bit of a noob so please go easy on me.

But would it be safe to link a photon running a simple push-button sketch (push-button activates a push-notification) to a an existing 12v doorbell.

The idea being that when the doorbell is pressed, not only does it ring the bell as normal but also connects the photon pin to gnd and sends a push-notification to my phone.

Thanks in advance.


You should be able to find this EXACT question already asked in this forum with several suggestions, the simplest of which probably involves an opto-isolator and a resistor.