WakeMe is a Telegram bot that helps you never miss your bus/train stop while traveling — especially useful when you're tired or sleeping during long journeys.
It tracks your location (bus) or train status (via PNR), and automatically wakes you up with voice calls ~30 minutes before arrival using AI-powered phone calls.
Current date reference: Project actively developed in 2025–2026
-
Bus Mode
- Share live location → bot tracks you in real-time
- Set destination (name or location pin)
- Calculates distance & ETA continuously
- Voice wake-up call when ~30 min away
-
Train Mode
- Enter 10-digit PNR number
- Fetches train name, route, timings via IRCTC
- Live train status tracking (current station, delay, stations left)
- Voice wake-up call when approaching destination
-
Smart Wake-up System
- Uses Bland.ai for natural Indian English voice calls
- Up to 5 retry attempts (2 min interval)
- Detects phrases like "I'm awake", "Yes I'm up"
- Leaves voicemail if not answered
- Escalates urgency in later attempts
-
Safety & Privacy
- Only asks for phone when needed
- Supports
/cancel,/awake,/statuscommands - Graceful handling of API failures & location issues
- Language: TypeScript
- Runtime: Node.js
- Telegram Bot Framework: Telegraf
- Database: PostgreSQL
- Voice Calls: Bland.ai API
- Train Status: irctc-connect (unofficial)
- Geocoding: Google Maps API (with Indian cities fallback)
- Server: Express (for webhook + health)
- Deployment Ready: Railway.app friendly structure
src/
├── config/ # env + constants
├── database/ # schema, queries, pool
├── handlers/ # telegram message/command/callback handlers
├── services/ # business logic (train, location, voice, telegram)
├── workers/ # background jobs (alerts, tracking)
├── types/ # shared interfaces
└── server.ts # main entry + bot + express
- Node.js 18+
- PostgreSQL database
- Telegram Bot Token
- Bland.ai API Key (https://bland.ai)
- Google Maps API Key (optional)
- Railway.app / VPS / any Node.js hosting
TELEGRAM_BOT_TOKEN=123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11
SERVER_URL=https://your-domain.com
PORT=3000
# Database
DATABASE_URL=postgresql://user:pass@host:5432/dbname
# Voice Calls
BLAND_API_KEY=sk_xxxxxxxxxxxxxxxxxxxxxxxxxxxx
# Optional - for better geocoding
GOOGLE_MAPS_API_KEY=AIzaSyCxxxxxxxxxxxxxxxxxxxxxxxxxxxx# Install dependencies
npm install
# Development (with hot reload)
npm run dev
# Build & start production
npm run build
npm start- Start →
/start - Choose Bus or Train
- Bus: Share Live Location (8 hours recommended)
- Train: Send 10-digit PNR
- Set destination (text or location pin for bus)
- Share phone number (needed for wake-up calls)
- Relax — bot will track & call you when close!
Useful commands:
/status → check current trip progress
/cancel → stop tracking & alerts
/awake → manually confirm you're awake
/help → show commands
- Indian trains only (IRCTC based)
- Bus tracking depends on user sharing live location continuously
- Voice call quality depends on Bland.ai credits & network
- No multi-leg journeys yet
- Geocoding fallback is very limited (top 10 cities only)
- Telegram & Telegraf community
- Bland.ai team for fantastic voice API
- Indian Railways passengers who sleep through stations 😴
Made with ☕ and late-night train journeys