class TelegramBot
extends TelegramApi
import { TelegramBot } from "https://deno.land/x/telegram_bot_api@0.4.0/src/telegram-bot/telegram-bot.ts";
Properties
private
readonly
updatesEventTarget: EventTargetprivate
optional
updatesStrategy: UpdatesStrategyMethods
private
handleUpdates(updates: Update[])protected
multipartRequest<T extends Method>(methodName: string, formData: FormData): ReturnType<T>handleUpdate(update: Update)
Handles update object from Telegram
on(eventType: UpdateType.Error, callback: (error: UpdateError) => void): void
on(eventType: UpdateType.Message, callback: (update: MessageUpdate) => void): void
on(eventType: UpdateType.EditedMessage, callback: (update: EditedMessageUpdate) => void): void
on(eventType: UpdateType.ChannelPost, callback: (update: ChannelPostUpdate) => void): void
on(eventType: UpdateType.EditedChannelPost, callback: (update: EditedChannelPostUpdate) => void): void
on(eventType: UpdateType.InlineQuery, callback: (update: InlineQueryUpdate) => void): void
on(eventType: UpdateType.ChosenInlineResult, callback: (update: ChosenInlineResultUpdate) => void): void
on(eventType: UpdateType.CallbackQuery, callback: (update: CallbackQueryUpdate) => void): void
on(eventType: UpdateType.ShippingQuery, callback: (update: ShippingQueryUpdate) => void): void
on(eventType: UpdateType.PreCheckoutQuery, callback: (update: PreCheckoutQueryUpdate) => void): void
on(eventType: UpdateType.Poll, callback: (update: PollUpdate) => void): void
on(eventType: UpdateType.PollAnswer, callback: (update: PollAnswerUpdate) => void): void
run(params: RunWithPollingParams): void
run(params: RunWithWebhookParams): void
stop()