telegram-router
v1.0.5
Published
A simple and powerful telegram bot router
Readme
telegram-router
telegram-router is a simple javascript library that helps you to route messages from telegram bot to your application.
Installation
npm install telegram-routerUsage
import { TelegramRouter } from 'telegram-router'
const bot = new TelegramRouter<Response>();
bot.handleWith('/admin', UpdateType.Message, MatchType.Exact, async (update: Telegram.Update) => {
// handle message
});
bot.fetch(update);Example
- telegram-bot-workers-template: The basic template for running a Telegram Bot on Cloudflare Workers.
License
telegram-router is released under the MIT license. See LICENSE for details.
