[{"data":1,"prerenderedAt":207},["ShallowReactive",2],{"doc-\u002Fintegrations\u002Ftelegram":3},{"id":4,"title":5,"body":6,"description":197,"edit":198,"extension":199,"meta":200,"navigation":201,"path":202,"seo":203,"stem":204,"vertical":198,"weight":205,"__hash__":206},"content\u002Fintegrations\u002Ftelegram.md","Telegram",{"type":7,"value":8,"toc":188},"minimark",[9,13,18,47,55,74,77,81,84,94,104,108,119,126,132,135,139,142,148,151,155],[10,11,12],"p",{},"Telegram is the most-used alarm channel in our customer base. It is\nfree, instant, and a small café operator already has the app open\non their phone.",[14,15,17],"h2",{"id":16},"setup","Setup",[19,20,21,30,37,44],"ol",{},[22,23,24,25,29],"li",{},"In OpenSense: ",[26,27,28],"code",{},"Account → Integrations → Telegram → Link",".",[22,31,32,33,36],{},"The dialog shows a bot username (",[26,34,35],{},"@opensense_bot",") and a one-time\nlinking code.",[22,38,39,40,43],{},"Open Telegram. Search for the bot. Press ",[26,41,42],{},"Start",". Send the\nlinking code as a message.",[22,45,46],{},"The bot replies \"linked\". The dialog in OpenSense flips to\n\"active\".",[10,48,49,50,54],{},"To add ",[51,52,53],"strong",{},"another"," chat (e.g. a group of operators):",[19,56,57,60,71],{},[22,58,59],{},"Add the bot to the group as a member.",[22,61,62,63,66,67,70],{},"Send ",[26,64,65],{},"\u002Flink \u003Ccode>"," in the group, where ",[26,68,69],{},"\u003Ccode>"," is the per-site\nlinking code from the dashboard.",[22,72,73],{},"The bot confirms.",[10,75,76],{},"A group chat is recommended when an alarm should wake up more than\none person.",[14,78,80],{"id":79},"per-channel-routing","Per-channel routing",[10,82,83],{},"For sites with many devices, you may not want every alarm to ping\nevery operator. Route per channel:",[85,86,91],"pre",{"className":87,"code":89,"language":90},[88],"language-text","PATCH \u002Fv1\u002Fchannels\u002Fchn_a1b2\u002Fnotifications\n{\n  \"telegram_targets\": [\"@nightmgr\", \"@daymgr\"],\n  \"telegram_digest\": { \"min_interval_min\": 10 }\n}\n","text",[26,92,89],{"__ignoreMap":93},"",[10,95,96,99,100,103],{},[26,97,98],{},"telegram_digest.min_interval_min"," is the minimum gap between\nconsecutive notifications ",[51,101,102],{},"for the same channel",". Different\nchannels are not rate-limited against each other.",[14,105,107],{"id":106},"rate-limiting","Rate limiting",[10,109,110,111,114,115,118],{},"OpenSense rate-limits ",[51,112,113],{},"per-chat"," at 1 message per 10 s (Telegram\nBot API caps at 1\u002Fs; we add headroom for groups). Excess goes into a\nqueue visible in the dashboard's ",[26,116,117],{},"Outbound"," log; messages older than\n2 minutes are dropped with a single \"queue overflow\" summary instead.",[10,120,121,122,125],{},"To avoid flooding during a cascading failure (door propped open,\n12 channels in alarm), configure a ",[51,123,124],{},"digest",":",[85,127,130],{"className":128,"code":129,"language":90},[88],"PATCH \u002Fv1\u002Fsites\u002Fsite_4f3c\u002Fnotifications\n{\n  \"digest\": {\n    \"enabled\": true,\n    \"min_interval_min\": 30,\n    \"summary_only\": true\n  }\n}\n",[26,131,129],{"__ignoreMap":93},[10,133,134],{},"A site-wide digest collapses multiple channel alarms in the same\nwindow into one summary message. Auditors prefer this; chasing 12\nidentical messages is operator fatigue, not information.",[14,136,138],{"id":137},"message-format","Message format",[10,140,141],{},"A typical alarm message:",[85,143,146],{"className":144,"code":145,"language":90},[88],"🔴 ALARM\nKava Bratislava · walk-in fridge\nT = +11.2 °C  (allowed -2 to +8 °C)\nopened 08:10 · 4 min ago\nack: https:\u002F\u002Fopensense.murzin.digital\u002Fapp\u002Fe\u002Fevt_4f3c\n",[26,147,145],{"__ignoreMap":93},[10,149,150],{},"Tap the link to ack inline. The browser opens a tiny ack page that\nsets the cookie; one tap on the \"Acknowledged\" button records the\nack. No separate app to install.",[14,152,154],{"id":153},"what-you-give-up","What you give up",[156,157,158,176,182],"ul",{},[22,159,160,163,164,167,168,171,172,175],{},[51,161,162],{},"No two-way command-and-control."," The bot listens for ",[26,165,166],{},"\u002Flink",",\n",[26,169,170],{},"\u002Fack"," and ",[26,173,174],{},"\u002Fsilence","; it does not let you rotate tokens or edit\nrules from Telegram.",[22,177,178,181],{},[51,179,180],{},"Telegram-hosted."," If Telegram is blocked in your jurisdiction,\nuse email or webhook instead.",[22,183,184,187],{},[51,185,186],{},"No end-to-end encryption"," between us and your operator\n(Telegram Bot API uses MTProto-on-TLS but is not E2E). Do not put\nhighly-sensitive content in the alarm body; the alarm is a\nsignal, not a payload.",{"title":93,"searchDepth":189,"depth":189,"links":190},3,[191,193,194,195,196],{"id":16,"depth":192,"text":17},2,{"id":79,"depth":192,"text":80},{"id":106,"depth":192,"text":107},{"id":137,"depth":192,"text":138},{"id":153,"depth":192,"text":154},"Push alarms to a chat",null,"md",{},true,"\u002Fintegrations\u002Ftelegram",{"title":5,"description":197},"integrations\u002Ftelegram",610,"IPR6LH1fql9LMrBq12-_6uA7Ql6-gbS_OswGv8HhNIU",1779022955141]