node-telegram-bot-api 2.2.0 is out! 🗂 Sessions - createSession() +…

🚀 node-telegram-bot-api 2.2.0 is out!

🗂 Sessions - createSession() + ctx.getSession(), with Memory, File, SQLite, SQL and Redis stores (new /bun subpath). See Session example in 16-sessions
💬 Reply & callback tracking that survives restarts and works on serverless - expectReply, matchCallback, taggedReplies
♻️ Bot lifecycle - bot.init() / bot.close() for middleware that owns resources
🛡 Polling survives 409 Conflict, webhook shutdown can't hang, run({ exitOnError })
🔨 Fix: reset sticky RegExp state in Bot.hears() . Thanks sinzbtw
🔒 reply_markup accepts only one markup object (stricter types)

Everything new is opt-in - 2.1.0 bots run unchanged.

📦 npm i node-telegram-bot-api
📝 https://github.com/yagop/node-telegram-bot-api/releases/tag/v2.2.0
GitHub
node-telegram-bot-api/examples/16-sessions.ts at master · yagop/node-telegram-bot-api
Telegram Bot API for NodeJS. Contribute to yagop/node-telegram-bot-api development by creating an account on GitHub.
👍3❤1
November 2, 2026 459 1