@grammyjs/types 3.2.0 → 3.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/inline.d.ts +17 -6
- package/manage.d.ts +3 -3
- package/methods.d.ts +2 -2
- package/package.json +1 -1
package/inline.d.ts
CHANGED
|
@@ -72,7 +72,7 @@ export interface InlineQueryResultPhoto {
|
|
|
72
72
|
type: "photo";
|
|
73
73
|
/** Unique identifier for this result, 1-64 bytes */
|
|
74
74
|
id: string;
|
|
75
|
-
/** A valid URL of the photo. Photo must be in
|
|
75
|
+
/** A valid URL of the photo. Photo must be in JPEG format. Photo size must not exceed 5MB */
|
|
76
76
|
photo_url: string;
|
|
77
77
|
/** URL of the thumbnail for the photo */
|
|
78
78
|
thumbnail_url: string;
|
|
@@ -119,6 +119,8 @@ export interface InlineQueryResultGif {
|
|
|
119
119
|
caption?: string;
|
|
120
120
|
/** Mode for parsing entities in the caption. See formatting options for more details. */
|
|
121
121
|
parse_mode?: ParseMode;
|
|
122
|
+
/** List of special entities that appear in the caption, which can be specified instead of parse_mode */
|
|
123
|
+
caption_entities?: MessageEntity[];
|
|
122
124
|
/** Inline keyboard attached to the message */
|
|
123
125
|
reply_markup?: InlineKeyboardMarkup;
|
|
124
126
|
/** Content of the message to be sent instead of the GIF animation */
|
|
@@ -148,6 +150,8 @@ export interface InlineQueryResultMpeg4Gif {
|
|
|
148
150
|
caption?: string;
|
|
149
151
|
/** Mode for parsing entities in the caption. See formatting options for more details. */
|
|
150
152
|
parse_mode?: ParseMode;
|
|
153
|
+
/** List of special entities that appear in the caption, which can be specified instead of parse_mode */
|
|
154
|
+
caption_entities?: MessageEntity[];
|
|
151
155
|
/** Inline keyboard attached to the message */
|
|
152
156
|
reply_markup?: InlineKeyboardMarkup;
|
|
153
157
|
/** Content of the message to be sent instead of the video animation */
|
|
@@ -155,7 +159,7 @@ export interface InlineQueryResultMpeg4Gif {
|
|
|
155
159
|
}
|
|
156
160
|
/** Represents a link to a page containing an embedded video player or a video file. By default, this video file will be sent by the user with an optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the video.
|
|
157
161
|
|
|
158
|
-
If an InlineQueryResultVideo message contains an embedded video (e.g., YouTube), you must replace its content using input_message_content. */
|
|
162
|
+
> If an InlineQueryResultVideo message contains an embedded video (e.g., YouTube), you must replace its content using input_message_content. */
|
|
159
163
|
export interface InlineQueryResultVideo {
|
|
160
164
|
/** Type of the result, must be video */
|
|
161
165
|
type: "video";
|
|
@@ -231,6 +235,8 @@ export interface InlineQueryResultVoice {
|
|
|
231
235
|
caption?: string;
|
|
232
236
|
/** Mode for parsing entities in the voice message caption. See formatting options for more details. */
|
|
233
237
|
parse_mode?: ParseMode;
|
|
238
|
+
/** List of special entities that appear in the caption, which can be specified instead of parse_mode */
|
|
239
|
+
caption_entities?: MessageEntity[];
|
|
234
240
|
/** Recording duration in seconds */
|
|
235
241
|
voice_duration?: number;
|
|
236
242
|
/** Inline keyboard attached to the message */
|
|
@@ -289,9 +295,9 @@ export interface InlineQueryResultLocation {
|
|
|
289
295
|
horizontal_accuracy?: number;
|
|
290
296
|
/** Period in seconds for which the location can be updated, should be between 60 and 86400. */
|
|
291
297
|
live_period?: number;
|
|
292
|
-
/**
|
|
298
|
+
/** For live locations, a direction in which the user is moving, in degrees. Must be between 1 and 360 if specified. */
|
|
293
299
|
heading?: number;
|
|
294
|
-
/**
|
|
300
|
+
/** For live locations, a maximum distance for proximity alerts about approaching another chat member, in meters. Must be between 1 and 100000 if specified. */
|
|
295
301
|
proximity_alert_radius?: number;
|
|
296
302
|
/** Inline keyboard attached to the message */
|
|
297
303
|
reply_markup?: InlineKeyboardMarkup;
|
|
@@ -416,6 +422,8 @@ export interface InlineQueryResultCachedGif {
|
|
|
416
422
|
caption?: string;
|
|
417
423
|
/** Mode for parsing entities in the caption. See formatting options for more details. */
|
|
418
424
|
parse_mode?: ParseMode;
|
|
425
|
+
/** List of special entities that appear in the caption, which can be specified instead of parse_mode */
|
|
426
|
+
caption_entities?: MessageEntity[];
|
|
419
427
|
/** Inline keyboard attached to the message */
|
|
420
428
|
reply_markup?: InlineKeyboardMarkup;
|
|
421
429
|
/** Content of the message to be sent instead of the GIF animation */
|
|
@@ -435,6 +443,8 @@ export interface InlineQueryResultCachedMpeg4Gif {
|
|
|
435
443
|
caption?: string;
|
|
436
444
|
/** Mode for parsing entities in the caption. See formatting options for more details. */
|
|
437
445
|
parse_mode?: ParseMode;
|
|
446
|
+
/** List of special entities that appear in the caption, which can be specified instead of parse_mode */
|
|
447
|
+
caption_entities?: MessageEntity[];
|
|
438
448
|
/** Inline keyboard attached to the message */
|
|
439
449
|
reply_markup?: InlineKeyboardMarkup;
|
|
440
450
|
/** Content of the message to be sent instead of the video animation */
|
|
@@ -442,8 +452,7 @@ export interface InlineQueryResultCachedMpeg4Gif {
|
|
|
442
452
|
}
|
|
443
453
|
/** Represents a link to a sticker stored on the Telegram servers. By default, this sticker will be sent by the user. Alternatively, you can use input_message_content to send a message with the specified content instead of the sticker.
|
|
444
454
|
|
|
445
|
-
Note: This will only work in Telegram versions released after 9 April, 2016 for static stickers and after 06 July, 2019 for animated stickers. Older clients will ignore them.
|
|
446
|
-
*/
|
|
455
|
+
Note: This will only work in Telegram versions released after 9 April, 2016 for static stickers and after 06 July, 2019 for animated stickers. Older clients will ignore them. */
|
|
447
456
|
export interface InlineQueryResultCachedSticker {
|
|
448
457
|
/** Type of the result, must be sticker */
|
|
449
458
|
type: "sticker";
|
|
@@ -520,6 +529,8 @@ export interface InlineQueryResultCachedVoice {
|
|
|
520
529
|
caption?: string;
|
|
521
530
|
/** Mode for parsing entities in the voice message caption. See formatting options for more details. */
|
|
522
531
|
parse_mode?: ParseMode;
|
|
532
|
+
/** List of special entities that appear in the caption, which can be specified instead of parse_mode */
|
|
533
|
+
caption_entities?: MessageEntity[];
|
|
523
534
|
/** Inline keyboard attached to the message */
|
|
524
535
|
reply_markup?: InlineKeyboardMarkup;
|
|
525
536
|
/** Content of the message to be sent instead of the voice message */
|
package/manage.d.ts
CHANGED
|
@@ -130,7 +130,7 @@ export declare namespace Chat {
|
|
|
130
130
|
interface PrivateGetChat extends PrivateChat, NonGroupGetChat, GetChat {
|
|
131
131
|
/** Custom emoji identifier of emoji status of the other party in a private chat. Returned only in getChat. */
|
|
132
132
|
emoji_status_custom_emoji_id?: string;
|
|
133
|
-
/** Expiration date of the emoji status of the other party in a private chat, if any. Returned only in getChat. */
|
|
133
|
+
/** Expiration date of the emoji status of the other party in a private chat in Unix time, if any. Returned only in getChat. */
|
|
134
134
|
emoji_status_expiration_date?: number;
|
|
135
135
|
/** Bio of the other party in a private chat. Returned only in getChat. */
|
|
136
136
|
bio?: string;
|
|
@@ -328,7 +328,7 @@ export interface ChatMemberRestricted {
|
|
|
328
328
|
can_pin_messages: boolean;
|
|
329
329
|
/** True, if the user is allowed to create forum topics */
|
|
330
330
|
can_manage_topics: boolean;
|
|
331
|
-
/** Date when restrictions will be lifted for this user;
|
|
331
|
+
/** Date when restrictions will be lifted for this user; Unix time. If 0, then the user is restricted forever */
|
|
332
332
|
until_date: number;
|
|
333
333
|
}
|
|
334
334
|
/** Represents a chat member that isn't currently a member of the chat, but may join it themselves. */
|
|
@@ -344,7 +344,7 @@ export interface ChatMemberBanned {
|
|
|
344
344
|
status: "kicked";
|
|
345
345
|
/** Information about the user */
|
|
346
346
|
user: User;
|
|
347
|
-
/** Date when restrictions will be lifted for this user;
|
|
347
|
+
/** Date when restrictions will be lifted for this user; Unix time. If 0, then the user is banned forever */
|
|
348
348
|
until_date: number;
|
|
349
349
|
}
|
|
350
350
|
/** This object represents changes in the status of a chat member. */
|
package/methods.d.ts
CHANGED
|
@@ -589,7 +589,7 @@ export type ApiMethods<F> = {
|
|
|
589
589
|
chat_id: number | string;
|
|
590
590
|
/** Unique identifier of the target user */
|
|
591
591
|
user_id: number;
|
|
592
|
-
/** Date when the user will be unbanned
|
|
592
|
+
/** Date when the user will be unbanned; Unix time. If user is banned for more than 366 days or less than 30 seconds from the current time they are considered to be banned forever. Applied for supergroups and channels only. */
|
|
593
593
|
until_date?: number;
|
|
594
594
|
/** Pass True to delete all messages from the chat for the user that is being removed. If False, the user will be able to see messages in the group that were sent before the user was removed. Always True for supergroups and channels. */
|
|
595
595
|
revoke_messages?: boolean;
|
|
@@ -613,7 +613,7 @@ export type ApiMethods<F> = {
|
|
|
613
613
|
permissions: ChatPermissions;
|
|
614
614
|
/** Pass True if chat permissions are set independently. Otherwise, the can_send_other_messages and can_add_web_page_previews permissions will imply the can_send_messages, can_send_audios, can_send_documents, can_send_photos, can_send_videos, can_send_video_notes, and can_send_voice_notes permissions; the can_send_polls permission will imply the can_send_messages permission. */
|
|
615
615
|
use_independent_chat_permissions?: boolean;
|
|
616
|
-
/** Date when restrictions will be lifted for the user
|
|
616
|
+
/** Date when restrictions will be lifted for the user; Unix time. If user is restricted for more than 366 days or less than 30 seconds from the current time, they are considered to be restricted forever */
|
|
617
617
|
until_date?: number;
|
|
618
618
|
}): true;
|
|
619
619
|
/** Use this method to promote or demote a user in a supergroup or a channel. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Pass False for all boolean parameters to demote a user. Returns True on success. */
|