Socket
Socket
Sign inDemoInstall

@grammyjs/types

Package Overview
Dependencies
Maintainers
1
Versions
84
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@grammyjs/types - npm Package Compare versions

Comparing version 2.6.0 to 2.7.0

markup.d.ts

3

index.d.ts
export * from "./api";
export * from "./callback";
export * from "./inline";
export * from "./manage";
export * from "./markup";
export * from "./menu-button";
export * from "./message";

@@ -6,0 +7,0 @@ export * from "./passport";

import { Chat, User } from "./manage";
import { InlineKeyboardMarkup } from "./markup";
import { Location, MessageEntity, ParseMode } from "./message";

@@ -15,3 +16,3 @@ import { LabeledPrice } from "./payment";

offset: string;
/** Type of the chat, from which the inline query was sent. Can be either “sender” for a private chat with the inline query sender, “private”, “group”, “supergroup”, or “channel”. The chat type should be always known for requests sent from official clients and most third-party clients, unless the request was sent from a secret chat */
/** Type of the chat, from which the inline query was sent. Can be either "sender" for a private chat with the inline query sender, "private", "group", "supergroup", or "channel". The chat type should be always known for requests sent from official clients and most third-party clients, unless the request was sent from a secret chat */
chat_type?: "sender" | Chat["type"];

@@ -22,80 +23,2 @@ /** Sender location, only for bots that request user location */

/** This object represents an inline keyboard that appears right next to the message it belongs to. */
export interface InlineKeyboardMarkup {
/** Array of button rows, each represented by an Array of InlineKeyboardButton objects */
inline_keyboard: InlineKeyboardButton[][];
}
export namespace InlineKeyboardButton {
interface AbstractInlineKeyboardButton {
/** Label text on the button */
text: string;
}
export interface UrlButton extends AbstractInlineKeyboardButton {
/** HTTP or tg:// url to be opened when the button is pressed. Links tg://user?id=<user_id> can be used to mention a user by their ID without using a username, if this is allowed by their privacy settings. */
url: string;
}
export interface LoginButton extends AbstractInlineKeyboardButton {
/** An HTTP URL used to automatically authorize the user. Can be used as a replacement for the Telegram Login Widget. */
login_url: LoginUrl;
}
export interface CallbackButton extends AbstractInlineKeyboardButton {
/** Data to be sent in a callback query to the bot when button is pressed, 1-64 bytes */
callback_data: string;
}
export interface SwitchInlineButton extends AbstractInlineKeyboardButton {
/** If set, pressing the button will prompt the user to select one of their chats, open that chat and insert the bot's username and the specified inline query in the input field. Can be empty, in which case just the bot's username will be inserted.
Note: This offers an easy way for users to start using your bot in inline mode when they are currently in a private chat with it. Especially useful when combined with switch_pm… actions – in this case the user will be automatically returned to the chat they switched from, skipping the chat selection screen. */
switch_inline_query: string;
}
export interface SwitchInlineCurrentChatButton
extends AbstractInlineKeyboardButton {
/** If set, pressing the button will insert the bot's username and the specified inline query in the current chat's input field. Can be empty, in which case only the bot's username will be inserted.
This offers a quick way for the user to open your bot in inline mode in the same chat – good for selecting something from multiple options. */
switch_inline_query_current_chat: string;
}
export interface GameButton extends AbstractInlineKeyboardButton {
/** Description of the game that will be launched when the user presses the button.
NOTE: This type of button must always be the first button in the first row. */
callback_game: CallbackGame;
}
export interface PayButton extends AbstractInlineKeyboardButton {
/** Specify True, to send a Pay button.
NOTE: This type of button must always be the first button in the first row and can only be used in invoice messages. */
pay: boolean;
}
}
/** This object represents one button of an inline keyboard. You must use exactly one of the optional fields. */
export type InlineKeyboardButton =
| InlineKeyboardButton.CallbackButton
| InlineKeyboardButton.GameButton
| InlineKeyboardButton.LoginButton
| InlineKeyboardButton.PayButton
| InlineKeyboardButton.SwitchInlineButton
| InlineKeyboardButton.SwitchInlineCurrentChatButton
| InlineKeyboardButton.UrlButton;
/** This object represents a parameter of the inline keyboard button used to automatically authorize a user. Serves as a great replacement for the Telegram Login Widget when the user is coming from Telegram. All the user needs to do is tap/click a button and confirm that they want to log in.
Telegram apps support these buttons as of version 5.7. */
export interface LoginUrl {
/** An HTTP URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in Receiving authorization data.
NOTE: You must always check the hash of the received data to verify the authentication and the integrity of the data as described in Checking authorization. */
url: string;
/** New text of the button in forwarded messages. */
forward_text?: string;
/** Username of a bot, which will be used for user authorization. See Setting up a bot for more details. If not specified, the current bot's username will be assumed. The url's domain must be the same as the domain linked with the bot. See Linking your domain to the bot for more details. */
bot_username?: string;
/** Pass True to request the permission for your bot to send messages to the user. */
request_write_access?: boolean;
}
/** A placeholder, currently holds no information. Use BotFather to set up your game. */
export interface CallbackGame {}
/** This object represents one result of an inline query. Telegram clients currently support results of the following 20 types:

@@ -218,3 +141,3 @@ - InlineQueryResultCachedAudio

thumb_url: string;
/** MIME type of the thumbnail, must be one of “image/jpeg”, “image/gif”, or “video/mp4”. Defaults to “image/jpeg” */
/** MIME type of the thumbnail, must be one of "image/jpeg", "image/gif", or "video/mp4". Defaults to "image/jpeg" */
thumb_mime_type?: "image/jpeg" | "image/gif" | "video/mp4";

@@ -249,3 +172,3 @@ /** Title for the result */

thumb_url: string;
/** MIME type of the thumbnail, must be one of “image/jpeg”, “image/gif”, or “video/mp4”. Defaults to “image/jpeg” */
/** MIME type of the thumbnail, must be one of "image/jpeg", "image/gif", or "video/mp4". Defaults to "image/jpeg" */
thumb_mime_type?: "image/jpeg" | "image/gif" | "video/mp4";

@@ -274,3 +197,3 @@ /** Title for the result */

video_url: string;
/** Mime type of the content of video url, “text/html” or “video/mp4” */
/** Mime type of the content of video url, "text/html" or "video/mp4" */
mime_type: "text/html" | "video/mp4";

@@ -439,3 +362,3 @@ /** URL of the thumbnail (JPEG only) for the video */

foursquare_id?: string;
/** Foursquare type of the venue, if known. (For example, “arts_entertainment/default”, “arts_entertainment/aquarium” or “food/icecream”.) */
/** Foursquare type of the venue, if known. (For example, "arts_entertainment/default", "arts_entertainment/aquarium" or "food/icecream".) */
foursquare_type?: string;

@@ -729,3 +652,3 @@ /** Google Places identifier of the venue */

foursquare_id?: string;
/** Foursquare type of the venue, if known. (For example, “arts_entertainment/default”, “arts_entertainment/aquarium” or “food/icecream”.) */
/** Foursquare type of the venue, if known. (For example, "arts_entertainment/default", "arts_entertainment/aquarium" or "food/icecream".) */
foursquare_type?: string;

@@ -732,0 +655,0 @@ /** Google Places identifier of the venue */

@@ -18,2 +18,4 @@ import { Location, Message, PhotoSize } from "./message";

last_error_message: string;
/** Unix time of the most recent error that happened when trying to synchronize available updates with Telegram datacenters */
last_synchronization_error_date?: number;
/** Maximum allowed number of simultaneous HTTPS connections to the webhook for update delivery */

@@ -57,3 +59,3 @@ max_connections: number;

interface AbstractChat {
/** Type of chat, can be either “private”, “group”, “supergroup” or “channel” */
/** Type of chat, can be either "private", "group", "supergroup" or "channel" */
type: string;

@@ -91,3 +93,5 @@ /** Unique identifier for this chat. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this identifier. */

export interface SupergroupChat
extends AbstractChat, UserNameChat, TitleChat {
extends AbstractChat,
UserNameChat,
TitleChat {
type: "supergroup";

@@ -144,3 +148,5 @@ }

export interface SupergroupGetChat
extends SupergroupChat, MultiUserGetChat, LargeGetChat {
extends SupergroupChat,
MultiUserGetChat,
LargeGetChat {
/** For supergroups, the minimum allowed delay between consecutive messages sent by each unpriviledged user; in seconds. Returned only in getChat. */

@@ -193,3 +199,3 @@ slow_mode_delay?: number;

export interface ChatInviteLink {
/** The invite link. If the link was created by another chat administrator, then the second part of the link will be replaced with “…”. */
/** The invite link. If the link was created by another chat administrator, then the second part of the link will be replaced with "...". */
invite_link: string;

@@ -214,2 +220,28 @@ /** Creator of the link */

/** Represents the rights of an administrator in a chat. */
export interface ChatAdministratorRights {
/** True, if the user's presence in the chat is hidden */
is_anonymous: boolean;
/** True, if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege */
can_manage_chat: boolean;
/** True, if the administrator can delete messages of other users */
can_delete_messages: boolean;
/** True, if the administrator can manage video chats */
can_manage_video_chats: boolean;
/** True, if the administrator can restrict, ban or unban chat members */
can_restrict_members: boolean;
/** True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that he has promoted, directly or indirectly (promoted by administrators that were appointed by the user) */
can_promote_members: boolean;
/** True, if the user is allowed to change the chat title, photo and other settings */
can_change_info: boolean;
/** True, if the user is allowed to invite new users to the chat */
can_invite_users: boolean;
/** True, if the administrator can post in the channel; channels only */
can_post_messages?: boolean;
/** True, if the administrator can edit messages of other users and can pin messages; channels only */
can_edit_messages?: boolean;
/** True, if the user is allowed to pin messages; groups and supergroups only */
can_pin_messages?: boolean;
}
/** This object contains information about one member of a chat. Currently, the following 6 types of chat members are supported:

@@ -232,3 +264,3 @@ - ChatMemberOwner

export interface ChatMemberOwner {
/** The member's status in the chat, always “creator” */
/** The member's status in the chat, always "creator" */
status: "creator";

@@ -245,3 +277,3 @@ /** Information about the user */

export interface ChatMemberAdministrator {
/** The member's status in the chat, always “administrator” */
/** The member's status in the chat, always "administrator" */
status: "administrator";

@@ -258,4 +290,4 @@ /** Information about the user */

can_delete_messages: boolean;
/** True, if the administrator can manage voice chats */
can_manage_voice_chats: boolean;
/** True, if the administrator can manage video chats */
can_manage_video_chats: boolean;
/** True, if the administrator can restrict, ban or unban chat members */

@@ -281,3 +313,3 @@ can_restrict_members: boolean;

export interface ChatMemberMember {
/** The member's status in the chat, always “member” */
/** The member's status in the chat, always "member" */
status: "member";

@@ -290,3 +322,3 @@ /** Information about the user */

export interface ChatMemberRestricted {
/** The member's status in the chat, always “restricted” */
/** The member's status in the chat, always "restricted" */
status: "restricted";

@@ -319,3 +351,3 @@ /** Information about the user */

export interface ChatMemberLeft {
/** The member's status in the chat, always “left” */
/** The member's status in the chat, always "left" */
status: "left";

@@ -328,3 +360,3 @@ /** Information about the user */

export interface ChatMemberBanned {
/** The member's status in the chat, always “kicked” */
/** The member's status in the chat, always "kicked" */
status: "kicked";

@@ -331,0 +363,0 @@ /** Information about the user */

@@ -1,2 +0,2 @@

import { InlineKeyboardMarkup } from "./inline";
import { InlineKeyboardMarkup } from "./markup";
import { Chat, User } from "./manage";

@@ -75,55 +75,40 @@ import { PassportData } from "./passport";

export type VenueMessage = LocationMessage & MsgWith<"venue">;
export type NewChatMembersMessage =
& ServiceMessage
& MsgWith<"new_chat_members">;
export type LeftChatMemberMessage =
& ServiceMessage
& MsgWith<"left_chat_member">;
export type NewChatMembersMessage = ServiceMessage &
MsgWith<"new_chat_members">;
export type LeftChatMemberMessage = ServiceMessage &
MsgWith<"left_chat_member">;
export type NewChatTitleMessage = ServiceMessage & MsgWith<"new_chat_title">;
export type NewChatPhotoMessage = ServiceMessage & MsgWith<"new_chat_photo">;
export type DeleteChatPhotoMessage =
& ServiceMessage
& MsgWith<"delete_chat_photo">;
export type GroupChatCreatedMessage =
& ServiceMessage
& MsgWith<"group_chat_created">;
export type SupergroupChatCreated =
& ServiceMessage
& MsgWith<"supergroup_chat_created">;
export type ChannelChatCreatedMessage =
& ServiceMessage
& MsgWith<"channel_chat_created">;
export type MessageAutoDeleteTimerChangedMessage =
& ServiceMessage
& MsgWith<"message_auto_delete_timer_changed">;
export type MigrateToChatIdMessage =
& ServiceMessage
& MsgWith<"migrate_to_chat_id">;
export type MigrateFromChatIdMessage =
& ServiceMessage
& MsgWith<"migrate_from_chat_id">;
export type DeleteChatPhotoMessage = ServiceMessage &
MsgWith<"delete_chat_photo">;
export type GroupChatCreatedMessage = ServiceMessage &
MsgWith<"group_chat_created">;
export type SupergroupChatCreated = ServiceMessage &
MsgWith<"supergroup_chat_created">;
export type ChannelChatCreatedMessage = ServiceMessage &
MsgWith<"channel_chat_created">;
export type MessageAutoDeleteTimerChangedMessage = ServiceMessage &
MsgWith<"message_auto_delete_timer_changed">;
export type MigrateToChatIdMessage = ServiceMessage &
MsgWith<"migrate_to_chat_id">;
export type MigrateFromChatIdMessage = ServiceMessage &
MsgWith<"migrate_from_chat_id">;
export type PinnedMessageMessage = ServiceMessage & MsgWith<"pinned_message">;
export type InvoiceMessage = ServiceMessage & MsgWith<"invoice">;
export type SuccessfulPaymentMessage =
& ServiceMessage
& MsgWith<"successful_payment">;
export type ConnectedWebsiteMessage =
& ServiceMessage
& MsgWith<"connected_website">;
export type SuccessfulPaymentMessage = ServiceMessage &
MsgWith<"successful_payment">;
export type ConnectedWebsiteMessage = ServiceMessage &
MsgWith<"connected_website">;
export type PassportDataMessage = ServiceMessage & MsgWith<"passport_data">;
export type ProximityAlertTriggeredMessage =
& ServiceMessage
& MsgWith<"proximity_alert_triggered">;
export type VoiceChatScheduledMessage =
& ServiceMessage
& MsgWith<"voice_chat_scheduled">;
export type VoiceChatStartedMessage =
& ServiceMessage
& MsgWith<"voice_chat_started">;
export type VoiceChatEndedMessage =
& ServiceMessage
& MsgWith<"voice_chat_ended">;
export type VoiceChatParticipantsInvitedMessage =
& ServiceMessage
& MsgWith<"voice_chat_participants_invited">;
export type ProximityAlertTriggeredMessage = ServiceMessage &
MsgWith<"proximity_alert_triggered">;
export type VideoChatScheduledMessage = ServiceMessage &
MsgWith<"video_chat_scheduled">;
export type VideoChatStartedMessage = ServiceMessage &
MsgWith<"video_chat_started">;
export type VideoChatEndedMessage = ServiceMessage &
MsgWith<"video_chat_ended">;
export type VideoChatParticipantsInvitedMessage = ServiceMessage &
MsgWith<"video_chat_participants_invited">;
export type WebAppDataMessage = ServiceMessage & MsgWith<"web_app_data">;
}

@@ -201,9 +186,12 @@

/** Service message: voice chat scheduled */
voice_chat_scheduled?: VoiceChatScheduled;
/** Service message: voice chat started */
voice_chat_started?: VoiceChatStarted;
/** Service message: voice chat ended */
voice_chat_ended?: VoiceChatEnded;
/** Service message: new participants invited to a voice chat */
voice_chat_participants_invited?: VoiceChatParticipantsInvited;
/** Service message: video chat scheduled */
video_chat_scheduled?: VideoChatScheduled;
/** Service message: video chat started */
video_chat_started?: VideoChatStarted;
/** Service message: video chat ended */
video_chat_ended?: VideoChatEnded;
/** Service message: new participants invited to a video chat */
video_chat_participants_invited?: VideoChatParticipantsInvited;
/** Service message: data sent by a Web App */
web_app_data?: WebAppData;
}

@@ -217,2 +205,8 @@

/** Contains information about an inline message sent by a Web App on behalf of a user. */
export interface SentWebAppMessage {
/** Identifier of the sent inline message. Available only if there is an inline keyboard attached to the message. */
inline_message_id: string;
}
/** The Bot API supports basic formatting for messages. You can use bold, italic, underlined, strikethrough, and spoiler text, as well as inline links and pre-formatted code in your bots' messages. Telegram clients will render them accordingly. You can use either markdown-style or HTML-style formatting.

@@ -311,3 +305,3 @@

interface AbstractMessageEntity {
/** Type of the entity. Currently, can be “mention” (@username), “hashtag” (#hashtag), “cashtag” ($USD), “bot_command” (/start@jobs_bot), “url” (https://telegram.org), “email” (do-not-reply@telegram.org), “phone_number” (+1-212-555-0123), “bold” (bold text), “italic” (italic text), “underline” (underlined text), “strikethrough” (strikethrough text), “spoiler” (spoiler message), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users without usernames) */
/** Type of the entity. Currently, can be "mention" (@username), "hashtag" (#hashtag), "cashtag" ($USD), "bot_command" (/start@jobs_bot), "url" (https://telegram.org), "email" (do-not-reply@telegram.org), "phone_number" (+1-212-555-0123), "bold" (bold text), "italic" (italic text), "underline" (underlined text), "strikethrough" (strikethrough text), "spoiler" (spoiler message), "code" (monowidth string), "pre" (monowidth block), "text_link" (for clickable text URLs), "text_mention" (for users without usernames) */
type: string;

@@ -337,3 +331,3 @@ /** Offset in UTF-16 code units to the start of the entity */

type: "text_link";
/** For “text_link” only, url that will be opened after user taps on the text */
/** For "text_link" only, url that will be opened after user taps on the text */
url: string;

@@ -343,3 +337,3 @@ }

type: "text_mention";
/** For “text_mention” only, the mentioned user */
/** For "text_mention" only, the mentioned user */
user: User;

@@ -349,3 +343,3 @@ }

type: "pre";
/** For “pre” only, the programming language of the entity text */
/** For "pre" only, the programming language of the entity text */
language?: string;

@@ -506,3 +500,3 @@ }

emoji: string;
/** Value of the dice, 1-6 for “🎲”, “🎯” and “🎳” base emoji, 1-5 for “🏀” and “⚽” base emoji, 1-64 for “🎰” base emoji */
/** Value of the dice, 1-6 for "🎲", "🎯" and "🎳" base emoji, 1-5 for "🏀" and "⚽" base emoji, 1-64 for "🎰" base emoji */
value: number;

@@ -543,3 +537,3 @@ }

is_anonymous: boolean;
/** Poll type, currently can be “regular” or “quiz” */
/** Poll type, currently can be "regular" or "quiz" */
type: "regular" | "quiz";

@@ -586,3 +580,3 @@ /** True, if the poll allows multiple answers */

foursquare_id?: string;
/** Foursquare type of the venue. (For example, “arts_entertainment/default”, “arts_entertainment/aquarium” or “food/icecream”.) */
/** Foursquare type of the venue. (For example, "arts_entertainment/default", "arts_entertainment/aquarium" or "food/icecream".) */
foursquare_type?: string;

@@ -611,23 +605,31 @@ /** Google Places identifier of the venue */

/** This object represents a service message about a voice chat scheduled in the chat. */
export interface VoiceChatScheduled {
/** Point in time (Unix timestamp) when the voice chat is supposed to be started by a chat administrator */
/** This object represents a service message about a video chat scheduled in the chat. */
export interface VideoChatScheduled {
/** Point in time (Unix timestamp) when the video chat is supposed to be started by a chat administrator */
start_date: number;
}
/** This object represents a service message about a voice chat started in the chat. Currently holds no information. */
export interface VoiceChatStarted {}
/** This object represents a service message about a video chat started in the chat. Currently holds no information. */
export interface VideoChatStarted {}
/** This object represents a service message about a voice chat ended in the chat. */
export interface VoiceChatEnded {
/** Voice chat duration in seconds */
/** This object represents a service message about a video chat ended in the chat. */
export interface VideoChatEnded {
/** Video chat duration in seconds */
duration: number;
}
/** This object represents a service message about new members invited to a voice chat. */
export interface VoiceChatParticipantsInvited {
/** New members that were invited to the voice chat */
/** This object represents a service message about new members invited to a video chat. */
export interface VideoChatParticipantsInvited {
/** New members that were invited to the video chat */
users: User[];
}
/** Contains data sent from a Web App to the bot. */
export interface WebAppData {
/** The data. Be aware that a bad client can send arbitrary data in this field. */
data: string;
/** Text of the web_app keyboard button, from which the Web App was opened. Be aware that a bad client can send arbitrary data in this field. */
button_text: string;
}
/** This object represents a sticker. */

@@ -679,3 +681,3 @@ export interface Sticker {

export interface MaskPosition {
/** The part of the face relative to which the mask should be placed. One of “forehead”, “eyes”, “mouth”, or “chin”. */
/** The part of the face relative to which the mask should be placed. One of "forehead", "eyes", "mouth", or "chin". */
point: "forehead" | "eyes" | "mouth" | "chin";

@@ -682,0 +684,0 @@ /** Shift by X-axis measured in widths of the mask scaled to the face size, from left to right. For example, choosing -1.0 will place mask just to the left of the default mask position. */

{
"name": "@grammyjs/types",
"version": "2.6.0",
"version": "2.7.0",
"description": "Telegram Bot API type declarations for grammY",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -23,3 +23,3 @@ /** Contains information about Telegram Passport data shared with the bot by the user. */

export interface EncryptedPassportElement {
/** Element type. One of “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport”, “address”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration”, “phone_number”, “email”. */
/** Element type. One of "personal_details", "passport", "driver_license", "identity_card", "internal_passport", "address", "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration", "phone_number", "email". */
type:

@@ -39,17 +39,17 @@ | "personal_details"

| "email";
/** Base64-encoded encrypted Telegram Passport element data provided by the user, available for “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport” and “address” types. Can be decrypted and verified using the accompanying EncryptedCredentials. */
/** Base64-encoded encrypted Telegram Passport element data provided by the user, available for "personal_details", "passport", "driver_license", "identity_card", "internal_passport" and "address" types. Can be decrypted and verified using the accompanying EncryptedCredentials. */
data?: string;
/** User's verified phone number, available only for “phone_number” type */
/** User's verified phone number, available only for "phone_number" type */
phone_number?: string;
/** User's verified email address, available only for “email” type */
/** User's verified email address, available only for "email" type */
email?: string;
/** Array of encrypted files with documents provided by the user, available for “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials. */
/** Array of encrypted files with documents provided by the user, available for "utility_bill", "bank_statement", "rental_agreement", "passport_registration" and "temporary_registration" types. Files can be decrypted and verified using the accompanying EncryptedCredentials. */
files?: PassportFile[];
/** Encrypted file with the front side of the document, provided by the user. Available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials. */
/** Encrypted file with the front side of the document, provided by the user. Available for "passport", "driver_license", "identity_card" and "internal_passport". The file can be decrypted and verified using the accompanying EncryptedCredentials. */
front_side?: PassportFile;
/** Encrypted file with the reverse side of the document, provided by the user. Available for “driver_license” and “identity_card”. The file can be decrypted and verified using the accompanying EncryptedCredentials. */
/** Encrypted file with the reverse side of the document, provided by the user. Available for "driver_license" and "identity_card". The file can be decrypted and verified using the accompanying EncryptedCredentials. */
reverse_side?: PassportFile;
/** Encrypted file with the selfie of the user holding a document, provided by the user; available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials. */
/** Encrypted file with the selfie of the user holding a document, provided by the user; available for "passport", "driver_license", "identity_card" and "internal_passport". The file can be decrypted and verified using the accompanying EncryptedCredentials. */
selfie?: PassportFile;
/** Array of encrypted files with translated versions of documents provided by the user. Available if requested for “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials. */
/** Array of encrypted files with translated versions of documents provided by the user. Available if requested for "passport", "driver_license", "identity_card", "internal_passport", "utility_bill", "bank_statement", "rental_agreement", "passport_registration" and "temporary_registration" types. Files can be decrypted and verified using the accompanying EncryptedCredentials. */
translation?: PassportFile[];

@@ -96,3 +96,3 @@ /** Base64-encoded element hash for using in PassportElementErrorUnspecified */

source: "data";
/** The section of the user's Telegram Passport which has the error, one of “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport”, “address” */
/** The section of the user's Telegram Passport which has the error, one of "personal_details", "passport", "driver_license", "identity_card", "internal_passport", "address" */
type:

@@ -117,3 +117,3 @@ | "personal_details"

source: "front_side";
/** The section of the user's Telegram Passport which has the issue, one of “passport”, “driver_license”, “identity_card”, “internal_passport” */
/** The section of the user's Telegram Passport which has the issue, one of "passport", "driver_license", "identity_card", "internal_passport" */
type: "passport" | "driver_license" | "identity_card" | "internal_passport";

@@ -130,3 +130,3 @@ /** Base64-encoded hash of the file with the front side of the document */

source: "reverse_side";
/** The section of the user's Telegram Passport which has the issue, one of “driver_license”, “identity_card” */
/** The section of the user's Telegram Passport which has the issue, one of "driver_license", "identity_card" */
type: "driver_license" | "identity_card";

@@ -143,3 +143,3 @@ /** Base64-encoded hash of the file with the reverse side of the document */

source: "selfie";
/** The section of the user's Telegram Passport which has the issue, one of “passport”, “driver_license”, “identity_card”, “internal_passport” */
/** The section of the user's Telegram Passport which has the issue, one of "passport", "driver_license", "identity_card", "internal_passport" */
type: "passport" | "driver_license" | "identity_card" | "internal_passport";

@@ -156,3 +156,3 @@ /** Base64-encoded hash of the file with the selfie */

source: "file";
/** The section of the user's Telegram Passport which has the issue, one of “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration” */
/** The section of the user's Telegram Passport which has the issue, one of "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration" */
type:

@@ -174,3 +174,3 @@ | "utility_bill"

source: "files";
/** The section of the user's Telegram Passport which has the issue, one of “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration” */
/** The section of the user's Telegram Passport which has the issue, one of "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration" */
type:

@@ -192,3 +192,3 @@ | "utility_bill"

source: "translation_file";
/** Type of element of the user's Telegram Passport which has the issue, one of “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration” */
/** Type of element of the user's Telegram Passport which has the issue, one of "passport", "driver_license", "identity_card", "internal_passport", "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration" */
type:

@@ -214,3 +214,3 @@ | "passport"

source: "translation_files";
/** Type of element of the user's Telegram Passport which has the issue, one of “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration” */
/** Type of element of the user's Telegram Passport which has the issue, one of "passport", "driver_license", "identity_card", "internal_passport", "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration" */
type:

@@ -217,0 +217,0 @@ | "passport"

@@ -1,2 +0,2 @@

import { CallbackQuery } from "./callback";
import { CallbackQuery } from "./markup";
import { ChosenInlineResult, InlineQuery } from "./inline";

@@ -3,0 +3,0 @@ import { Chat, ChatJoinRequest, ChatMemberUpdated, User } from "./manage";

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc