Module

x/grammy/types.web.ts>Message

The Telegram Bot Framework.
Very Popular
Go to Latest
namespace Message
import { Message } from "https://dotland.deno.dev/x/grammy@v1.20.2/types.web.ts";

Type Aliases

interface Message
implements [Message.MediaMessage]
import { type Message } from "https://dotland.deno.dev/x/grammy@v1.20.2/types.web.ts";

Properties

optional
text: string

For text messages, the actual UTF-8 text of the message

optional
entities: MessageEntity[]

For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text

optional
animation: Animation

Message is an animation, information about the animation. For backward compatibility, when this field is set, the document field will also be set

optional
audio: Audio

Message is an audio file, information about the file

optional
document: Document

Message is a general file, information about the file

optional
photo: PhotoSize[]

Message is a photo, available sizes of the photo

optional
sticker: Sticker

Message is a sticker, information about the sticker

optional
story: Story

Message is a forwarded story

optional
video: Video

Message is a video, information about the video

optional
video_note: VideoNote

Message is a video note, information about the video message

optional
voice: Voice

Message is a voice message, information about the file

optional
contact: Contact

Message is a shared contact, information about the contact

optional
dice: Dice

Message is a dice with random value

optional
game: Game

Message is a game, information about the game. More about games »

optional
poll: Poll

Message is a native poll, information about the poll

optional
venue: Venue

Message is a venue, information about the venue. For backward compatibility, when this field is set, the location field will also be set

optional
location: Location

Message is a shared location, information about the location

optional
new_chat_members: User[]

New members that were added to the group or supergroup and information about them (the bot itself may be one of these members)

optional
left_chat_member: User

A member was removed from the group, information about them (this member may be the bot itself)

optional
new_chat_title: string

A chat title was changed to this value

optional
new_chat_photo: PhotoSize[]

A chat photo was change to this value

optional
delete_chat_photo: true

Service message: the chat photo was deleted

optional
group_chat_created: true

Service message: the group has been created

optional
supergroup_chat_created: true

Service message: the supergroup has been created. This field can't be received in a message coming through updates, because bot can't be a member of a supergroup when it is created. It can only be found in reply_to_message if someone replies to a very first message in a directly created supergroup.

optional
channel_chat_created: true

Service message: the channel has been created. This field can't be received in a message coming through updates, because bot can't be a member of a channel when it is created. It can only be found in reply_to_message if someone replies to a very first message in a channel.

optional
message_auto_delete_timer_changed: MessageAutoDeleteTimerChanged

Service message: auto-delete timer settings changed in the chat

optional
migrate_to_chat_id: number

The group has been migrated to a supergroup with the specified identifier.

optional
migrate_from_chat_id: number

The supergroup has been migrated from a group with the specified identifier.

optional
pinned_message: MaybeInaccessibleMessage

Specified message was pinned. Note that the Message object in this field will not contain further reply_to_message fields even if it itself is a reply.

optional
invoice: Invoice

Message is an invoice for a payment, information about the invoice. More about payments »

optional
successful_payment: SuccessfulPayment

Message is a service message about a successful payment, information about the payment. More about payments »

optional
users_shared: UsersShared

Service message: users were shared with the bot

optional
chat_shared: ChatShared

Service message: a chat was shared with the bot

optional
connected_website: string

The domain name of the website on which the user has logged in. More about Telegram Login »

optional
write_access_allowed: WriteAccessAllowed

Service message: the user allowed the bot to write messages after adding it to the attachment or side menu, launching a Web App from a link, or accepting an explicit request from a Web App sent by the method requestWriteAccess

optional
passport_data: PassportData

Telegram Passport data

optional
proximity_alert_triggered: ProximityAlertTriggered

Service message. A user in the chat triggered another user's proximity alert while sharing Live Location.

optional
forum_topic_created: ForumTopicCreated

Service message: forum topic created

optional
forum_topic_edited: ForumTopicEdited

Service message: forum topic edited

optional
forum_topic_closed: ForumTopicClosed

Service message: forum topic closed

optional
forum_topic_reopened: ForumTopicReopened

Service message: forum topic reopened

optional
general_forum_topic_hidden: GeneralForumTopicHidden

Service message: the 'General' forum topic hidden

optional
general_forum_topic_unhidden: GeneralForumTopicUnhidden

Service message: the 'General' forum topic unhidden

optional
giveaway_created: GiveawayCreated

Service message: a scheduled giveaway was created

optional
giveaway: Giveaway

The message is a scheduled giveaway message

optional
giveaway_winners: GiveawayWinners

A giveaway with public winners was completed

optional
giveaway_completed: GiveawayCompleted

Service message: a giveaway without public winners was completed

optional
video_chat_scheduled: VideoChatScheduled

Service message: video chat scheduled

optional
video_chat_started: VideoChatStarted

Service message: video chat started

optional
video_chat_ended: VideoChatEnded

Service message: video chat ended

optional
video_chat_participants_invited: VideoChatParticipantsInvited

Service message: new participants invited to a video chat

optional
web_app_data: WebAppData

Service message: data sent by a Web App

import Message
import { Message } from "https://dotland.deno.dev/x/grammy@v1.20.2/types.web.ts";