Alerts

Email and Telegram notifications on device status changes.

PyPing fires alerts on status transitions: when a device goes from online to offline, and when it recovers. Alerts are managed at /alerts.

Alert Channels

ChannelConfig locationTest endpoint
Email (SMTP)Settings → APP CONFIG (smtp_* keys)TEST SMTP button in Settings
TelegramSettings → APP CONFIG (telegram_* keys) + TELEGRAM_BOT_TOKEN env varTEST TG button in Settings

Alert Log

Each fired alert is recorded in the alerts table with device name, event (DOWN / UP), channel used, and send timestamp. This gives an audit trail independent of external inbox or chat history.

Per-Device Alert Toggle

In the device edit form, uncheck Alerts enabled to silence alerts for that specific device while keeping global alerts active. Useful for hosts that are intentionally offline (e.g. a powered-down lab machine).

How to configure Telegram

  1. Create a bot with @BotFather — save the token as TELEGRAM_BOT_TOKEN in your .env.
  2. Add the bot to your group or channel.
  3. Get the chat ID (use @getidsbot or the Telegram API).
  4. Enter the chat ID in Settings and click TEST TG to verify delivery.