@mtkruto/node 0.0.968 → 0.0.969
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/client/1_client_abstract.js +2 -2
- package/esm/client/2_client_plain.d.ts +3 -0
- package/esm/client/2_client_plain.js +11 -5
- package/esm/client/3_client.d.ts +3 -0
- package/esm/client/3_client.js +16 -9
- package/esm/constants.d.ts +10 -9
- package/esm/constants.js +9 -17
- package/esm/mod.d.ts +1 -1
- package/esm/mod.js +1 -1
- package/esm/tl/2_types.d.ts +49 -49
- package/esm/tl/2_types.js +194 -193
- package/esm/tl/3_functions.d.ts +15 -15
- package/esm/tl/3_functions.js +45 -44
- package/package.json +1 -1
- package/script/client/1_client_abstract.js +1 -1
- package/script/client/2_client_plain.d.ts +3 -0
- package/script/client/2_client_plain.js +10 -4
- package/script/client/3_client.d.ts +3 -0
- package/script/client/3_client.js +15 -8
- package/script/constants.d.ts +10 -9
- package/script/constants.js +10 -18
- package/script/mod.d.ts +1 -1
- package/script/mod.js +8 -8
- package/script/tl/2_types.d.ts +49 -49
- package/script/tl/2_types.js +193 -192
- package/script/tl/3_functions.d.ts +15 -15
- package/script/tl/3_functions.js +44 -43
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { initTgCrypto } from "../deps.js";
|
|
2
|
-
import {
|
|
2
|
+
import { INITIAL_DC } from "../constants.js";
|
|
3
3
|
import { webSocketTransportProvider } from "../transport/2_transport_provider.js";
|
|
4
4
|
export class ClientAbstract {
|
|
5
5
|
get initialDc() {
|
|
6
6
|
return this._initialDc;
|
|
7
7
|
}
|
|
8
|
-
constructor(transportProvider = webSocketTransportProvider({ initialDc:
|
|
8
|
+
constructor(transportProvider = webSocketTransportProvider({ initialDc: INITIAL_DC }), cdn = false) {
|
|
9
9
|
Object.defineProperty(this, "transportProvider", {
|
|
10
10
|
enumerable: true,
|
|
11
11
|
configurable: true,
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import { Function } from "../tl/3_functions.js";
|
|
2
|
+
import { TransportProvider } from "../transport/2_transport_provider.js";
|
|
2
3
|
import { ClientAbstract } from "./1_client_abstract.js";
|
|
3
4
|
export declare class ClientPlain extends ClientAbstract {
|
|
5
|
+
private readonly publicKeys;
|
|
4
6
|
private lastMsgId;
|
|
7
|
+
constructor(transportProvider: TransportProvider, publicKeys?: import("../constants.js").PublicKeys);
|
|
5
8
|
invoke<T extends Function<unknown>>(function_: T): Promise<T["__R"]>;
|
|
6
9
|
createAuthKey(): Promise<{
|
|
7
10
|
authKey: Uint8Array;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { assertEquals, assertInstanceOf, debug, factorize, ige256Decrypt, ige256Encrypt } from "../deps.js";
|
|
2
|
-
import {
|
|
2
|
+
import { PUBLIC_KEYS } from "../constants.js";
|
|
3
3
|
import { bigIntFromBuffer, getRandomBigInt, modExp } from "../utilities/0_bigint.js";
|
|
4
4
|
import { bufferFromBigInt, concat } from "../utilities/0_buffer.js";
|
|
5
5
|
import { UNREACHABLE } from "../utilities/0_control.js";
|
|
@@ -13,8 +13,14 @@ import { ClientAbstract } from "./1_client_abstract.js";
|
|
|
13
13
|
import { getMessageId, packUnencryptedMessage, unpackUnencryptedMessage } from "./0_message.js";
|
|
14
14
|
const d = debug("ClientPlain/createAuthKey");
|
|
15
15
|
export class ClientPlain extends ClientAbstract {
|
|
16
|
-
constructor() {
|
|
17
|
-
super(
|
|
16
|
+
constructor(transportProvider, publicKeys = PUBLIC_KEYS) {
|
|
17
|
+
super(transportProvider);
|
|
18
|
+
Object.defineProperty(this, "publicKeys", {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
configurable: true,
|
|
21
|
+
writable: true,
|
|
22
|
+
value: publicKeys
|
|
23
|
+
});
|
|
18
24
|
Object.defineProperty(this, "lastMsgId", {
|
|
19
25
|
enumerable: true,
|
|
20
26
|
configurable: true,
|
|
@@ -64,10 +70,10 @@ export class ClientPlain extends ClientAbstract {
|
|
|
64
70
|
let publicKeyFingerprint;
|
|
65
71
|
let publicKey;
|
|
66
72
|
for (const fingerprint of resPq.serverPublicKeyFingerprints) {
|
|
67
|
-
const maybePublicKey = publicKeys.
|
|
73
|
+
const maybePublicKey = this.publicKeys.find(([k]) => (k == fingerprint));
|
|
68
74
|
if (maybePublicKey) {
|
|
69
75
|
publicKeyFingerprint = fingerprint;
|
|
70
|
-
publicKey = maybePublicKey;
|
|
76
|
+
publicKey = maybePublicKey[1];
|
|
71
77
|
break;
|
|
72
78
|
}
|
|
73
79
|
}
|
package/esm/client/3_client.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { PublicKeys } from "../constants.js";
|
|
1
2
|
import { MaybePromise } from "../utilities/0_types.js";
|
|
2
3
|
import * as types from "../tl/2_types.js";
|
|
3
4
|
import * as functions from "../tl/3_functions.js";
|
|
@@ -58,6 +59,7 @@ export interface ClientParams {
|
|
|
58
59
|
* The system_version parameter to be passed to initConnection when calling `authorize`.
|
|
59
60
|
*/
|
|
60
61
|
systemVersion?: string;
|
|
62
|
+
publicKeys?: PublicKeys;
|
|
61
63
|
}
|
|
62
64
|
export interface ForwardMessagesParams {
|
|
63
65
|
messageThreadId?: number;
|
|
@@ -85,6 +87,7 @@ export declare class Client extends ClientAbstract {
|
|
|
85
87
|
readonly langPack: string;
|
|
86
88
|
readonly systemLangCode: string;
|
|
87
89
|
readonly systemVersion: string;
|
|
90
|
+
private readonly publicKeys?;
|
|
88
91
|
/**
|
|
89
92
|
* Constructs the client.
|
|
90
93
|
*
|
package/esm/client/3_client.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { debug, gunzip, Mutex } from "../deps.js";
|
|
2
|
-
import {
|
|
2
|
+
import { ACK_THRESHOLD, APP_VERSION, CHANNEL_DIFFERENCE_LIMIT_BOT, CHANNEL_DIFFERENCE_LIMIT_USER, DEVICE_MODEL, LANG_CODE, LANG_PACK, LAYER, MAX_CHANNEL_ID, MAX_CHAT_ID, STICKER_SET_NAME_TTL, SYSTEM_LANG_CODE, SYSTEM_VERSION, USERNAME_TTL, ZERO_CHANNEL_ID } from "../constants.js";
|
|
3
3
|
import { bigIntFromBuffer, getRandomBigInt, getRandomId } from "../utilities/0_bigint.js";
|
|
4
4
|
import { UNREACHABLE } from "../utilities/0_control.js";
|
|
5
5
|
import { sha1 } from "../utilities/0_hash.js";
|
|
@@ -153,6 +153,12 @@ export class Client extends ClientAbstract {
|
|
|
153
153
|
writable: true,
|
|
154
154
|
value: void 0
|
|
155
155
|
});
|
|
156
|
+
Object.defineProperty(this, "publicKeys", {
|
|
157
|
+
enumerable: true,
|
|
158
|
+
configurable: true,
|
|
159
|
+
writable: true,
|
|
160
|
+
value: void 0
|
|
161
|
+
});
|
|
156
162
|
Object.defineProperty(this, "storageInited", {
|
|
157
163
|
enumerable: true,
|
|
158
164
|
configurable: true,
|
|
@@ -184,12 +190,13 @@ export class Client extends ClientAbstract {
|
|
|
184
190
|
value: new Mutex()
|
|
185
191
|
});
|
|
186
192
|
this.parseMode = params?.parseMode ?? ParseMode.None;
|
|
187
|
-
this.appVersion = params?.appVersion ??
|
|
188
|
-
this.deviceModel = params?.deviceModel ??
|
|
189
|
-
this.langCode = params?.langCode ??
|
|
190
|
-
this.langPack = params?.langPack ??
|
|
191
|
-
this.systemLangCode = params?.systemLangCode ??
|
|
192
|
-
this.systemVersion = params?.systemVersion ??
|
|
193
|
+
this.appVersion = params?.appVersion ?? APP_VERSION;
|
|
194
|
+
this.deviceModel = params?.deviceModel ?? DEVICE_MODEL;
|
|
195
|
+
this.langCode = params?.langCode ?? LANG_CODE;
|
|
196
|
+
this.langPack = params?.langPack ?? LANG_PACK;
|
|
197
|
+
this.systemLangCode = params?.systemLangCode ?? SYSTEM_LANG_CODE;
|
|
198
|
+
this.systemVersion = params?.systemVersion ?? SYSTEM_VERSION;
|
|
199
|
+
this.publicKeys = params?.publicKeys;
|
|
193
200
|
}
|
|
194
201
|
/**
|
|
195
202
|
* Sets the DC and resets the auth key stored in the session provider
|
|
@@ -226,7 +233,7 @@ export class Client extends ClientAbstract {
|
|
|
226
233
|
}
|
|
227
234
|
const authKey = await this.storage.getAuthKey();
|
|
228
235
|
if (authKey == null) {
|
|
229
|
-
const plain = new ClientPlain(this.transportProvider);
|
|
236
|
+
const plain = new ClientPlain(this.transportProvider, this.publicKeys);
|
|
230
237
|
const dc = await this.storage.getDc();
|
|
231
238
|
if (dc != null) {
|
|
232
239
|
plain.setDc(dc);
|
|
@@ -458,7 +465,7 @@ export class Client extends ClientAbstract {
|
|
|
458
465
|
}
|
|
459
466
|
while (this.connected) {
|
|
460
467
|
try {
|
|
461
|
-
if (this.toAcknowledge.size >=
|
|
468
|
+
if (this.toAcknowledge.size >= ACK_THRESHOLD) {
|
|
462
469
|
await this.send(new types.MsgsAck({ msgIds: [...this.toAcknowledge] }));
|
|
463
470
|
this.toAcknowledge.clear();
|
|
464
471
|
}
|
package/esm/constants.d.ts
CHANGED
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { DC } from "./transport/2_transport_provider.js";
|
|
2
|
-
export declare const
|
|
3
|
-
export
|
|
2
|
+
export declare const ACK_THRESHOLD = 10;
|
|
3
|
+
export type PublicKeys = readonly [bigint, [bigint, bigint]][];
|
|
4
|
+
export declare const PUBLIC_KEYS: PublicKeys;
|
|
4
5
|
export declare const VECTOR_CONSTRUCTOR = 481674261;
|
|
5
|
-
export declare const
|
|
6
|
+
export declare const INITIAL_DC: DC;
|
|
6
7
|
export declare const LAYER = 160;
|
|
7
|
-
export declare const
|
|
8
|
-
export declare const
|
|
9
|
-
export declare const
|
|
10
|
-
export declare const
|
|
11
|
-
export declare const
|
|
12
|
-
export declare const
|
|
8
|
+
export declare const APP_VERSION = "MTKruto 0.0.969";
|
|
9
|
+
export declare const DEVICE_MODEL: string;
|
|
10
|
+
export declare const LANG_CODE: string;
|
|
11
|
+
export declare const LANG_PACK = "";
|
|
12
|
+
export declare const SYSTEM_LANG_CODE: string;
|
|
13
|
+
export declare const SYSTEM_VERSION: string;
|
|
13
14
|
export declare const USERNAME_TTL = 86400;
|
|
14
15
|
export declare const STICKER_SET_NAME_TTL = 172800;
|
|
15
16
|
export declare const MAX_CHAT_ID = 999999999999;
|
package/esm/constants.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as dntShim from "./_dnt.shims.js";
|
|
2
|
-
export const
|
|
3
|
-
export const
|
|
2
|
+
export const ACK_THRESHOLD = 10;
|
|
3
|
+
export const PUBLIC_KEYS = Object.freeze([
|
|
4
4
|
[
|
|
5
5
|
1562291298945373506n,
|
|
6
6
|
[
|
|
@@ -50,26 +50,18 @@ export const publicKeys = new Map([
|
|
|
50
50
|
0x010001n,
|
|
51
51
|
],
|
|
52
52
|
],
|
|
53
|
-
// Piltover
|
|
54
|
-
[
|
|
55
|
-
-5746138571559360724n,
|
|
56
|
-
[
|
|
57
|
-
26007219673003768186863565706940772901187119797549016801229858995725553827566821957407312503173782965285118977548255274803204174826509270586421841734996746493071723679186583391927378886693846518017621303145594627156874011707147548520576401963675756312298478878474644101348427872255774246965916073553469761183250044599310582333625453447885100318336864215713703860033765477732305055537755094341310278183464296754000479758644167423888581130401586546401934096183449791147912201040435037926911688179080223967863256047196705714611239523210563418382771999824529581206920323901890386681875893623076449827387008128524246269437n,
|
|
58
|
-
0x010001n,
|
|
59
|
-
],
|
|
60
|
-
],
|
|
61
53
|
]);
|
|
62
54
|
export const VECTOR_CONSTRUCTOR = 0x1CB5C415;
|
|
63
|
-
export const
|
|
55
|
+
export const INITIAL_DC = "2-test";
|
|
64
56
|
export const LAYER = 160;
|
|
65
|
-
export const
|
|
57
|
+
export const APP_VERSION = "MTKruto 0.0.969";
|
|
66
58
|
// @ts-ignore: lib
|
|
67
|
-
export const
|
|
68
|
-
export const
|
|
69
|
-
export const
|
|
70
|
-
export const
|
|
59
|
+
export const DEVICE_MODEL = typeof dntShim.Deno === "undefined" ? typeof navigator === "undefined" ? typeof process === "undefined" ? "Unknown" : process.platform + "-" + process.arch : navigator.userAgent.split(" ")[0] : dntShim.Deno.build.os + "-" + dntShim.Deno.build.arch;
|
|
60
|
+
export const LANG_CODE = typeof navigator === "undefined" ? "en" : navigator.language.split("-")[0];
|
|
61
|
+
export const LANG_PACK = "";
|
|
62
|
+
export const SYSTEM_LANG_CODE = typeof navigator === "undefined" ? "en" : navigator.language.split("-")[0];
|
|
71
63
|
// @ts-ignore: lib
|
|
72
|
-
export const
|
|
64
|
+
export const SYSTEM_VERSION = typeof navigator === "undefined" ? typeof process === "undefined" ? "Unknown" : "Node.js/" + process.versions.node : navigator.userAgent;
|
|
73
65
|
export const USERNAME_TTL = 86400;
|
|
74
66
|
export const STICKER_SET_NAME_TTL = 172800;
|
|
75
67
|
export const MAX_CHAT_ID = 999999999999;
|
package/esm/mod.d.ts
CHANGED
|
@@ -23,4 +23,4 @@ export * from "./transport/0_transport.js";
|
|
|
23
23
|
export * from "./transport/2_transport_provider.js";
|
|
24
24
|
export * from "./connection/0_connection.js";
|
|
25
25
|
export * from "./connection/1_connection_web_socket.js";
|
|
26
|
-
export {
|
|
26
|
+
export { APP_VERSION, DEVICE_MODEL, INITIAL_DC, LANG_CODE, LANG_PACK, LAYER, SYSTEM_LANG_CODE, SYSTEM_VERSION } from "./constants.js";
|
package/esm/mod.js
CHANGED
|
@@ -20,4 +20,4 @@ export * from "./transport/0_transport.js";
|
|
|
20
20
|
export * from "./transport/2_transport_provider.js";
|
|
21
21
|
export * from "./connection/0_connection.js";
|
|
22
22
|
export * from "./connection/1_connection_web_socket.js";
|
|
23
|
-
export {
|
|
23
|
+
export { APP_VERSION, DEVICE_MODEL, INITIAL_DC, LANG_CODE, LANG_PACK, LAYER, SYSTEM_LANG_CODE, SYSTEM_VERSION } from "./constants.js";
|
package/esm/tl/2_types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { id,
|
|
1
|
+
import { id, params, TLObject, Params, TLObjectConstructor, ParamDesc, paramDesc } from "./1_tl_object.js";
|
|
2
2
|
export declare abstract class Type extends TLObject {
|
|
3
3
|
}
|
|
4
4
|
export declare abstract class TypeX extends Type {
|
|
@@ -1698,7 +1698,7 @@ export declare class InputChatUploadedPhoto extends TypeInputChatPhoto {
|
|
|
1698
1698
|
protected get [id](): number;
|
|
1699
1699
|
static get [paramDesc](): ParamDesc;
|
|
1700
1700
|
protected get [params](): Params;
|
|
1701
|
-
constructor(params
|
|
1701
|
+
constructor(params?: {
|
|
1702
1702
|
file?: TypeInputFile;
|
|
1703
1703
|
video?: TypeInputFile;
|
|
1704
1704
|
videoStartTs?: number;
|
|
@@ -2624,7 +2624,7 @@ export declare class MessageMediaPhoto extends TypeMessageMedia {
|
|
|
2624
2624
|
protected get [id](): number;
|
|
2625
2625
|
static get [paramDesc](): ParamDesc;
|
|
2626
2626
|
protected get [params](): Params;
|
|
2627
|
-
constructor(params
|
|
2627
|
+
constructor(params?: {
|
|
2628
2628
|
spoiler?: true;
|
|
2629
2629
|
photo?: TypePhoto;
|
|
2630
2630
|
ttlSeconds?: number;
|
|
@@ -2671,7 +2671,7 @@ export declare class MessageMediaDocument extends TypeMessageMedia {
|
|
|
2671
2671
|
protected get [id](): number;
|
|
2672
2672
|
static get [paramDesc](): ParamDesc;
|
|
2673
2673
|
protected get [params](): Params;
|
|
2674
|
-
constructor(params
|
|
2674
|
+
constructor(params?: {
|
|
2675
2675
|
nopremium?: true;
|
|
2676
2676
|
spoiler?: true;
|
|
2677
2677
|
document?: TypeDocument;
|
|
@@ -2992,7 +2992,7 @@ export declare class MessageActionBotAllowed extends TypeMessageAction {
|
|
|
2992
2992
|
protected get [id](): number;
|
|
2993
2993
|
static get [paramDesc](): ParamDesc;
|
|
2994
2994
|
protected get [params](): Params;
|
|
2995
|
-
constructor(params
|
|
2995
|
+
constructor(params?: {
|
|
2996
2996
|
attachMenu?: true;
|
|
2997
2997
|
domain?: string;
|
|
2998
2998
|
app?: TypeBotApp;
|
|
@@ -3154,7 +3154,7 @@ export declare class MessageActionTopicEdit extends TypeMessageAction {
|
|
|
3154
3154
|
protected get [id](): number;
|
|
3155
3155
|
static get [paramDesc](): ParamDesc;
|
|
3156
3156
|
protected get [params](): Params;
|
|
3157
|
-
constructor(params
|
|
3157
|
+
constructor(params?: {
|
|
3158
3158
|
title?: string;
|
|
3159
3159
|
iconEmojiId?: bigint;
|
|
3160
3160
|
closed?: boolean;
|
|
@@ -3432,7 +3432,7 @@ export declare class AuthAuthorizationSignUpRequired extends TypeAuthAuthorizati
|
|
|
3432
3432
|
protected get [id](): number;
|
|
3433
3433
|
static get [paramDesc](): ParamDesc;
|
|
3434
3434
|
protected get [params](): Params;
|
|
3435
|
-
constructor(params
|
|
3435
|
+
constructor(params?: {
|
|
3436
3436
|
termsOfService?: TypeHelpTermsOfService;
|
|
3437
3437
|
});
|
|
3438
3438
|
}
|
|
@@ -3496,7 +3496,7 @@ export declare class InputPeerNotifySettings extends TypeInputPeerNotifySettings
|
|
|
3496
3496
|
protected get [id](): number;
|
|
3497
3497
|
static get [paramDesc](): ParamDesc;
|
|
3498
3498
|
protected get [params](): Params;
|
|
3499
|
-
constructor(params
|
|
3499
|
+
constructor(params?: {
|
|
3500
3500
|
showPreviews?: boolean;
|
|
3501
3501
|
silent?: boolean;
|
|
3502
3502
|
muteUntil?: number;
|
|
@@ -3521,7 +3521,7 @@ export declare class PeerNotifySettings extends TypePeerNotifySettings {
|
|
|
3521
3521
|
protected get [id](): number;
|
|
3522
3522
|
static get [paramDesc](): ParamDesc;
|
|
3523
3523
|
protected get [params](): Params;
|
|
3524
|
-
constructor(params
|
|
3524
|
+
constructor(params?: {
|
|
3525
3525
|
showPreviews?: boolean;
|
|
3526
3526
|
silent?: boolean;
|
|
3527
3527
|
muteUntil?: number;
|
|
@@ -3551,7 +3551,7 @@ export declare class PeerSettings extends TypePeerSettings {
|
|
|
3551
3551
|
protected get [id](): number;
|
|
3552
3552
|
static get [paramDesc](): ParamDesc;
|
|
3553
3553
|
protected get [params](): Params;
|
|
3554
|
-
constructor(params
|
|
3554
|
+
constructor(params?: {
|
|
3555
3555
|
reportSpam?: true;
|
|
3556
3556
|
addContact?: true;
|
|
3557
3557
|
blockContact?: true;
|
|
@@ -4042,7 +4042,7 @@ export declare class InputMessagesFilterPhoneCalls extends TypeMessagesFilter {
|
|
|
4042
4042
|
protected get [id](): number;
|
|
4043
4043
|
static get [paramDesc](): ParamDesc;
|
|
4044
4044
|
protected get [params](): Params;
|
|
4045
|
-
constructor(params
|
|
4045
|
+
constructor(params?: {
|
|
4046
4046
|
missed?: true;
|
|
4047
4047
|
});
|
|
4048
4048
|
}
|
|
@@ -4494,7 +4494,7 @@ export declare class UpdateStickerSets extends TypeUpdate {
|
|
|
4494
4494
|
protected get [id](): number;
|
|
4495
4495
|
static get [paramDesc](): ParamDesc;
|
|
4496
4496
|
protected get [params](): Params;
|
|
4497
|
-
constructor(params
|
|
4497
|
+
constructor(params?: {
|
|
4498
4498
|
masks?: true;
|
|
4499
4499
|
emojis?: true;
|
|
4500
4500
|
});
|
|
@@ -4689,7 +4689,7 @@ export declare class UpdatePinnedDialogs extends TypeUpdate {
|
|
|
4689
4689
|
protected get [id](): number;
|
|
4690
4690
|
static get [paramDesc](): ParamDesc;
|
|
4691
4691
|
protected get [params](): Params;
|
|
4692
|
-
constructor(params
|
|
4692
|
+
constructor(params?: {
|
|
4693
4693
|
folderId?: number;
|
|
4694
4694
|
order?: Array<TypeDialogPeer>;
|
|
4695
4695
|
});
|
|
@@ -6907,7 +6907,7 @@ export declare class WebPageNotModified extends TypeWebPage {
|
|
|
6907
6907
|
protected get [id](): number;
|
|
6908
6908
|
static get [paramDesc](): ParamDesc;
|
|
6909
6909
|
protected get [params](): Params;
|
|
6910
|
-
constructor(params
|
|
6910
|
+
constructor(params?: {
|
|
6911
6911
|
cachedPageViews?: number;
|
|
6912
6912
|
});
|
|
6913
6913
|
}
|
|
@@ -7002,7 +7002,7 @@ export declare class AccountPasswordSettings extends TypeAccountPasswordSettings
|
|
|
7002
7002
|
protected get [id](): number;
|
|
7003
7003
|
static get [paramDesc](): ParamDesc;
|
|
7004
7004
|
protected get [params](): Params;
|
|
7005
|
-
constructor(params
|
|
7005
|
+
constructor(params?: {
|
|
7006
7006
|
email?: string;
|
|
7007
7007
|
secureSettings?: TypeSecureSecretSettings;
|
|
7008
7008
|
});
|
|
@@ -7016,7 +7016,7 @@ export declare class AccountPasswordInputSettings extends TypeAccountPasswordInp
|
|
|
7016
7016
|
protected get [id](): number;
|
|
7017
7017
|
static get [paramDesc](): ParamDesc;
|
|
7018
7018
|
protected get [params](): Params;
|
|
7019
|
-
constructor(params
|
|
7019
|
+
constructor(params?: {
|
|
7020
7020
|
newAlgo?: TypePasswordKdfAlgo;
|
|
7021
7021
|
newPasswordHash?: Uint8Array;
|
|
7022
7022
|
hint?: string;
|
|
@@ -7282,7 +7282,7 @@ export declare class BotInfo extends TypeBotInfo {
|
|
|
7282
7282
|
protected get [id](): number;
|
|
7283
7283
|
static get [paramDesc](): ParamDesc;
|
|
7284
7284
|
protected get [params](): Params;
|
|
7285
|
-
constructor(params
|
|
7285
|
+
constructor(params?: {
|
|
7286
7286
|
userId?: bigint;
|
|
7287
7287
|
description?: string;
|
|
7288
7288
|
descriptionPhoto?: TypePhoto;
|
|
@@ -7489,7 +7489,7 @@ export declare class ReplyKeyboardHide extends TypeReplyMarkup {
|
|
|
7489
7489
|
protected get [id](): number;
|
|
7490
7490
|
static get [paramDesc](): ParamDesc;
|
|
7491
7491
|
protected get [params](): Params;
|
|
7492
|
-
constructor(params
|
|
7492
|
+
constructor(params?: {
|
|
7493
7493
|
selective?: true;
|
|
7494
7494
|
});
|
|
7495
7495
|
}
|
|
@@ -7500,7 +7500,7 @@ export declare class ReplyKeyboardForceReply extends TypeReplyMarkup {
|
|
|
7500
7500
|
protected get [id](): number;
|
|
7501
7501
|
static get [paramDesc](): ParamDesc;
|
|
7502
7502
|
protected get [params](): Params;
|
|
7503
|
-
constructor(params
|
|
7503
|
+
constructor(params?: {
|
|
7504
7504
|
singleUse?: true;
|
|
7505
7505
|
selective?: true;
|
|
7506
7506
|
placeholder?: string;
|
|
@@ -8047,7 +8047,7 @@ export declare class ChannelParticipantsMentions extends TypeChannelParticipants
|
|
|
8047
8047
|
protected get [id](): number;
|
|
8048
8048
|
static get [paramDesc](): ParamDesc;
|
|
8049
8049
|
protected get [params](): Params;
|
|
8050
|
-
constructor(params
|
|
8050
|
+
constructor(params?: {
|
|
8051
8051
|
q?: string;
|
|
8052
8052
|
topMsgId?: number;
|
|
8053
8053
|
});
|
|
@@ -8208,7 +8208,7 @@ export declare class InputBotInlineMessageGame extends TypeInputBotInlineMessage
|
|
|
8208
8208
|
protected get [id](): number;
|
|
8209
8209
|
static get [paramDesc](): ParamDesc;
|
|
8210
8210
|
protected get [params](): Params;
|
|
8211
|
-
constructor(params
|
|
8211
|
+
constructor(params?: {
|
|
8212
8212
|
replyMarkup?: TypeReplyMarkup;
|
|
8213
8213
|
});
|
|
8214
8214
|
}
|
|
@@ -8616,7 +8616,7 @@ export declare class AuthSentCodeTypeSetUpEmailRequired extends TypeAuthSentCode
|
|
|
8616
8616
|
protected get [id](): number;
|
|
8617
8617
|
static get [paramDesc](): ParamDesc;
|
|
8618
8618
|
protected get [params](): Params;
|
|
8619
|
-
constructor(params
|
|
8619
|
+
constructor(params?: {
|
|
8620
8620
|
appleSigninAllowed?: true;
|
|
8621
8621
|
googleSigninAllowed?: true;
|
|
8622
8622
|
});
|
|
@@ -8671,7 +8671,7 @@ export declare class MessagesMessageEditData extends TypeMessagesMessageEditData
|
|
|
8671
8671
|
protected get [id](): number;
|
|
8672
8672
|
static get [paramDesc](): ParamDesc;
|
|
8673
8673
|
protected get [params](): Params;
|
|
8674
|
-
constructor(params
|
|
8674
|
+
constructor(params?: {
|
|
8675
8675
|
caption?: true;
|
|
8676
8676
|
});
|
|
8677
8677
|
}
|
|
@@ -8833,7 +8833,7 @@ export declare class DraftMessageEmpty extends TypeDraftMessage {
|
|
|
8833
8833
|
protected get [id](): number;
|
|
8834
8834
|
static get [paramDesc](): ParamDesc;
|
|
8835
8835
|
protected get [params](): Params;
|
|
8836
|
-
constructor(params
|
|
8836
|
+
constructor(params?: {
|
|
8837
8837
|
date?: number;
|
|
8838
8838
|
});
|
|
8839
8839
|
}
|
|
@@ -9672,7 +9672,7 @@ export declare class PaymentRequestedInfo extends TypePaymentRequestedInfo {
|
|
|
9672
9672
|
protected get [id](): number;
|
|
9673
9673
|
static get [paramDesc](): ParamDesc;
|
|
9674
9674
|
protected get [params](): Params;
|
|
9675
|
-
constructor(params
|
|
9675
|
+
constructor(params?: {
|
|
9676
9676
|
name?: string;
|
|
9677
9677
|
phone?: string;
|
|
9678
9678
|
email?: string;
|
|
@@ -9775,7 +9775,7 @@ export declare class InputWebFileAudioAlbumThumbLocation extends TypeInputWebFil
|
|
|
9775
9775
|
protected get [id](): number;
|
|
9776
9776
|
static get [paramDesc](): ParamDesc;
|
|
9777
9777
|
protected get [params](): Params;
|
|
9778
|
-
constructor(params
|
|
9778
|
+
constructor(params?: {
|
|
9779
9779
|
small?: true;
|
|
9780
9780
|
document?: TypeInputDocument;
|
|
9781
9781
|
title?: string;
|
|
@@ -9844,7 +9844,7 @@ export declare class PaymentsValidatedRequestedInfo extends TypePaymentsValidate
|
|
|
9844
9844
|
protected get [id](): number;
|
|
9845
9845
|
static get [paramDesc](): ParamDesc;
|
|
9846
9846
|
protected get [params](): Params;
|
|
9847
|
-
constructor(params
|
|
9847
|
+
constructor(params?: {
|
|
9848
9848
|
id?: string;
|
|
9849
9849
|
shippingOptions?: Array<TypeShippingOption>;
|
|
9850
9850
|
});
|
|
@@ -9908,7 +9908,7 @@ export declare class PaymentsSavedInfo extends TypePaymentsSavedInfo {
|
|
|
9908
9908
|
protected get [id](): number;
|
|
9909
9909
|
static get [paramDesc](): ParamDesc;
|
|
9910
9910
|
protected get [params](): Params;
|
|
9911
|
-
constructor(params
|
|
9911
|
+
constructor(params?: {
|
|
9912
9912
|
hasSavedCredentials?: true;
|
|
9913
9913
|
savedInfo?: TypePaymentRequestedInfo;
|
|
9914
9914
|
});
|
|
@@ -10731,7 +10731,7 @@ export declare class ChannelAdminLogEventActionPinTopic extends TypeChannelAdmin
|
|
|
10731
10731
|
protected get [id](): number;
|
|
10732
10732
|
static get [paramDesc](): ParamDesc;
|
|
10733
10733
|
protected get [params](): Params;
|
|
10734
|
-
constructor(params
|
|
10734
|
+
constructor(params?: {
|
|
10735
10735
|
prevTopic?: TypeForumTopic;
|
|
10736
10736
|
newTopic?: TypeForumTopic;
|
|
10737
10737
|
});
|
|
@@ -10795,7 +10795,7 @@ export declare class ChannelAdminLogEventsFilter extends TypeChannelAdminLogEven
|
|
|
10795
10795
|
protected get [id](): number;
|
|
10796
10796
|
static get [paramDesc](): ParamDesc;
|
|
10797
10797
|
protected get [params](): Params;
|
|
10798
|
-
constructor(params
|
|
10798
|
+
constructor(params?: {
|
|
10799
10799
|
join?: true;
|
|
10800
10800
|
leave?: true;
|
|
10801
10801
|
invite?: true;
|
|
@@ -11728,7 +11728,7 @@ export declare class PageTableCell extends TypePageTableCell {
|
|
|
11728
11728
|
protected get [id](): number;
|
|
11729
11729
|
static get [paramDesc](): ParamDesc;
|
|
11730
11730
|
protected get [params](): Params;
|
|
11731
|
-
constructor(params
|
|
11731
|
+
constructor(params?: {
|
|
11732
11732
|
header?: true;
|
|
11733
11733
|
alignCenter?: true;
|
|
11734
11734
|
alignRight?: true;
|
|
@@ -11934,7 +11934,7 @@ export declare class PollResults extends TypePollResults {
|
|
|
11934
11934
|
protected get [id](): number;
|
|
11935
11935
|
static get [paramDesc](): ParamDesc;
|
|
11936
11936
|
protected get [params](): Params;
|
|
11937
|
-
constructor(params
|
|
11937
|
+
constructor(params?: {
|
|
11938
11938
|
min?: true;
|
|
11939
11939
|
results?: Array<TypePollAnswerVoters>;
|
|
11940
11940
|
totalVoters?: number;
|
|
@@ -11977,7 +11977,7 @@ export declare class ChatAdminRights extends TypeChatAdminRights {
|
|
|
11977
11977
|
protected get [id](): number;
|
|
11978
11978
|
static get [paramDesc](): ParamDesc;
|
|
11979
11979
|
protected get [params](): Params;
|
|
11980
|
-
constructor(params
|
|
11980
|
+
constructor(params?: {
|
|
11981
11981
|
changeInfo?: true;
|
|
11982
11982
|
postMessages?: true;
|
|
11983
11983
|
editMessages?: true;
|
|
@@ -12099,7 +12099,7 @@ export declare class CodeSettings extends TypeCodeSettings {
|
|
|
12099
12099
|
protected get [id](): number;
|
|
12100
12100
|
static get [paramDesc](): ParamDesc;
|
|
12101
12101
|
protected get [params](): Params;
|
|
12102
|
-
constructor(params
|
|
12102
|
+
constructor(params?: {
|
|
12103
12103
|
allowFlashcall?: true;
|
|
12104
12104
|
currentNumber?: true;
|
|
12105
12105
|
allowAppHash?: true;
|
|
@@ -12122,7 +12122,7 @@ export declare class WallPaperSettings extends TypeWallPaperSettings {
|
|
|
12122
12122
|
protected get [id](): number;
|
|
12123
12123
|
static get [paramDesc](): ParamDesc;
|
|
12124
12124
|
protected get [params](): Params;
|
|
12125
|
-
constructor(params
|
|
12125
|
+
constructor(params?: {
|
|
12126
12126
|
blur?: true;
|
|
12127
12127
|
motion?: true;
|
|
12128
12128
|
backgroundColor?: number;
|
|
@@ -12467,7 +12467,7 @@ export declare class AccountContentSettings extends TypeAccountContentSettings {
|
|
|
12467
12467
|
protected get [id](): number;
|
|
12468
12468
|
static get [paramDesc](): ParamDesc;
|
|
12469
12469
|
protected get [params](): Params;
|
|
12470
|
-
constructor(params
|
|
12470
|
+
constructor(params?: {
|
|
12471
12471
|
sensitiveEnabled?: true;
|
|
12472
12472
|
sensitiveCanChange?: true;
|
|
12473
12473
|
});
|
|
@@ -12561,7 +12561,7 @@ export declare class WebPageAttributeTheme extends TypeWebPageAttribute {
|
|
|
12561
12561
|
protected get [id](): number;
|
|
12562
12562
|
static get [paramDesc](): ParamDesc;
|
|
12563
12563
|
protected get [params](): Params;
|
|
12564
|
-
constructor(params
|
|
12564
|
+
constructor(params?: {
|
|
12565
12565
|
documents?: Array<TypeDocument>;
|
|
12566
12566
|
settings?: TypeThemeSettings;
|
|
12567
12567
|
});
|
|
@@ -12959,7 +12959,7 @@ export declare class GlobalPrivacySettings extends TypeGlobalPrivacySettings {
|
|
|
12959
12959
|
protected get [id](): number;
|
|
12960
12960
|
static get [paramDesc](): ParamDesc;
|
|
12961
12961
|
protected get [params](): Params;
|
|
12962
|
-
constructor(params
|
|
12962
|
+
constructor(params?: {
|
|
12963
12963
|
archiveAndMuteNewNoncontactPeers?: true;
|
|
12964
12964
|
keepArchivedUnmuted?: true;
|
|
12965
12965
|
keepArchivedFolders?: true;
|
|
@@ -13019,7 +13019,7 @@ export declare class MessageViews extends TypeMessageViews {
|
|
|
13019
13019
|
protected get [id](): number;
|
|
13020
13020
|
static get [paramDesc](): ParamDesc;
|
|
13021
13021
|
protected get [params](): Params;
|
|
13022
|
-
constructor(params
|
|
13022
|
+
constructor(params?: {
|
|
13023
13023
|
views?: number;
|
|
13024
13024
|
forwards?: number;
|
|
13025
13025
|
replies?: TypeMessageReplies;
|
|
@@ -13328,7 +13328,7 @@ export declare class MessagesHistoryImportParsed extends TypeMessagesHistoryImpo
|
|
|
13328
13328
|
protected get [id](): number;
|
|
13329
13329
|
static get [paramDesc](): ParamDesc;
|
|
13330
13330
|
protected get [params](): Params;
|
|
13331
|
-
constructor(params
|
|
13331
|
+
constructor(params?: {
|
|
13332
13332
|
pm?: true;
|
|
13333
13333
|
group?: true;
|
|
13334
13334
|
title?: string;
|
|
@@ -13747,7 +13747,7 @@ export declare class AuthLoggedOut extends TypeAuthLoggedOut {
|
|
|
13747
13747
|
protected get [id](): number;
|
|
13748
13748
|
static get [paramDesc](): ParamDesc;
|
|
13749
13749
|
protected get [params](): Params;
|
|
13750
|
-
constructor(params
|
|
13750
|
+
constructor(params?: {
|
|
13751
13751
|
futureAuthToken?: Uint8Array;
|
|
13752
13752
|
});
|
|
13753
13753
|
}
|
|
@@ -13994,7 +13994,7 @@ export declare class WebViewMessageSent extends TypeWebViewMessageSent {
|
|
|
13994
13994
|
protected get [id](): number;
|
|
13995
13995
|
static get [paramDesc](): ParamDesc;
|
|
13996
13996
|
protected get [params](): Params;
|
|
13997
|
-
constructor(params
|
|
13997
|
+
constructor(params?: {
|
|
13998
13998
|
msgId?: TypeInputBotInlineMessageID;
|
|
13999
13999
|
});
|
|
14000
14000
|
}
|
|
@@ -14182,7 +14182,7 @@ export declare class InputStorePaymentPremiumSubscription extends TypeInputStore
|
|
|
14182
14182
|
protected get [id](): number;
|
|
14183
14183
|
static get [paramDesc](): ParamDesc;
|
|
14184
14184
|
protected get [params](): Params;
|
|
14185
|
-
constructor(params
|
|
14185
|
+
constructor(params?: {
|
|
14186
14186
|
restore?: true;
|
|
14187
14187
|
upgrade?: true;
|
|
14188
14188
|
});
|
|
@@ -14306,7 +14306,7 @@ export declare class ChatReactionsAll extends TypeChatReactions {
|
|
|
14306
14306
|
protected get [id](): number;
|
|
14307
14307
|
static get [paramDesc](): ParamDesc;
|
|
14308
14308
|
protected get [params](): Params;
|
|
14309
|
-
constructor(params
|
|
14309
|
+
constructor(params?: {
|
|
14310
14310
|
allowCustom?: true;
|
|
14311
14311
|
});
|
|
14312
14312
|
}
|
|
@@ -14448,7 +14448,7 @@ export declare class MessageExtendedMediaPreview extends TypeMessageExtendedMedi
|
|
|
14448
14448
|
protected get [id](): number;
|
|
14449
14449
|
static get [paramDesc](): ParamDesc;
|
|
14450
14450
|
protected get [params](): Params;
|
|
14451
|
-
constructor(params
|
|
14451
|
+
constructor(params?: {
|
|
14452
14452
|
w?: number;
|
|
14453
14453
|
h?: number;
|
|
14454
14454
|
thumb?: TypePhotoSize;
|
|
@@ -14589,7 +14589,7 @@ export declare class RequestPeerTypeUser extends TypeRequestPeerType {
|
|
|
14589
14589
|
protected get [id](): number;
|
|
14590
14590
|
static get [paramDesc](): ParamDesc;
|
|
14591
14591
|
protected get [params](): Params;
|
|
14592
|
-
constructor(params
|
|
14592
|
+
constructor(params?: {
|
|
14593
14593
|
bot?: boolean;
|
|
14594
14594
|
premium?: boolean;
|
|
14595
14595
|
});
|
|
@@ -14604,7 +14604,7 @@ export declare class RequestPeerTypeChat extends TypeRequestPeerType {
|
|
|
14604
14604
|
protected get [id](): number;
|
|
14605
14605
|
static get [paramDesc](): ParamDesc;
|
|
14606
14606
|
protected get [params](): Params;
|
|
14607
|
-
constructor(params
|
|
14607
|
+
constructor(params?: {
|
|
14608
14608
|
creator?: true;
|
|
14609
14609
|
botParticipant?: true;
|
|
14610
14610
|
hasUsername?: boolean;
|
|
@@ -14621,7 +14621,7 @@ export declare class RequestPeerTypeBroadcast extends TypeRequestPeerType {
|
|
|
14621
14621
|
protected get [id](): number;
|
|
14622
14622
|
static get [paramDesc](): ParamDesc;
|
|
14623
14623
|
protected get [params](): Params;
|
|
14624
|
-
constructor(params
|
|
14624
|
+
constructor(params?: {
|
|
14625
14625
|
creator?: true;
|
|
14626
14626
|
hasUsername?: boolean;
|
|
14627
14627
|
userAdminRights?: TypeChatAdminRights;
|
|
@@ -14702,7 +14702,7 @@ export declare class AutoSaveSettings extends TypeAutoSaveSettings {
|
|
|
14702
14702
|
protected get [id](): number;
|
|
14703
14703
|
static get [paramDesc](): ParamDesc;
|
|
14704
14704
|
protected get [params](): Params;
|
|
14705
|
-
constructor(params
|
|
14705
|
+
constructor(params?: {
|
|
14706
14706
|
photos?: true;
|
|
14707
14707
|
videos?: true;
|
|
14708
14708
|
videoMaxSize?: bigint;
|