@chat-adapter/telegram
4.43.0 · 19 Oct 2026MIT206.7k / weekRepositoryHomepagenpmAtom feed
34 stable releases, newest first, by release line. Notes are quoted as the maintainers published them.
4.43.0
19 Oct 2026Only updates dependencies:chat 4.43.0@chat-adapter/shared 4.43.0
4.42.0
14 Oct 20267d496a7: Count a reply to the bot as a mention (with
mentionOnReply) in regular supergroups. The forum-topic exclusion for replies to the topic's creation message now applies only to topic messages (is_topic_message), so ordinary replies, which carrymessage_thread_idequal to the replied-to message's id, are no longer dropped.
Patch Changes
7d496a7: Count a reply to the bot as a mention (with
mentionOnReply) in regular supergroups. The forum-topic exclusion for replies to the topic's creation message now applies only to topic messages (is_topic_message), so ordinary replies, which carrymessage_thread_idequal to the replied-to message's id, are no longer dropped.
4.41.1
28 Sep 2026Only updates dependencies:chat 4.41.1@chat-adapter/shared 4.41.1
4.41.0
18 Sep 2026f893470: Stop cutting Telegram MarkdownV2 messages and captions at a backtick inside a link destination. Messages that fit the length limit now ship exactly as rendered, and a length cut that lands inside a link, code span, or underline now removes the incomplete entity before the ellipsis.
91683e5: Wait for Telegram polling handlers to settle before advancing update offsets.
Patch Changes
f893470: Stop cutting Telegram MarkdownV2 messages and captions at a backtick inside a link destination. Messages that fit the length limit now ship exactly as rendered, and a length cut that lands inside a link, code span, or underline now removes the incomplete entity before the ellipsis.
91683e5: Wait for Telegram polling handlers to settle before advancing update offsets.
4.40.0
5 Sep 2026043386b: Add Telegram Business mode support. Opt in via
businessMode: true.The adapter handles
business_connection,business_message, andedited_business_messageupdates, encodes business threads astelegram:biz:{connectionId}:{chatId}, and passesbusiness_connection_idon outbound sends, edits, typing, file uploads, and inline-keyboard callbacks. Business threads are their own channel, slash commands route throughonSlashCommand, deletes usedeleteBusinessMessages, and connection state is cached in the state adapter so a revoked connection is honoured by every instance. Reactions on business threads throw aNotImplementedError, since the Bot API has no business variant ofsetMessageReaction.43dba3d: Skip unused plain-text conversion for rich and Markdown native draft updates. Plain-text fallback and final delivery keep their existing behavior.
Minor Changes
043386b: Add Telegram Business mode support. Opt in via
businessMode: true.The adapter handles
business_connection,business_message, andedited_business_messageupdates, encodes business threads astelegram:biz:{connectionId}:{chatId}, and passesbusiness_connection_idon outbound sends, edits, typing, file uploads, and inline-keyboard callbacks. Business threads are their own channel, slash commands route throughonSlashCommand, deletes usedeleteBusinessMessages, and connection state is cached in the state adapter so a revoked connection is honoured by every instance. Reactions on business threads throw aNotImplementedError, since the Bot API has no business variant ofsetMessageReaction.
Patch Changes
43dba3d: Skip unused plain-text conversion for rich and Markdown native draft updates. Plain-text fallback and final delivery keep their existing behavior.
4.39.0
28 Aug 2026c4a359e: require webhook verification by default with an explicit unverified opt-in
26a06ca: Add
mentionOnReply: when enabled, a reply to one of the bot's own messages reportsisMention, so a bot in a group keeps the conversation going without the handle being repeated. Off by default, so existing mention-only bots are unaffected, and readable fromTELEGRAM_MENTION_ON_REPLY. Implicit forum-topic replies and the bot's own echoed messages never count, and polling mode now retries the startupgetMelazily so a transient outage cannot leave mention detection disabled.d5ebec1: Implement
replyin the Telegram adapter soThread.reply()threads the answer to its target instead of throwingNotImplementedError. The reference travels as Bot APIreply_parametersand covers text, rich messages, documents, attachments and media groups;allow_sending_without_replykeeps delivery working when the target has been deleted. Malformed reply target ids are rejected before anything is sent, and a rich-message gateway that rejectsreply_parametersfalls back to a regular threaded send.
Minor Changes
c4a359e: require webhook verification by default with an explicit unverified opt-in
26a06ca: Add
mentionOnReply: when enabled, a reply to one of the bot's own messages reportsisMention, so a bot in a group keeps the conversation going without the handle being repeated. Off by default, so existing mention-only bots are unaffected, and readable fromTELEGRAM_MENTION_ON_REPLY. Implicit forum-topic replies and the bot's own echoed messages never count, and polling mode now retries the startupgetMelazily so a transient outage cannot leave mention detection disabled.d5ebec1: Implement
replyin the Telegram adapter soThread.reply()threads the answer to its target instead of throwingNotImplementedError. The reference travels as Bot APIreply_parametersand covers text, rich messages, documents, attachments and media groups;allow_sending_without_replykeeps delivery working when the target has been deleted. Malformed reply target ids are rejected before anything is sent, and a rich-message gateway that rejectsreply_parametersfalls back to a regular threaded send.a18e792: Describe the message kinds Telegram sends with no text and no file. A shared location, venue, contact, poll, dice, game, invoice or story used to arrive as an empty message: the payload carried the content, but a handler reading
textsaw nothing. Each now gets a short literal description (📍 55.75, 37.61,👤 Ada Lovelace +1555…,📊 Lunch or dinner?), and the structured payload stays on the raw message for anyone who needs the numbers.a0ba986: Parse stickers and animations. A sticker used to arrive as an empty message, since it carries no text, and an animation (Telegram GIF) was dropped entirely. A sticker now reports the emoji it stands for as its text (falling back to the sticker set name, then to "sticker") plus an attachment matching its real format: an image for a still WebP sticker, a video for a WebM one, a file for a Lottie (TGS) one. An animation arrives as a single video attachment; the redundant
documentfield Telegram sets alongside it for backward compatibility is no longer reported as a second attachment.
Patch Changes
eddcd7e: Return Telegram file downloads as portable ArrayBuffer data while preserving Buffer support in the shared attachment contract.
b6fa24c: guard attachment downloads across the remaining adapters
Slack, Discord, and WhatsApp attachment downloads now go through the shared guarded downloader: private and internal addresses are refused (as URL literals, through DNS resolution, and after redirects), responses are capped at 25 MB, and downloads time out after 30 seconds. Slack sends the bot token only on hops to trusted Slack origins, and WhatsApp keeps its access token on Meta's media hosts and the configured Graph origin. Telegram enforces the same size cap and timeout with the Web Fetch API so downloads keep working in runtimes like Cloudflare Workers.
downloadAttachmentin@chat-adapter/sharednow resolvesheadersper hop (pass a function to control what each redirect target receives), forwards the resolved headers to custom transports, and accepts anonResponsehook to reject unexpected final responses before the body is read.
4.38.1
17 Aug 2026Only updates dependencies:chat 4.38.1@chat-adapter/shared 4.38.1
4.38.0
14 Aug 20260f24cc3: Preserve normalized replied-to message context and populate it from Telegram replies.
7a1150c: Add outbound-only Vercel Connect authentication for Telegram while retaining native webhook verification or polling.
3bbf3ff: Use post-and-edit streaming by default and make native Telegram drafts opt-in. Streams now render the same way in every chat type; set the new
nativeStreaming: trueconfig option to restore draft previews in private chats.The adapter now owns the post-and-edit loop so edits stay under Telegram's per-chat rate limit. Edits are throttled to a 1100ms floor, configurable with the new
streamingEditIntervalMsoption, and a rate-limited final edit is retried once instead of failing the post.
Minor Changes
0f24cc3: Preserve normalized replied-to message context and populate it from Telegram replies.
7a1150c: Add outbound-only Vercel Connect authentication for Telegram while retaining native webhook verification or polling.
3bbf3ff: Use post-and-edit streaming by default and make native Telegram drafts opt-in. Streams now render the same way in every chat type; set the new
nativeStreaming: trueconfig option to restore draft previews in private chats.The adapter now owns the post-and-edit loop so edits stay under Telegram's per-chat rate limit. Edits are throttled to a 1100ms floor, configurable with the new
streamingEditIntervalMsoption, and a rate-limited final edit is retried once instead of failing the post.
Patch Changes
4.35.0
24 Jul 202654eea71: Add an optional Telegram user allowlist via
allowedUserIdsor the comma-separatedTELEGRAM_ALLOWED_USER_IDSenvironment variable.0701679: Cache the compiled bot-mention regex in
isBotMentionedinstead of recompiling it per message, and make the protectedsleephelper accept an optionalAbortSignalsostopPolling()interrupts the polling backoff delay immediately.
Minor Changes
54eea71: Add an optional Telegram user allowlist via
allowedUserIdsor the comma-separatedTELEGRAM_ALLOWED_USER_IDSenvironment variable.
Patch Changes
0701679: Cache the compiled bot-mention regex in
isBotMentionedinstead of recompiling it per message, and make the protectedsleephelper accept an optionalAbortSignalsostopPolling()interrupts the polling backoff delay immediately.
4.34.0
13 Jul 2026Reading the note…
4.33.0
7 Jul 2026Reading the note…
4.32.0
1 Jul 2026Reading the note…
4.31.0
16 Jun 2026Reading the note…
4.30.0
2 Jun 2026Reading the note…
4.29.0
18 May 2026Reading the note…
4.28.1
8 May 2026Reading the note…
4.27.0
30 Apr 2026Reading the note…
4.26.0
14 Apr 2026Reading the note…
4.25.0
11 Apr 2026Reading the note…
4.24.0
7 Apr 2026Reading the note…
4.23.0
26 Mar 2026Reading the note…
4.22.0
24 Mar 2026Reading the note…
4.21.0
23 Mar 2026Reading the note…
4.20.2
16 Mar 2026Reading the note…
4.20.1
12 Mar 2026Reading the note…
4.20.0
11 Mar 2026Reading the note…
4.19.0
10 Mar 2026Reading the note…
4.18.0
7 Mar 2026Reading the note…
4.17.0
6 Mar 2026Reading the note…
4.16.1
4 Mar 2026Reading the note…
4.16.0
4 Mar 2026Reading the note…
4.15.0
26 Feb 2026Reading the note…