@mtkruto/node 0.1.145 → 0.1.147
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/esm/3_types.d.ts +3 -1
- package/esm/3_types.js +3 -1
- package/esm/4_constants.d.ts +1 -1
- package/esm/4_constants.js +1 -1
- package/esm/client/1_reaction_manager.d.ts +4 -2
- package/esm/client/2_message_manager.d.ts +3 -2
- package/esm/client/2_message_manager.js +19 -2
- package/esm/client/3_callback_query_manager.d.ts +3 -2
- package/esm/client/3_chat_list_manager.d.ts +3 -2
- package/esm/client/3_inline_query_manager.d.ts +3 -2
- package/esm/client/3_inline_query_manager.js +1 -1
- package/esm/types/0_mini_app_info.d.ts +6 -0
- package/esm/types/0_mini_app_info.js +3 -0
- package/esm/types/0_network_statistics_entry.d.ts +1 -0
- package/esm/types/0_reaction.d.ts +1 -0
- package/esm/types/1_inline_query_result_button.d.ts +2 -2
- package/esm/types/1_input_message_content.d.ts +1 -0
- package/esm/types/1_keyboard_button.d.ts +5 -4
- package/esm/types/1_keyboard_button.js +3 -3
- package/esm/types/1_network_statistics.d.ts +1 -0
- package/esm/types/2_inline_keyboard_button.d.ts +4 -4
- package/esm/types/2_inline_keyboard_button.js +4 -4
- package/esm/types/2_inline_query.d.ts +1 -0
- package/esm/types/2_invite_link.d.ts +23 -0
- package/esm/types/2_invite_link.js +27 -0
- package/esm/types/2_message_reaction_count.d.ts +1 -0
- package/esm/types/3_chat_member_updated.d.ts +23 -0
- package/esm/types/3_chat_member_updated.js +33 -0
- package/esm/types/4_inline_query_result.d.ts +1 -0
- package/esm/types/4_inline_query_result.js +1 -1
- package/esm/types/4_message.d.ts +8 -8
- package/esm/types/4_message.js +2 -2
- package/esm/types/6_update.d.ts +19 -2
- package/package.json +1 -1
- package/script/3_types.d.ts +3 -1
- package/script/3_types.js +3 -1
- package/script/4_constants.d.ts +1 -1
- package/script/4_constants.js +1 -1
- package/script/client/1_reaction_manager.d.ts +4 -2
- package/script/client/2_message_manager.d.ts +3 -2
- package/script/client/2_message_manager.js +51 -34
- package/script/client/3_callback_query_manager.d.ts +3 -2
- package/script/client/3_chat_list_manager.d.ts +3 -2
- package/script/client/3_inline_query_manager.d.ts +3 -2
- package/script/client/3_inline_query_manager.js +1 -1
- package/script/types/0_mini_app_info.d.ts +6 -0
- package/script/types/0_mini_app_info.js +7 -0
- package/script/types/0_network_statistics_entry.d.ts +1 -0
- package/script/types/0_reaction.d.ts +1 -0
- package/script/types/1_inline_query_result_button.d.ts +2 -2
- package/script/types/1_input_message_content.d.ts +1 -0
- package/script/types/1_keyboard_button.d.ts +5 -4
- package/script/types/1_keyboard_button.js +3 -3
- package/script/types/1_network_statistics.d.ts +1 -0
- package/script/types/2_inline_keyboard_button.d.ts +4 -4
- package/script/types/2_inline_keyboard_button.js +4 -4
- package/script/types/2_inline_query.d.ts +1 -0
- package/script/types/2_invite_link.d.ts +23 -0
- package/script/types/2_invite_link.js +31 -0
- package/script/types/2_message_reaction_count.d.ts +1 -0
- package/script/types/3_chat_member_updated.d.ts +23 -0
- package/script/types/3_chat_member_updated.js +37 -0
- package/script/types/4_inline_query_result.d.ts +1 -0
- package/script/types/4_inline_query_result.js +1 -1
- package/script/types/4_message.d.ts +8 -8
- package/script/types/4_message.js +2 -2
- package/script/types/6_update.d.ts +19 -2
- package/esm/types/0_web_app_info.d.ts +0 -5
- package/esm/types/0_web_app_info.js +0 -3
- package/script/types/0_web_app_info.d.ts +0 -5
- package/script/types/0_web_app_info.js +0 -7
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { enums } from "../2_tl.js";
|
|
2
2
|
import { LoginUrl } from "./0_login_url.js";
|
|
3
|
-
import {
|
|
3
|
+
import { MiniAppInfo } from "./0_mini_app_info.js";
|
|
4
4
|
import { UsernameResolver } from "./1__getters.js";
|
|
5
5
|
/** @unlisted */
|
|
6
6
|
export interface _InlineKeyboardButtonBase {
|
|
@@ -15,8 +15,8 @@ export interface InlineKeyboardButtonCallback extends _InlineKeyboardButtonBase
|
|
|
15
15
|
callbackData: string;
|
|
16
16
|
}
|
|
17
17
|
/** @unlisted */
|
|
18
|
-
export interface
|
|
19
|
-
|
|
18
|
+
export interface InlineKeyboardButtonMiniApp extends _InlineKeyboardButtonBase {
|
|
19
|
+
miniApp: MiniAppInfo;
|
|
20
20
|
}
|
|
21
21
|
/** @unlisted */
|
|
22
22
|
export interface InlineKeyboardButtonLogin extends _InlineKeyboardButtonBase {
|
|
@@ -39,6 +39,6 @@ export interface InlineKeyboardButtonPay extends _InlineKeyboardButtonBase {
|
|
|
39
39
|
pay: boolean;
|
|
40
40
|
}
|
|
41
41
|
/** A button of an inline keyboard. */
|
|
42
|
-
export type InlineKeyboardButton = InlineKeyboardButtonURL | InlineKeyboardButtonCallback |
|
|
42
|
+
export type InlineKeyboardButton = InlineKeyboardButtonURL | InlineKeyboardButtonCallback | InlineKeyboardButtonMiniApp | InlineKeyboardButtonLogin | InlineKeyboardButtonSwitchInline | InlineKeyboardButtonSwitchInlineCurrent | InlineKeyboardButtonGame | InlineKeyboardButtonPay;
|
|
43
43
|
export declare function constructInlineKeyboardButton(button_: enums.KeyboardButton): InlineKeyboardButton;
|
|
44
44
|
export declare function inlineKeyboardButtonToTlObject(button: InlineKeyboardButton, usernameResolver: UsernameResolver): Promise<import("../tl/2_types.js").KeyboardButtonUrl_ | import("../tl/2_types.js").KeyboardButtonCallback_ | import("../tl/2_types.js").KeyboardButtonSwitchInline_ | import("../tl/2_types.js").KeyboardButtonBuy_ | import("../tl/2_types.js").InputKeyboardButtonUrlAuth_ | import("../tl/2_types.js").KeyboardButtonWebView_>;
|
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.inlineKeyboardButtonToTlObject = exports.constructInlineKeyboardButton = void 0;
|
|
4
4
|
const _1_utilities_js_1 = require("../1_utilities.js");
|
|
5
5
|
const _2_tl_js_1 = require("../2_tl.js");
|
|
6
|
-
const
|
|
6
|
+
const _0_mini_app_info_js_1 = require("./0_mini_app_info.js");
|
|
7
7
|
function constructInlineKeyboardButton(button_) {
|
|
8
8
|
if (button_ instanceof _2_tl_js_1.types.KeyboardButtonUrl) {
|
|
9
9
|
return { text: button_.text, url: button_.url };
|
|
@@ -12,7 +12,7 @@ function constructInlineKeyboardButton(button_) {
|
|
|
12
12
|
return { text: button_.text, callbackData: new TextDecoder().decode(button_.data) };
|
|
13
13
|
}
|
|
14
14
|
else if (button_ instanceof _2_tl_js_1.types.KeyboardButtonWebView || button_ instanceof _2_tl_js_1.types.KeyboardButtonSimpleWebView) {
|
|
15
|
-
return { text: button_.text,
|
|
15
|
+
return { text: button_.text, miniApp: (0, _0_mini_app_info_js_1.constructMiniAppInfo)(button_.url) };
|
|
16
16
|
}
|
|
17
17
|
else if (button_ instanceof _2_tl_js_1.types.KeyboardButtonUrlAuth) {
|
|
18
18
|
return { text: button_.text, loginUrl: { url: button_.url, forwardText: button_.fwd_text } };
|
|
@@ -43,8 +43,8 @@ async function inlineKeyboardButtonToTlObject(button, usernameResolver) {
|
|
|
43
43
|
else if ("callbackData" in button) {
|
|
44
44
|
return new _2_tl_js_1.types.KeyboardButtonCallback({ text: button.text, data: new TextEncoder().encode(button.callbackData) });
|
|
45
45
|
}
|
|
46
|
-
else if ("
|
|
47
|
-
return new _2_tl_js_1.types.KeyboardButtonWebView({ text: button.text, url: button.
|
|
46
|
+
else if ("miniApp" in button) {
|
|
47
|
+
return new _2_tl_js_1.types.KeyboardButtonWebView({ text: button.text, url: button.miniApp.url });
|
|
48
48
|
}
|
|
49
49
|
else if ("loginUrl" in button) {
|
|
50
50
|
return new _2_tl_js_1.types.InputKeyboardButtonUrlAuth({
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { types } from "../2_tl.js";
|
|
2
|
+
import { EntityGetter } from "./1__getters.js";
|
|
3
|
+
import { User } from "./1_user.js";
|
|
4
|
+
/** A chat invite link. */
|
|
5
|
+
export interface InviteLink {
|
|
6
|
+
/** The link itself. */
|
|
7
|
+
inviteLink: string;
|
|
8
|
+
/** The user who created the invite link. */
|
|
9
|
+
creator: User;
|
|
10
|
+
/** Whether the invite link requires explicit approval from administrators. */
|
|
11
|
+
createsJoinRequest: boolean;
|
|
12
|
+
/** Whether the invite link is revoked. */
|
|
13
|
+
revoked: boolean;
|
|
14
|
+
/** An optional name. */
|
|
15
|
+
name?: string;
|
|
16
|
+
/** The point of time in which the invite link is expired at. */
|
|
17
|
+
expiresAt?: Date;
|
|
18
|
+
/** The number of times the invite link can be used. */
|
|
19
|
+
limit?: number;
|
|
20
|
+
/** The number of pending join requests from this invite link. */
|
|
21
|
+
pendingJoinRequestCount?: number;
|
|
22
|
+
}
|
|
23
|
+
export declare function constructInviteLink(inviteLink_: types.ChatInviteExported, getEntity: EntityGetter): Promise<InviteLink>;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.constructInviteLink = void 0;
|
|
4
|
+
const _1_utilities_js_1 = require("../1_utilities.js");
|
|
5
|
+
const _2_tl_js_1 = require("../2_tl.js");
|
|
6
|
+
const _1_user_js_1 = require("./1_user.js");
|
|
7
|
+
async function constructInviteLink(inviteLink_, getEntity) {
|
|
8
|
+
const entity = await getEntity(new _2_tl_js_1.types.PeerUser({ user_id: inviteLink_.admin_id }));
|
|
9
|
+
if (!entity) {
|
|
10
|
+
(0, _1_utilities_js_1.UNREACHABLE)();
|
|
11
|
+
}
|
|
12
|
+
const inviteLink = inviteLink_.link;
|
|
13
|
+
const creator = (0, _1_user_js_1.constructUser)(entity);
|
|
14
|
+
const createsJoinRequest = inviteLink_.request_needed ? true : false;
|
|
15
|
+
const revoked = inviteLink_.revoked ? true : false;
|
|
16
|
+
const name = inviteLink_.title;
|
|
17
|
+
const expiresAt = inviteLink_.expire_date ? (0, _1_utilities_js_1.fromUnixTimestamp)(inviteLink_.expire_date) : undefined;
|
|
18
|
+
const limit = inviteLink_.usage_limit ? inviteLink_.usage_limit : undefined;
|
|
19
|
+
const pendingJoinRequestCount = inviteLink_.requested;
|
|
20
|
+
return (0, _1_utilities_js_1.cleanObject)({
|
|
21
|
+
inviteLink,
|
|
22
|
+
creator,
|
|
23
|
+
createsJoinRequest,
|
|
24
|
+
revoked,
|
|
25
|
+
name,
|
|
26
|
+
expiresAt,
|
|
27
|
+
limit,
|
|
28
|
+
pendingJoinRequestCount,
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
exports.constructInviteLink = constructInviteLink;
|
|
@@ -2,6 +2,7 @@ import { types } from "../2_tl.js";
|
|
|
2
2
|
import { EntityGetter } from "./1__getters.js";
|
|
3
3
|
import { ChatP } from "./1_chat_p.js";
|
|
4
4
|
import { ReactionCount } from "./1_reaction_count.js";
|
|
5
|
+
/** Information on the reactions made to a channel post. */
|
|
5
6
|
export interface MessageReactionCount {
|
|
6
7
|
chat: ChatP;
|
|
7
8
|
messageId: number;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { types } from "../2_tl.js";
|
|
2
|
+
import { EntityGetter } from "./1__getters.js";
|
|
3
|
+
import { ChatP } from "./1_chat_p.js";
|
|
4
|
+
import { User } from "./1_user.js";
|
|
5
|
+
import { ChatMember } from "./2_chat_member.js";
|
|
6
|
+
import { InviteLink } from "./2_invite_link.js";
|
|
7
|
+
export interface ChatMemberUpdated {
|
|
8
|
+
/** The chat in which the change was made. */
|
|
9
|
+
chat: ChatP;
|
|
10
|
+
/** The one who made the change. */
|
|
11
|
+
from: User;
|
|
12
|
+
/** The point of time in which the chat member's status was changed. */
|
|
13
|
+
date: Date;
|
|
14
|
+
/** The old status of the chat member. */
|
|
15
|
+
oldChatMember: ChatMember;
|
|
16
|
+
/** The new status of the chat member. */
|
|
17
|
+
newChatMember: ChatMember;
|
|
18
|
+
/** The invite link used to join. */
|
|
19
|
+
inviteLink?: InviteLink;
|
|
20
|
+
/** Whether the user joined from a shared folder. */
|
|
21
|
+
viaSharedFolder?: boolean;
|
|
22
|
+
}
|
|
23
|
+
export declare function constructChatMemberUpdated(update: types.UpdateChannelParticipant | types.UpdateChatParticipant, getEntity: EntityGetter): Promise<ChatMemberUpdated>;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.constructChatMemberUpdated = void 0;
|
|
4
|
+
const _1_utilities_js_1 = require("../1_utilities.js");
|
|
5
|
+
const _2_tl_js_1 = require("../2_tl.js");
|
|
6
|
+
const _1_chat_p_js_1 = require("./1_chat_p.js");
|
|
7
|
+
const _1_user_js_1 = require("./1_user.js");
|
|
8
|
+
const _2_chat_member_js_1 = require("./2_chat_member.js");
|
|
9
|
+
const _2_invite_link_js_1 = require("./2_invite_link.js");
|
|
10
|
+
async function constructChatMemberUpdated(update, getEntity) {
|
|
11
|
+
if (!update.prev_participant && !update.new_participant) {
|
|
12
|
+
(0, _1_utilities_js_1.UNREACHABLE)();
|
|
13
|
+
}
|
|
14
|
+
const chat_ = await getEntity("channel_id" in update ? new _2_tl_js_1.types.PeerChannel(update) : new _2_tl_js_1.types.PeerChat(update));
|
|
15
|
+
const from_ = await getEntity(new _2_tl_js_1.types.PeerUser({ user_id: update.actor_id }));
|
|
16
|
+
if (!chat_ || !from_) {
|
|
17
|
+
(0, _1_utilities_js_1.UNREACHABLE)();
|
|
18
|
+
}
|
|
19
|
+
const userPeer = new _2_tl_js_1.types.PeerUser(update);
|
|
20
|
+
const chat = (0, _1_chat_p_js_1.constructChatP)(chat_);
|
|
21
|
+
const from = (0, _1_user_js_1.constructUser)(from_);
|
|
22
|
+
const date = (0, _1_utilities_js_1.fromUnixTimestamp)(update.date);
|
|
23
|
+
const oldChatMember = await (0, _2_chat_member_js_1.constructChatMember)(update.prev_participant ?? new _2_tl_js_1.types.ChannelParticipantLeft({ peer: userPeer }), getEntity);
|
|
24
|
+
const newChatMember = await (0, _2_chat_member_js_1.constructChatMember)(update.new_participant ?? new _2_tl_js_1.types.ChannelParticipantLeft({ peer: userPeer }), getEntity);
|
|
25
|
+
const viaSharedFolder = "via_chatlist" in update ? update.via_chatlist ? true : update.invite ? false : undefined : undefined;
|
|
26
|
+
const inviteLink = (update.invite && update.invite instanceof _2_tl_js_1.types.ChatInviteExported) ? await (0, _2_invite_link_js_1.constructInviteLink)(update.invite, getEntity) : undefined;
|
|
27
|
+
return (0, _1_utilities_js_1.cleanObject)({
|
|
28
|
+
chat,
|
|
29
|
+
from,
|
|
30
|
+
date,
|
|
31
|
+
oldChatMember,
|
|
32
|
+
newChatMember,
|
|
33
|
+
viaSharedFolder,
|
|
34
|
+
inviteLink,
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
exports.constructChatMemberUpdated = constructChatMemberUpdated;
|
|
@@ -185,6 +185,7 @@ export interface InlineQueryResultVoice extends _InlineQueryResultBase, _InlineQ
|
|
|
185
185
|
voiceUrl: string;
|
|
186
186
|
voiceDuration?: number;
|
|
187
187
|
}
|
|
188
|
+
/** A single inline query result. */
|
|
188
189
|
export type InlineQueryResult = InlineQueryResultCachedAudio | InlineQueryResultCachedDocument | InlineQueryResultCachedGif | InlineQueryResultCachedMpeg4Gif | InlineQueryResultCachedPhoto | InlineQueryResultCachedSticker | InlineQueryResultCachedVideo | InlineQueryResultCachedVoice | InlineQueryResultArticle | InlineQueryResultAudio | InlineQueryResultContact | InlineQueryResultGame | InlineQueryResultDocument | InlineQueryResultGif | InlineQueryResultLocation | InlineQueryResultMpeg4Gif | InlineQueryResultPhoto | InlineQueryResultVenue | InlineQueryResultVideo | InlineQueryResultVoice;
|
|
189
190
|
export declare function inlineQueryResultToTlObject(result_: InlineQueryResult, parseText: (text: string, params?: {
|
|
190
191
|
parseMode?: ParseMode;
|
|
@@ -181,7 +181,7 @@ async function inlineQueryResultToTlObject(result_, parseText, usernameResolver)
|
|
|
181
181
|
const fileId = _0__file_id_js_1.FileID.decode(fileId_);
|
|
182
182
|
return new _2_tl_js_1.types.InputBotInlineResultDocument({
|
|
183
183
|
id,
|
|
184
|
-
type,
|
|
184
|
+
type: type == "document" ? "file" : type,
|
|
185
185
|
title,
|
|
186
186
|
description,
|
|
187
187
|
document: new _2_tl_js_1.types.InputDocument({
|
|
@@ -88,7 +88,7 @@ export interface _MessageBase {
|
|
|
88
88
|
* Properties shared between media message types.
|
|
89
89
|
* @unlisted
|
|
90
90
|
*/
|
|
91
|
-
export interface
|
|
91
|
+
export interface _MessageMediaBase extends _MessageBase {
|
|
92
92
|
caption?: string;
|
|
93
93
|
captionEntities?: MessageEntity[];
|
|
94
94
|
hasMediaSpoiler?: boolean;
|
|
@@ -104,7 +104,7 @@ export interface MessageText extends _MessageBase {
|
|
|
104
104
|
entities: MessageEntity[];
|
|
105
105
|
}
|
|
106
106
|
/** @unlisted */
|
|
107
|
-
export interface MessagePhoto extends
|
|
107
|
+
export interface MessagePhoto extends _MessageMediaBase {
|
|
108
108
|
/** The photo included in the message. */
|
|
109
109
|
photo: Photo;
|
|
110
110
|
}
|
|
@@ -112,7 +112,7 @@ export interface MessagePhoto extends MessageMediaBase {
|
|
|
112
112
|
* A document message.
|
|
113
113
|
* @unlisted
|
|
114
114
|
*/
|
|
115
|
-
export interface MessageDocument extends
|
|
115
|
+
export interface MessageDocument extends _MessageMediaBase {
|
|
116
116
|
/** The document included in the message. */
|
|
117
117
|
document: Document;
|
|
118
118
|
}
|
|
@@ -120,7 +120,7 @@ export interface MessageDocument extends MessageMediaBase {
|
|
|
120
120
|
* A video message.
|
|
121
121
|
* @unlisted
|
|
122
122
|
*/
|
|
123
|
-
export interface MessageVideo extends
|
|
123
|
+
export interface MessageVideo extends _MessageMediaBase {
|
|
124
124
|
/** The video included in the message. */
|
|
125
125
|
video: Video;
|
|
126
126
|
}
|
|
@@ -136,7 +136,7 @@ export interface MessageSticker extends _MessageBase {
|
|
|
136
136
|
* An animation message. Animations are GIFs or H.264/MPEG-4 AVC videos without sound.
|
|
137
137
|
* @unlisted
|
|
138
138
|
*/
|
|
139
|
-
export interface MessageAnimation extends
|
|
139
|
+
export interface MessageAnimation extends _MessageMediaBase {
|
|
140
140
|
/** The animation included in the message. */
|
|
141
141
|
animation: Animation;
|
|
142
142
|
}
|
|
@@ -144,7 +144,7 @@ export interface MessageAnimation extends MessageMediaBase {
|
|
|
144
144
|
* A voice message.
|
|
145
145
|
* @unlisted
|
|
146
146
|
*/
|
|
147
|
-
export interface MessageVoice extends
|
|
147
|
+
export interface MessageVoice extends _MessageMediaBase {
|
|
148
148
|
/** The voice included in the message. */
|
|
149
149
|
voice: Voice;
|
|
150
150
|
}
|
|
@@ -152,7 +152,7 @@ export interface MessageVoice extends MessageMediaBase {
|
|
|
152
152
|
* An audio message.
|
|
153
153
|
* @unlisted
|
|
154
154
|
*/
|
|
155
|
-
export interface MessageAudio extends
|
|
155
|
+
export interface MessageAudio extends _MessageMediaBase {
|
|
156
156
|
/** The audio included in the message. */
|
|
157
157
|
audio: Audio;
|
|
158
158
|
}
|
|
@@ -325,7 +325,7 @@ export interface MessageUserShared extends _MessageBase {
|
|
|
325
325
|
*/
|
|
326
326
|
export interface MessageWriteAccessAllowed extends _MessageBase {
|
|
327
327
|
writeAccessAllowed: {
|
|
328
|
-
|
|
328
|
+
miniAppName?: string;
|
|
329
329
|
};
|
|
330
330
|
}
|
|
331
331
|
/**
|
|
@@ -201,8 +201,8 @@ async function constructServiceMessage(message_, chat, getEntity, getMessage) {
|
|
|
201
201
|
return { ...message, userShared };
|
|
202
202
|
}
|
|
203
203
|
else if (message_.action instanceof _2_tl_js_1.types.MessageActionBotAllowed) {
|
|
204
|
-
const
|
|
205
|
-
const writeAccessAllowed = {
|
|
204
|
+
const miniAppName = message_.action.app ? message_.action.app[_2_tl_js_1.as](_2_tl_js_1.types.BotApp).title : undefined;
|
|
205
|
+
const writeAccessAllowed = { miniAppName };
|
|
206
206
|
return { ...message, writeAccessAllowed };
|
|
207
207
|
}
|
|
208
208
|
else if (message_.action instanceof _2_tl_js_1.types.MessageActionTopicCreate) {
|
|
@@ -6,6 +6,7 @@ import { InlineQuery } from "./2_inline_query.js";
|
|
|
6
6
|
import { MessageInteractions } from "./2_message_interactions.js";
|
|
7
7
|
import { MessageReactionCount } from "./2_message_reaction_count.js";
|
|
8
8
|
import { MessageReactions } from "./2_message_reactions.js";
|
|
9
|
+
import { ChatMemberUpdated } from "./3_chat_member_updated.js";
|
|
9
10
|
import { Message } from "./4_message.js";
|
|
10
11
|
import { CallbackQuery } from "./5_callback_query.js";
|
|
11
12
|
import { Chat } from "./5_chat.js";
|
|
@@ -183,6 +184,20 @@ export interface UpdateMessageReactionCount {
|
|
|
183
184
|
export interface UpdateMessageReactions {
|
|
184
185
|
messageReactions: MessageReactions;
|
|
185
186
|
}
|
|
187
|
+
/**
|
|
188
|
+
* The status of a chat member was changed.
|
|
189
|
+
* @unlisted
|
|
190
|
+
*/
|
|
191
|
+
export interface UpdateChatMember {
|
|
192
|
+
chatMember: ChatMemberUpdated;
|
|
193
|
+
}
|
|
194
|
+
/**
|
|
195
|
+
* The status of the current account was changed in a chat.
|
|
196
|
+
* @unlisted
|
|
197
|
+
*/
|
|
198
|
+
export interface UpdateMyChatMember {
|
|
199
|
+
myChatMember: ChatMemberUpdated;
|
|
200
|
+
}
|
|
186
201
|
/** @unlisted */
|
|
187
202
|
export interface UpdateMap {
|
|
188
203
|
message: UpdateNewMessage;
|
|
@@ -199,8 +214,10 @@ export interface UpdateMap {
|
|
|
199
214
|
messageInteractions: UpdateMessageInteractions;
|
|
200
215
|
messageReactionCount: UpdateMessageReactionCount;
|
|
201
216
|
messageReactions: UpdateMessageReactions;
|
|
217
|
+
chatMember: UpdateChatMember;
|
|
218
|
+
myChatMember: UpdateMyChatMember;
|
|
202
219
|
}
|
|
203
220
|
/** @unlisted */
|
|
204
|
-
export type UpdateIntersection<T> = T & Partial<UpdateConnectionState & UpdateAuthorizationState & UpdateNewMessage & UpdateEditedMessage & UpdateDeletedMessages & UpdateCallbackQuery & UpdateInlineQuery & UpdateChosenInlineResult & UpdateNewChat & UpdateEditedChat & UpdateDeletedChat & UpdateMessageInteractions & UpdateMessageReactionCount & UpdateMessageReactions>;
|
|
221
|
+
export type UpdateIntersection<T> = T & Partial<UpdateConnectionState & UpdateAuthorizationState & UpdateNewMessage & UpdateEditedMessage & UpdateDeletedMessages & UpdateCallbackQuery & UpdateInlineQuery & UpdateChosenInlineResult & UpdateNewChat & UpdateEditedChat & UpdateDeletedChat & UpdateMessageInteractions & UpdateMessageReactionCount & UpdateMessageReactions & UpdateChatMember & UpdateMyChatMember>;
|
|
205
222
|
/** An incoming update. */
|
|
206
|
-
export type Update = UpdateConnectionState | UpdateAuthorizationState | UpdateNewMessage | UpdateEditedMessage | UpdateDeletedMessages | UpdateCallbackQuery | UpdateInlineQuery | UpdateChosenInlineResult | UpdateNewChat | UpdateEditedChat | UpdateDeletedChat | UpdateMessageInteractions | UpdateMessageReactionCount | UpdateMessageReactions;
|
|
223
|
+
export type Update = UpdateConnectionState | UpdateAuthorizationState | UpdateNewMessage | UpdateEditedMessage | UpdateDeletedMessages | UpdateCallbackQuery | UpdateInlineQuery | UpdateChosenInlineResult | UpdateNewChat | UpdateEditedChat | UpdateDeletedChat | UpdateMessageInteractions | UpdateMessageReactionCount | UpdateMessageReactions | UpdateChatMember | UpdateMyChatMember;
|