A CLI application that monitors your public IP address and sends Telegram notifications when it changes. Perfect for cloud VMs using NAT networks where upstream IPs may change.
- 5 IP Detection Services: ipify, ifconfig.me, ipinfo.io, api.ip.sb, icanhazip.com
- Automatic Fallback: If primary service fails, automatically tries others
- Telegram Notifications: Get notified when your IP changes
- Secure Storage: Credentials encrypted with AES-256-GCM
- IP History: Keeps last 500 IP changes in JSON format
- Daemon Mode: Continuously monitor IP at configurable intervals
Download the latest binary for your platform from Releases:
ip_detector-linux-x86_64- Linux (Intel/AMD)ip_detector-linux-arm64- Linux (ARM64)ip_detector-darwin-x86_64- macOS (Intel)ip_detector-darwin-arm64- macOS (Apple Silicon)
# Example for Linux x86_64
chmod +x ip_detector-linux-x86_64
./ip_detector-linux-x86_64On first run, the app will guide you through setup:
./ip_detectorYou'll be prompted to:
- Select an IP detection service
- Enter your Telegram Bot Token
- Enter your Telegram Chat ID
# Check current IP (no notification)
./ip_detector --check
# Check IP and send notification if changed
./ip_detector
# Send test notification
./ip_detector --test-notify
# Run in daemon mode (check every 5 minutes)
./ip_detector --daemon
# Run in daemon mode with custom interval (in seconds)
./ip_detector --daemon --interval 60
# Reconfigure the application
./ip_detector --reconfigureConfiguration is stored in ~/.ip_detector/:
config.json- Encrypted credentials and settingsip_history.json- Last 500 IP changes
# Copy binary and service file
sudo cp ip_detector /usr/local/bin/
sudo cp contrib/ip_detector@.service /etc/systemd/system/
# Enable and start for current user
sudo systemctl enable ip_detector@$USER
sudo systemctl start ip_detector@$USER
# Check status
sudo systemctl status ip_detector@$USER# Copy binary and init script
sudo cp ip_detector /usr/local/bin/
sudo cp contrib/ip_detector.openrc /etc/init.d/ip_detector.$USER
sudo chmod +x /etc/init.d/ip_detector.$USER
# Enable and start
sudo rc-update add ip_detector.$USER default
sudo rc-service ip_detector.$USER start-
Create a Bot: Message @BotFather on Telegram
- Send
/newbotand follow instructions - Copy the bot token provided
- Send
-
Get Chat ID:
- Message your new bot
- Visit
https://api.telegram.org/bot<YOUR_TOKEN>/getUpdates - Find your
chat.idin the response
MIT