--- title: "Alert Notifications & Telegram Bot" description: "Real-time incident dispatching across Telegram bots, SMTP email channels, and customizable notification templates in Ring2All NMS." --- ## 📖 Introduction When an infrastructure anomaly, hardware degradation, or service outage occurs, rapid notification is paramount. The **Alert Notifications** subsystem in Ring2All NMS unifies high-speed messaging across **Telegram Bots**, enterprise **SMTP Email Servers**, and webhook endpoints, with full support for customizable rich Markdown and HTML alert templates. ![NMS Telegram Settings](/screenshots/nms/telegram-settings.png) ![NMS SMTP Settings](/screenshots/nms/smtp-settings.png) ![NMS Notification Templates](/screenshots/nms/notification-templates.png) --- ## 🎯 User Roles & Key Capabilities | Role | Primary Use Case | Key Capabilities | | :--- | :--- | :--- | | **On-Call NOC Engineers** | Instant incident notification on mobile devices. | Receive rich Telegram alerts with host name, error description, severity level, and one-click acknowledge links. | | **Operations Management** | Executive digest summaries and SLA logging. | Configure SMTP email dispatches for daily health digests and formal outage post-mortems. | | **Platform Integrators** | Webhook delivery into ticketing systems. | Route JSON alert payloads into PagerDuty, Jira Service Desk, or custom webhook endpoints. | --- ## 📢 Multi-Channel Alert Pipeline ```mermaid graph LR Incident[Anomaly Detected by NMS / Watchdog] --> Router[Alert Routing Engine] Router --> TG[📱 Telegram Bot Dispatch] Router --> Mail[✉️ SMTP Email Server] Router --> WH[🔗 Webhook HTTP POST] TG --> T1[Instant Push to Private Group or Channel] Mail --> M1[HTML Formatted Email with Incident Table] WH --> W1[Automated Incident Ticket Creation] ``` ### 1. Telegram Bot Integration Telegram provides sub-second push notifications across mobile and desktop devices without SMS costs or cellular delay: * **Bot Token**: Standard token issued by `@BotFather`. * **Chat ID**: Target private chat ID or public/private group ID (e.g., `-1001234567890`). * **Test Dispatch**: Built-in **Send Test Message** button confirms Telegram API connectivity before enabling alerts in production. ### 2. SMTP Mail Server Configuration Supports standard TLS/STARTTLS connections to corporate mail servers (Google Workspace, Microsoft 365, Amazon SES, Postfix): * **Host & Port**: Mail server FQDN and port (`587` for STARTTLS, `465` for SSL/TLS). * **Authentication**: Username and secure app password. * **From Address**: Standardized sender identity (e.g., `alerts@ring2all.com`). ### 3. Unified Templates Hub & Notification Templates (`/settings/templates`) The **Templates Hub** (`/settings/templates`) brings **Notification Templates** together with the platform's entire blueprint library behind a 5-KPI summary bar and five clean tabs (**Marketing Agents**, **Connected Services**, **SSH Servers**, **General Servers**, and **Notifications**), making it the central launchpad after installation: ![NMS Unified Templates Hub](/screenshots/nms/templates-hub.png) Within the **Notifications** tab, administrators customize the exact wording, severity styling, and dynamic placeholders used by Telegram Bots, SMTP Emails, and Webhooks: * `{{server_name}}`: Name of the reporting host. * `{{metric_name}}`: The specific metric violating thresholds (e.g., `Disk /var/log`, `SIP 5060`). * `{{current_value}}` & `{{threshold}}`: Real-time measurement vs. configured limit. * `{{timestamp}}`: UTC and localized timestamp of the event.