Implementing a heartbeat to warn about lack of connectivity

Syncthing is running stable without any need for user intervention. Several times I ran into a problem that a network setting change prevented Syncthing from actually running and it went unnoticed for a period of time.

How can I implement alerting for a situation when two nodes remain disconnected for over 24 hours?

I thought of a scheduled task that creates files periodically on each node and checks for the files from the other nodes, however isn’t there a simpler method?

Simplest would probably be to periodically poll the /rest/stats/device API endpoint. It gives you a “last seen” value for each configured device. That will be within the last minute or so when the devices are connected, and otherwise reflect the time we were last connected to them.

Perfect! Thank you.