Telegram, Discord, Slack & Webhook Alerts
Receive real-time execution alerts across Telegram, Discord, Slack, and custom HTTP webhooks when automated playbooks complete, fail, timeout, or get canceled.
Production automation should not require operators to watch terminal output continuously. When background playbooks run on schedules or trigger via inbound webhooks, teams need immediate status visibility where they already work.
CIEL provides native Notification Channels to broadcast job outcomes into team chat platforms and monitoring pipelines the moment an execution finishes, encounters host failures, or reaches an error state.
1. Supported Notification Providers
CIEL natively integrates with four communication channels without requiring external gateway daemons:
A. Telegram Bot
- Protocol: Direct HTTPS requests to the official Telegram Bot API (
/sendMessage). - Required Configuration:
telegram_bot_token: API token generated via@BotFather.telegram_chat_id: Numeric target chat ID (individual user ID or-100...supergroup ID).
- Message Format: Clean Markdown message displaying execution status tags (
[SUCCESS],[FAILED], or[INFO]), project name, playbook title, target inventory or host scope, failed host counts, duration in seconds, Job ID, and error summaries.
B. Discord Webhooks
- Protocol: HTTP POST to Discord Incoming Webhooks.
- Required Configuration:
webhook_urlgenerated under Discord Channel Settings -> Integrations -> Webhooks. - Message Format: Color-coded rich embed cards:
- Green (
#2ECC71) for successful executions. - Red (
#E74C3C) for failed or timed-out executions. - Blue (
#3498DB) for test notifications and operational notices. - Embed fields include Project, Status, Playbook, Target Scope, Failed Hosts, Duration, and a footer linking the Job ID.
- Green (
C. Slack Incoming Webhooks
- Protocol: HTTP POST to Slack App incoming webhooks.
- Required Configuration:
webhook_urlfrom your Slack App configuration. - Message Format: Standard Slack attachments with color indicators (
#36a64fgreen,#e01e5ared,#439FE0blue), structured field pairs, and Job ID footer annotations.
D. Custom Webhook (HTTP POST JSON)
- Protocol: Standard HTTP
POSTwithContent-Type: application/json. - Required Configuration:
webhook_urlaccepting JSON payloads. - Best for: Triggering downstream workflows in orchestration tools (such as n8n, Zapier, Prometheus Alertmanager, or internal incident response microservices).
- Payload Schema:
{
"event": "job_status",
"data": {
"job_id": "job-8d9e2a1f-b32c-4912-88ef",
"project_id": 1,
"project_name": "Production Infrastructure",
"status": "successful",
"exit_code": 0,
"error_message": null,
"playbook_name": "Deploy Production Application",
"target_label": "Target",
"target_name": "Direct Host (2 hosts)",
"inventory_name": null,
"execution_mode": "podman",
"duration_seconds": 38.5,
"failed_host_count": 0
}
}When a job runs against a registered inventory, target_label is set to "Inventory" and inventory_name reflects the inventory title. When executed directly against ad-hoc hosts or provisioners, target_label is set to "Target".
2. Configuring Channels in the Dashboard
Navigate to Notifications (/notifications in the sidebar under RUNS & JOBS) and click + Add Channel to open the drawer:
Step 1: Channel Name
Provide a recognizable operational title (for example, DevOps Team Telegram or Production Discord Alerts). Channel names must be unique within the active project.
Step 2: Select Provider Type
Click on one of the provider tiles: Telegram, Slack, Discord, or Custom Webhook. The credential fields below update dynamically based on your selection.
Step 3: Enter Credentials
- For Telegram: Enter your Bot Token and Target Chat ID.
- For Slack, Discord, or Custom Webhook: Enter the destination incoming Webhook URL.
Step 4: Select Trigger Events
Choose which job outcomes should send notifications:
- Failed: Sent when a playbook execution fails or any target host is reported unreachable.
- Successful: Sent when the playbook finishes with exit code
0across all hosts. - Canceled: Sent when an active job is stopped manually by an operator.
- Timed Out: Sent when a task exceeds its maximum allowed execution deadline.
Use the quick selector links above the list to toggle between:
- Failures only (
Failed+Timed Out): Recommended for production environments to eliminate notification fatigue. - All events: Broadcasts all job state transitions.
Step 5: Save & Activate
Toggle the Active switch to enable notifications immediately upon creation.
3. Testing & Error Diagnostics
Before relying on an alert channel for production incident response, verify that your credentials and webhook endpoints accept incoming payloads.
Sending a Test Notification
Click the three-dots action menu (...) on any channel row in the table and select Send test notification. CIEL dispatches an immediate test payload to the configured endpoint.
Upstream Error Sanitization
If an external provider returns an error (such as an invalid Telegram bot token, a revoked Discord webhook, or an unreachable internal server), CIEL captures the diagnostic response:
- HTTP 405 Method Not Allowed: Alerts operators if the destination URL rejects HTTP
POSTrequests. - Upstream Diagnostic Snippet: Surfaces actionable error messages from the provider (such as Telegram's
chat not foundor Discord'sUnknown Webhook) directly in the UI toast notifications without exposing private tokens or leaking controller internal stack traces. - Timeout Protection: Upstream notification dispatches time out safely after 10 seconds, preventing external webhook latency from delaying internal job lifecycle transitions.
4. Operational Management
- Pause without Deletion: To temporarily silence notifications during scheduled maintenance windows, select Pause notifications from the row action menu. The channel remains configured but will not receive alerts until re-enabled.
- Project Isolation: Notification channels are scoped to projects. Different teams or environments (staging vs production) maintain their own independent alert destinations and event filters.
5. External References
For upstream specifications and setup guides:
- Telegram Bot API Documentation: Official documentation on bot token creation and message formatting.
- Discord Webhooks Guide: Step-by-step instructions for creating channel webhooks in Discord.
- Slack Incoming Webhooks: Creating and managing incoming webhook URLs for Slack workspaces.