npm telegraf 4.15.0
v4.15.0

latest releases: 4.16.3, 4.16.2, 4.16.1...
11 months ago

This is a rather minor release.

anyOf and allOf filter combinators

v4.11.0 introduced support for type-guard filters in Composer::on, which allowed you to filter updates based on their content.

This release adds two new combinators to the filter API: anyOf and allOf. This will play very nicely with custom filters. For example:

import { anyOf, allOf } from "telegraf/filters";

// must match all filters
bot.on(allOf(message(), isGroup), ctx => {
  // ...
});

Deprecating hookPath

The confusingly named hookPath in bot.launch webhook options is now deprecated. It will be removed in the next major release. You can start using path instead, today.


Meanwhile, we're working on new modules to add to the Telegraf ecosystem. Look forward to them, and join discussions in the official Telegraf chat!

Don't miss a new telegraf release

NewReleases is sending notifications on new releases.