V18.0.0 π
First stable release of the V18 line. Migrates the underlying node-telegram-bot-api from v0.66 (CJS, request, bluebird) to v1.x (dual ESM+CJS, native fetch/undici, TypeScript). Promoted from beta to the latest dist-tag β Manage Palette will now offer it as the current version.
β οΈ Read MIGRATION.md before upgrading. Existing V17 flows keep working via a built-in legacy-options compatibility shim, but there are behavioural notes worth knowing.
Requirements
- Node.js β₯ 20.
What changed since V17
- New library core: native
fetch/undicitransport; droppedbluebirdandsocks-proxy-agent; addedundiciandfetch-socks. Dependency floornode-telegram-bot-api@^1.1.2. - Per-bot undici dispatcher β restores per-bot connection-pool / proxy isolation (SOCKS via
fetch-socks), with per-bot keep-alive-pool rebuild on recovery. - Synchronous
require()of the library (v1.1.2 restored CommonJS) β no dynamic-import bridge. callApiraw-API escape hatch βmsg.payload.type = "callApi"reaches any Bot API method without a dedicated type. See README β Calling the raw Bot API.editMessageMediauploads local files / Buffers / streams natively.- Legacy-options shim transparently rewrites deprecated
msg.payload.optionsforms (reply_to_message_id,thumb,disable_web_page_preview, keyboard string-shorthand,allow_sending_without_reply) with one-time deprecation warnings. - Carries forward all V17.4.13βV17.4.17 polling-recovery and queue-wedge fixes.
Upgrade
cd ~/.node-red
npm install node-red-contrib-telegrambot@latest
node-red-restart
Full detail in CHANGELOG.md (18.0.0 + the beta.1βbeta.4 entries) and #448.
Thanks to everyone who tested the betas β petermeter69, WJ4IoT, ajanulis, and others.