TMS notifications in Telegram — events, digests, 2FA
The challenge
The TMS team learned about events — a load ready to bill, an invoice paid, a warehouse arrival — from chats or by accident. A shared Telegram channel spammed everyone with everything. They needed personal notifications: everyone picks what they receive, routine summaries arrive as digests, and the warehouse sees its events in its own group.
What was built
A notification hub was built around Telegram: an event catalog in code, per-user subscriptions, real-time delivery and cron digests. The same channel was reused for two-factor login.
An event catalog with role-based subscriptions
admin, billing and dispatcher each see their own set of toggles; adding an event = one catalog entry plus one router call.
Account-to-Telegram linking via a one-time code
everyone gets messages personally, no shared chat.
Real-time events: load created / delivered / ready to bill, invoice paid
instantly, with details and a link.
Morning digests: the admin’s picture of the day (pickups, deliveries, ready to bill) and a billing digest; the endpoint is idempotent
no duplicates even if the cron fires twice.
Warehouse bots: CARRIER OUT summaries with BOL documents as PDFs, CARRIER IN alerts and a morning post about today’s arrivals
all into the warehouse group.
Telegram 2FA at login: a code in a direct message + trusted devices for 5 days.
Resilient cron infrastructure: primary runs on the hosting, GitHub Actions as a fallback
delivery doesn’t depend on a single scheduler.
The result
Everyone on the team gets only their own events, the morning digest replaced manual board checks, and the warehouse lives in one Telegram group where summaries with BOL documents arrive on their own. Two-factor login was closed with the same bot — no paid service required.
Tech stack
Have a similar challenge?
Discuss a projectNext case
Industry CRM
Print shop CRM — from order to signed act →