Install and Configure Apprise on Cloud Server with a Single API for Over 80 Notification Platforms
Detailed guide to install and configure Apprise on a cloud server to send notifications to over 80 platforms using a single API.
Image credit: Bessi · Pixabay Content License
Apprise is an open-source tool that enables sending notifications to over 80 platforms such as Slack, Telegram, Email, SMS, Discord, Pushover, Microsoft Teams, and more using a single API. This guide walks you through installing and configuring Apprise on a cloud server to manage notifications in a centralized, efficient, and flexible way.
Prerequisites
- Cloud server (VPS) running Linux (Ubuntu 20.04/22.04 or Debian 11/12)
- SSH (or terminal) access to the server
- Python 3.8 or higher
- pip (Python package manager)
- Stable internet connection
1. Install Apprise on Cloud Server
Run the following commands in the server terminal to install Apprise:
sudo apt update
sudo apt upgrade -y
sudo apt install python3 python3-pip -y
pip3 install apprise
Verify the installation by running:
apprise --version
2. Configure Apprise with Notification Platforms
Apprise supports multiple notification platforms via specific URL formats. Below are examples for common platforms:
2.1. Configure Notifications via Telegram
Requirements: Bot token and chat ID from Telegram BotFather.
apprise -t "Test Notification" -b "Notification content" telegram://[token]/[chat_id]
2.2. Configure Notifications via Slack
Requirements: Slack webhook URL.
apprise -t "Test Notification" -b "Notification content" slack://[webhook_url]
2.3. Configure Notifications via Email
Requirements: SMTP configuration (e.g., Gmail, Outlook).
apprise -t "Test Notification" -b "Notification content" smtp://user:[email protected]:587
2.4. Configure Notifications via SMS (via Twilio)
Requirements: Twilio Account SID, Auth Token, and phone numbers.
apprise -t "Test Notification" -b "Notification content" twilio://[account_sid]:[auth_token]@from/[to]
3. Create an Apprise Configuration File (apprise-config.yaml)
To manage multiple notification platforms, create a configuration file:
# apprise-config.yaml
urls:
- telegram://[token]/[chat_id]
- slack://[webhook_url]
- smtp://user:[email protected]:587
- twilio://[account_sid]:[auth_token]@from/[to]
Save this file to /home/user/apprise-config.yaml and use the command:
apprise -c /home/user/apprise-config.yaml -t "Test Notification" -b "Notification content"
4. Send Notifications from Applications or Scripts
You can call Apprise from any application using shell commands or the Python library:
import apprise
# Create Apprise object
apprise_obj = apprise.Apprise()
# Add notification URLs
apprise_obj.add('telegram://[token]/[chat_id]')
apprise_obj.add('slack://[webhook_url]')
apprise_obj.add('smtp://user:[email protected]:587')
# Send notification
apprise_obj.notify(
body="Notification content",
title="Test Notification"
)
5. Test and Verify
Run the following command to test all configured platforms:
apprise -c /home/user/apprise-config.yaml -t "Notification Test" -b "This is a test notification"
If notifications are successfully sent to all platforms, the configuration is complete.
6. Troubleshooting
- Not receiving notifications? Verify the configuration URLs and access credentials (token, webhook, SMTP).
- Apprise does not recognize the URL? Ensure the URL format matches Apprise's documentation.
- Missing Python libraries? Reinstall with:
pip3 install apprise.
References
- Apprise GitHub Repository
- High-RAM Cloud VPS for Self-Hosted LLMs & API Gateways
- Cloud VPS RAM lớn cho Self-Host LLM & API Gateway
Assumptions
- The server is configured with SSH access and Python 3 installed.
- The user has access to the required accounts for each notification platform (Telegram, Slack, etc.).
- No additional platform-specific configuration is needed beyond basic credentials (token, webhook, SMTP).
Related infrastructure & engineering guides: Comprehensive Virtualization Data Protection: Deploying Proxmox Backup Server (PBS) on Hetzner VPS for Off-Site Backup
High-RAM Cloud VPS Plans Optimized for AI, Databases & Cache
Enterprise RAID 10 NVMe SSDs, CMC & FPT District 9 uplinks with Anycast Anti-DDoS and 99.99% SLA.
VPS-4E
10% VAT included
- CPU: 4 vCPU
- RAM: 8 GB
- SSD: 50 GB NVMe
