A zero-cost, automated Telegram "Userbot" that intercepts stock restock alerts and triggers instant VoIP calls to your phone.
The Telegram Stock Alert Dialer is designed to solve a critical limitation with standard Telegram bots: Bots cannot read messages from other bots.
This project utilizes GramJS to run as a Userbot (acting on behalf of your personal account). It silently monitors a specific Telegram bot (e.g., Amul restock bot) for exact stock messages, extracts the product name and quantity, and leverages the free CallMeBot API to place a Text-to-Speech (TTS) voice call directly to your phone.
It features a remote-control interface built entirely inside your Telegram "Saved Messages", allowing you to snooze alerts or set strict quiet hours without ever touching code.
- 📱 Userbot Architecture: Intercepts messages that standard bots cannot see.
- 🎙️ Instant VoIP Calls: Triggers a free TTS phone call alerting you of the exact product and quantity.
- 💬 In-Chat Dashboard: Control the bot remotely by sending commands to your Telegram "Saved Messages".
- ⏳ Smart Scheduling: Set 24-hour time windows (in IST) to prevent the bot from waking you up at night.
- 🐳 Cloud-Ready: Pre-configured
Dockerfileand dummy web-server for easy deployment to 100% free hosting providers (like Render or Koyeb).
You will need to gather a few free API keys and IDs before starting:
- Telegram API ID & Hash: Get this by creating an application at my.telegram.org.
- CallMeBot Authorization: Message
@CallMeBot_APIon Telegram or visit this link to authorize Voice Calls. - Target Bot ID: The exact username of the restock bot you want to monitor (e.g.,
@AmulAlertBot).
Clone the repository and install dependencies:
git clone https://github.com/kuanarshubham/AmulCallMe.git
cd AmulCallMe
npm installBecause this uses a Userbot, you need to authenticate your account locally once to generate a session cookie.
npx ts-node scripts/generateSession.tsFollow the interactive prompts. Once completed, it will output a long string. Copy it!
Create a .env file in the root directory and populate it:
TELEGRAM_API_ID=your_api_id
TELEGRAM_API_HASH=your_api_hash
TELEGRAM_SESSION=your_long_session_string
TARGET_BOT_ID=@target_restock_bot
CALLMEBOT_USERNAME=@your_telegram_usernamenpm run build
npm startNote: You can trigger a test call by sending /call to your Telegram "Saved Messages" chat.
Send these commands to your own Saved Messages chat in Telegram to control the bot:
| Command | Description |
|---|---|
/snooze |
Pauses all VoIP calls for exactly 20 days. |
/resume |
Clears the snooze timer and resumes normal operation. |
/call-timing HH:MM-HH:MM |
Sets a strict allowed calling window in IST (e.g., 09:00-22:00). |
/call |
Triggers a test VoIP call immediately. |
/help |
Displays the list of available commands. |
This project is perfectly optimized to run on Render's Free Tier without a credit card.
- Create a New Web Service on Render and connect this repository.
- Render will automatically detect the
Dockerfile. - Add your 5
.envvariables in the Environment Variables section on the Render dashboard. - Deploy!
- Important: Render spins down free web services after 15 minutes of inactivity. Use a free pinging service like UptimeRobot to ping your Render URL every 10 minutes to keep the bot alive 24/7.
- Node.js & TypeScript
- GramJS - Telegram MTProto API framework
- CallMeBot - Free VoIP Call API
- date-fns-tz - Timezone management
This project is licensed under the MIT License - see the LICENSE file for details.
