@mtkruto/node 0.152.0 → 0.154.0

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.
Files changed (117) hide show
  1. package/esm/4_constants.d.ts +1 -0
  2. package/esm/4_constants.d.ts.map +1 -1
  3. package/esm/4_constants.js +1 -0
  4. package/esm/client/0_client_abstract.d.ts +1 -1
  5. package/esm/client/0_client_abstract.d.ts.map +1 -1
  6. package/esm/client/0_client_abstract.js +2 -2
  7. package/esm/client/0_password.js +1 -1
  8. package/esm/client/0_utilities.d.ts +1 -1
  9. package/esm/client/0_utilities.d.ts.map +1 -1
  10. package/esm/client/0_utilities.js +4 -4
  11. package/esm/client/1_client_plain.d.ts +1 -1
  12. package/esm/client/1_client_plain.d.ts.map +1 -1
  13. package/esm/client/1_client_plain.js +27 -15
  14. package/esm/client/2_client_encrypted.d.ts +6 -3
  15. package/esm/client/2_client_encrypted.d.ts.map +1 -1
  16. package/esm/client/2_client_encrypted.js +157 -50
  17. package/esm/client/2_file_manager.js +7 -7
  18. package/esm/client/2_network_statistics_manager.d.ts +2 -2
  19. package/esm/client/2_network_statistics_manager.d.ts.map +1 -1
  20. package/esm/client/2_network_statistics_manager.js +13 -12
  21. package/esm/client/2_update_manager.d.ts.map +1 -1
  22. package/esm/client/2_update_manager.js +6 -1
  23. package/esm/client/6_client.d.ts +2 -0
  24. package/esm/client/6_client.d.ts.map +1 -1
  25. package/esm/client/6_client.js +14 -11
  26. package/esm/client/6_client_dispatcher.js +2 -2
  27. package/esm/connection/0_get_tls_header.js +5 -5
  28. package/esm/connection/1_connection_socks5.node.js +3 -3
  29. package/esm/connection/1_connection_tcp.node.js +3 -3
  30. package/esm/connection/1_connection_tls.node.js +3 -3
  31. package/esm/connection/1_connection_web_socket.js +4 -4
  32. package/esm/session/0_session_state.d.ts +1 -0
  33. package/esm/session/0_session_state.d.ts.map +1 -1
  34. package/esm/session/0_session_state.js +8 -4
  35. package/esm/session/1_session.d.ts +4 -3
  36. package/esm/session/1_session.d.ts.map +1 -1
  37. package/esm/session/1_session.js +8 -5
  38. package/esm/session/2_session_encrypted.d.ts +11 -6
  39. package/esm/session/2_session_encrypted.d.ts.map +1 -1
  40. package/esm/session/2_session_encrypted.js +22 -14
  41. package/esm/session/2_session_plain.js +2 -2
  42. package/esm/tl/1_tl_writer.js +5 -5
  43. package/esm/tl/2_message.js +1 -1
  44. package/esm/transport/1_transport_abridged.js +1 -1
  45. package/esm/transport/1_transport_intermediate.js +1 -1
  46. package/esm/transport/1_transport_provider.d.ts +2 -2
  47. package/esm/transport/1_transport_provider.d.ts.map +1 -1
  48. package/esm/transport/1_transport_provider.js +5 -5
  49. package/esm/transport/2_transport_provider_mtproxy.js +2 -2
  50. package/esm/transport/2_transport_provider_socks5.js +2 -2
  51. package/esm/transport/2_transport_provider_tcp.js +2 -2
  52. package/esm/transport/2_transport_provider_web_socket.js +3 -3
  53. package/esm/types/1_network_statistics.d.ts +1 -1
  54. package/esm/types/1_network_statistics.d.ts.map +1 -1
  55. package/esm/types/_file_id.js +1 -1
  56. package/esm/utilities/0_int.js +1 -1
  57. package/esm/utilities/1_auth.js +4 -4
  58. package/esm/utilities/1_crypto.js +7 -7
  59. package/package.json +1 -1
  60. package/script/4_constants.d.ts +1 -0
  61. package/script/4_constants.d.ts.map +1 -1
  62. package/script/4_constants.js +2 -1
  63. package/script/client/0_client_abstract.d.ts +1 -1
  64. package/script/client/0_client_abstract.d.ts.map +1 -1
  65. package/script/client/0_client_abstract.js +2 -2
  66. package/script/client/0_password.js +1 -1
  67. package/script/client/0_utilities.d.ts +1 -1
  68. package/script/client/0_utilities.d.ts.map +1 -1
  69. package/script/client/0_utilities.js +5 -5
  70. package/script/client/1_client_plain.d.ts +1 -1
  71. package/script/client/1_client_plain.d.ts.map +1 -1
  72. package/script/client/1_client_plain.js +26 -14
  73. package/script/client/2_client_encrypted.d.ts +6 -3
  74. package/script/client/2_client_encrypted.d.ts.map +1 -1
  75. package/script/client/2_client_encrypted.js +157 -50
  76. package/script/client/2_file_manager.js +7 -7
  77. package/script/client/2_network_statistics_manager.d.ts +2 -2
  78. package/script/client/2_network_statistics_manager.d.ts.map +1 -1
  79. package/script/client/2_network_statistics_manager.js +13 -12
  80. package/script/client/2_update_manager.d.ts.map +1 -1
  81. package/script/client/2_update_manager.js +6 -1
  82. package/script/client/6_client.d.ts +2 -0
  83. package/script/client/6_client.d.ts.map +1 -1
  84. package/script/client/6_client.js +14 -11
  85. package/script/client/6_client_dispatcher.js +2 -2
  86. package/script/connection/0_get_tls_header.js +5 -5
  87. package/script/connection/1_connection_socks5.node.js +3 -3
  88. package/script/connection/1_connection_tcp.node.js +3 -3
  89. package/script/connection/1_connection_tls.node.js +3 -3
  90. package/script/connection/1_connection_web_socket.js +4 -4
  91. package/script/session/0_session_state.d.ts +1 -0
  92. package/script/session/0_session_state.d.ts.map +1 -1
  93. package/script/session/0_session_state.js +8 -4
  94. package/script/session/1_session.d.ts +4 -3
  95. package/script/session/1_session.d.ts.map +1 -1
  96. package/script/session/1_session.js +8 -5
  97. package/script/session/2_session_encrypted.d.ts +11 -6
  98. package/script/session/2_session_encrypted.d.ts.map +1 -1
  99. package/script/session/2_session_encrypted.js +22 -14
  100. package/script/session/2_session_plain.js +2 -2
  101. package/script/tl/1_tl_writer.js +5 -5
  102. package/script/tl/2_message.js +1 -1
  103. package/script/transport/1_transport_abridged.js +1 -1
  104. package/script/transport/1_transport_intermediate.js +1 -1
  105. package/script/transport/1_transport_provider.d.ts +2 -2
  106. package/script/transport/1_transport_provider.d.ts.map +1 -1
  107. package/script/transport/1_transport_provider.js +5 -5
  108. package/script/transport/2_transport_provider_mtproxy.js +2 -2
  109. package/script/transport/2_transport_provider_socks5.js +2 -2
  110. package/script/transport/2_transport_provider_tcp.js +2 -2
  111. package/script/transport/2_transport_provider_web_socket.js +3 -3
  112. package/script/types/1_network_statistics.d.ts +1 -1
  113. package/script/types/1_network_statistics.d.ts.map +1 -1
  114. package/script/types/_file_id.js +1 -1
  115. package/script/utilities/0_int.js +1 -1
  116. package/script/utilities/1_auth.js +4 -4
  117. package/script/utilities/1_crypto.js +7 -7
@@ -58,9 +58,15 @@ export class SessionEncrypted extends Session {
58
58
  this.#authKeyId = intFromBytes(hash.slice(-8));
59
59
  this.#authKey = key;
60
60
  }
61
+ get id() {
62
+ return this.#id;
63
+ }
61
64
  get authKey() {
62
65
  return this.#authKey;
63
66
  }
67
+ get authKeyId() {
68
+ return this.#authKeyId;
69
+ }
64
70
  async connect() {
65
71
  if (!this.isConnected) {
66
72
  this.#rejectAllPending(new ConnectionError("The connection was closed."));
@@ -79,6 +85,8 @@ export class SessionEncrypted extends Session {
79
85
  super.disconnect();
80
86
  this.state.reset();
81
87
  this.#id = getRandomId();
88
+ this.#receiveLoop.abort();
89
+ this.#sendLoop.abort();
82
90
  this.#pingLoop.abort();
83
91
  this.#awakeSendLoop?.();
84
92
  this.#rejectAllPending(new ConnectionError("The connection was disconnected."));
@@ -137,11 +145,11 @@ export class SessionEncrypted extends Session {
137
145
  return;
138
146
  }
139
147
  // message was not sent by us
140
- this.handlers.onMessageFailed?.(id, reason);
148
+ drop(this.handlers.onMessageFailed?.(id, reason));
141
149
  }
142
150
  #setServerSalt(newServerSalt) {
143
151
  this.state.serverSalt = newServerSalt;
144
- this.handlers.onNewServerSalt?.(newServerSalt);
152
+ drop(this.handlers.onNewServerSalt?.(newServerSalt));
145
153
  }
146
154
  async send(body) {
147
155
  if (!this.isDisconnected && !this.isConnected) {
@@ -156,7 +164,7 @@ export class SessionEncrypted extends Session {
156
164
  async #receive() {
157
165
  this.#assertNotDisconnected();
158
166
  const buffer = await this.transport.transport.receive();
159
- if (buffer.length === 4) {
167
+ if (buffer.byteLength === 4) {
160
168
  const int = intFromBytes(buffer);
161
169
  throw new TransportError(Number(int));
162
170
  }
@@ -194,8 +202,8 @@ export class SessionEncrypted extends Session {
194
202
  assertEquals(reader.readInt64(), this.#authKeyId);
195
203
  const messageKey_ = reader.readInt128();
196
204
  const messageKey = intToBytes(messageKey_, 16);
197
- if (reader.buffer.length % 16 !== 0) {
198
- reader = new TLReader(reader.buffer.subarray(0, -(reader.buffer.length % 16)));
205
+ if (reader.buffer.byteLength % 16 !== 0) {
206
+ reader = new TLReader(reader.buffer.subarray(0, -(reader.buffer.byteLength % 16)));
199
207
  }
200
208
  const a = await sha256(concat([messageKey, this.#authKey.subarray(8, 44)]));
201
209
  const b = await sha256(concat([this.#authKey.subarray(48, 84), messageKey]));
@@ -301,11 +309,11 @@ export class SessionEncrypted extends Session {
301
309
  if (!this.isConnected) {
302
310
  this.#LreceiveLoop.debug("aborting as not connected");
303
311
  loop.abort();
304
- return;
305
312
  }
306
- else {
307
- return;
313
+ else if (err instanceof TransportError) {
314
+ await this.handlers.onTransportError?.(err);
308
315
  }
316
+ return;
309
317
  }
310
318
  try {
311
319
  if (message.body instanceof Uint8Array) {
@@ -321,7 +329,7 @@ export class SessionEncrypted extends Session {
321
329
  }
322
330
  //// RECEIVE LOOP HANDLERS ////
323
331
  async #onMessage(msgId, body, containerId) {
324
- this.#LreceiveLoop.debug("received message with ID", msgId, "and size", body.length, "inside", ...(containerId === null ? ["no container"] : ["container", containerId]));
332
+ this.#LreceiveLoop.debug("received message with ID", msgId, "and size", body.byteLength, "inside", ...(containerId === null ? ["no container"] : ["container", containerId]));
325
333
  const logger = this.#LreceiveLoop.branch(msgId + "");
326
334
  let reader = new TLReader(body);
327
335
  let id = reader.readInt32(false);
@@ -331,13 +339,13 @@ export class SessionEncrypted extends Session {
331
339
  id = reader.readInt32(false);
332
340
  }
333
341
  if (id === RPC_RESULT) {
334
- this.#onRpcResult(msgId, reader.buffer, logger);
342
+ await this.#onRpcResult(msgId, reader.buffer, logger);
335
343
  return;
336
344
  }
337
345
  if (!Mtproto.schema.identifierToName[id]) {
338
346
  logger.debug("identified body as a non-MTProto constructor");
339
347
  reader.unreadInt32();
340
- this.handlers.onUpdate?.(reader.buffer);
348
+ await this.handlers.onUpdate?.(reader.buffer);
341
349
  return;
342
350
  }
343
351
  let type;
@@ -390,10 +398,10 @@ export class SessionEncrypted extends Session {
390
398
  if (id === RPC_ERROR) {
391
399
  logger.debug("received rpc_error from message", msgId);
392
400
  const error = await Mtproto.deserializeType("rpc_error", reader);
393
- this.handlers.onRpcError?.(reqMsgId, error);
401
+ await this.handlers.onRpcError?.(reqMsgId, error);
394
402
  }
395
403
  else {
396
- this.handlers.onRpcResult?.(reqMsgId, reader.buffer);
404
+ await this.handlers.onRpcResult?.(reqMsgId, reader.buffer);
397
405
  }
398
406
  }
399
407
  #onMsgDetailedInfo(msgDetailedInfo, logger) {
@@ -445,7 +453,7 @@ export class SessionEncrypted extends Session {
445
453
  }
446
454
  else {
447
455
  // pong is not ours
448
- this.handlers.onPong?.(pong);
456
+ drop(this.handlers.onPong?.(pong));
449
457
  }
450
458
  }
451
459
  #onNewSessionCreated(msgId, newSessionCreated) {
@@ -31,7 +31,7 @@ export class SessionPlain extends Session {
31
31
  const writer = new TLWriter();
32
32
  writer.writeInt64(0n); // auth key ID
33
33
  writer.writeInt64(messageId);
34
- writer.writeInt32(data.length);
34
+ writer.writeInt32(data.byteLength);
35
35
  writer.write(data);
36
36
  const payload = writer.buffer;
37
37
  await this.transport.transport.send(payload);
@@ -42,7 +42,7 @@ export class SessionPlain extends Session {
42
42
  throw new ConnectionError("The connection is not open.");
43
43
  }
44
44
  const buffer = await this.transport.transport.receive();
45
- if (buffer.length === 4) {
45
+ if (buffer.byteLength === 4) {
46
46
  const int = intFromBytes(buffer);
47
47
  throw new TransportError(Number(int));
48
48
  }
@@ -63,14 +63,14 @@ export class TLWriter {
63
63
  }
64
64
  writeBytes(bytes) {
65
65
  let padding;
66
- if (bytes.length > 253) {
66
+ if (bytes.byteLength > 253) {
67
67
  this.write(new Uint8Array([254]));
68
- this.writeInt24(bytes.length);
69
- padding = bytes.length % 4;
68
+ this.writeInt24(bytes.byteLength);
69
+ padding = bytes.byteLength % 4;
70
70
  }
71
71
  else {
72
- this.write(new Uint8Array([bytes.length]));
73
- padding = (bytes.length + 1) % 4;
72
+ this.write(new Uint8Array([bytes.byteLength]));
73
+ padding = (bytes.byteLength + 1) % 4;
74
74
  }
75
75
  this.write(bytes);
76
76
  if (padding > 0) {
@@ -30,7 +30,7 @@ export async function serializeMessage(message) {
30
30
  const writer = new TLWriter()
31
31
  .writeInt64(message.msg_id)
32
32
  .writeInt32(message.seqno)
33
- .writeInt32(body.length)
33
+ .writeInt32(body.byteLength)
34
34
  .write(body);
35
35
  return writer.buffer;
36
36
  }
@@ -59,7 +59,7 @@ export class TransportAbridged extends Transport {
59
59
  return await this.decrypt(buffer);
60
60
  }
61
61
  async send(buffer) {
62
- const bufferLength = buffer.length / 4;
62
+ const bufferLength = buffer.byteLength / 4;
63
63
  const header = new Uint8Array([bufferLength >= 0x7F ? 0x7F : bufferLength]);
64
64
  const length = bufferLength >= 0x7F ? intToBytes(bufferLength, 3, { isSigned: false }) : new Uint8Array();
65
65
  const data = concat([header, length, buffer]);
@@ -62,7 +62,7 @@ export class TransportIntermediate extends Transport {
62
62
  const padding = dntShim.crypto.getRandomValues(new Uint8Array(Math.abs(getRandomId(true) % 16)));
63
63
  buffer = concat([buffer, padding]);
64
64
  }
65
- const length = intToBytes(buffer.length, 4);
65
+ const length = intToBytes(buffer.byteLength, 4);
66
66
  const data = concat([length, buffer]);
67
67
  await this.#connection.write(await this.encrypt(data));
68
68
  }
@@ -23,13 +23,13 @@ export type DC = "1" | "2" | "3" | "4" | "5" | "1-test" | "2-test" | "3-test";
23
23
  export declare function getDcIps(dc: DC, version: "ipv4" | "ipv6"): [string, ...string[]];
24
24
  export interface TransportProviderParams {
25
25
  dc: DC;
26
- isCdn: boolean;
26
+ isMedia: boolean;
27
27
  }
28
28
  export type TransportProvider = (params: TransportProviderParams) => {
29
29
  connection: Connection;
30
30
  transport: Transport;
31
31
  dcId: number;
32
32
  };
33
- export declare function getDcId(dc: DC, isCdn: boolean): number;
33
+ export declare function getDcId(dc: DC, isMedia: boolean): number;
34
34
  export declare function getDc(dcId: number): DC;
35
35
  //# sourceMappingURL=1_transport_provider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"1_transport_provider.d.ts","sourceRoot":"","sources":["../../src/transport/1_transport_provider.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAElD,MAAM,MAAM,EAAE,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,QAAQ,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAC9E,wBAAgB,QAAQ,CAAC,EAAE,EAAE,EAAE,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE,CAAC,CAiDhF;AAED,MAAM,WAAW,uBAAuB;IACtC,EAAE,EAAE,EAAE,CAAC;IACP,KAAK,EAAE,OAAO,CAAC;CAChB;AAED,MAAM,MAAM,iBAAiB,GAAG,CAAC,MAAM,EAAE,uBAAuB,KAAK;IAAE,UAAU,EAAE,UAAU,CAAC;IAAC,SAAS,EAAE,SAAS,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAEpI,wBAAgB,OAAO,CAAC,EAAE,EAAE,EAAE,EAAE,KAAK,EAAE,OAAO,GAAG,MAAM,CAEtD;AAED,wBAAgB,KAAK,CAAC,IAAI,EAAE,MAAM,GAAG,EAAE,CAOtC"}
1
+ {"version":3,"file":"1_transport_provider.d.ts","sourceRoot":"","sources":["../../src/transport/1_transport_provider.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAElD,MAAM,MAAM,EAAE,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,QAAQ,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAC9E,wBAAgB,QAAQ,CAAC,EAAE,EAAE,EAAE,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE,CAAC,CAiDhF;AAED,MAAM,WAAW,uBAAuB;IACtC,EAAE,EAAE,EAAE,CAAC;IACP,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,MAAM,MAAM,iBAAiB,GAAG,CAAC,MAAM,EAAE,uBAAuB,KAAK;IAAE,UAAU,EAAE,UAAU,CAAC;IAAC,SAAS,EAAE,SAAS,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAEpI,wBAAgB,OAAO,CAAC,EAAE,EAAE,EAAE,EAAE,OAAO,EAAE,OAAO,GAAG,MAAM,CAExD;AAED,wBAAgB,KAAK,CAAC,IAAI,EAAE,MAAM,GAAG,EAAE,CAOtC"}
@@ -68,14 +68,14 @@ export function getDcIps(dc, version) {
68
68
  unreachable();
69
69
  }
70
70
  }
71
- export function getDcId(dc, isCdn) {
72
- return Number(dc[0]) + (dc.endsWith("-test") ? 10_000 : 0) * (isCdn ? -1 : 1);
71
+ export function getDcId(dc, isMedia) {
72
+ return Number(dc[0]) + (dc.endsWith("-test") ? 10_000 : 0) * (isMedia ? -1 : 1);
73
73
  }
74
74
  export function getDc(dcId) {
75
75
  dcId = Math.abs(dcId);
76
- const test = dcId >= 10_000;
77
- if (dcId >= 10_000) {
76
+ const isTest = dcId >= 10_000;
77
+ if (isTest) {
78
78
  dcId -= 10_000;
79
79
  }
80
- return `${dcId}${test ? "-test" : ""}`;
80
+ return `${dcId}${isTest ? "-test" : ""}`;
81
81
  }
@@ -42,8 +42,8 @@ export function transportProviderMtproxy(urlOrHostname, port, secret) {
42
42
  throw new TypeError("Proxy secret must be at least 16 bytes.");
43
43
  }
44
44
  }
45
- return ({ dc, isCdn }) => {
46
- const dcId = getDcId(dc, isCdn);
45
+ return ({ dc, isMedia }) => {
46
+ const dcId = getDcId(dc, isMedia);
47
47
  const connection = secret.byteLength <= 17 ? new ConnectionTCP(hostname, port) : new ConnectionTLS(hostname, port, secret);
48
48
  const transport = new TransportIntermediate(connection, { isPadded: true, isObfuscated: true, secret, dcId });
49
49
  return { connection, transport, dcId };
@@ -36,8 +36,8 @@ export function transportProviderSocks5(urlOrHostname, port, params) {
36
36
  port = parseInt(port_);
37
37
  params = { ...(params ?? {}), username, password };
38
38
  }
39
- return ({ dc, isCdn }) => {
40
- const dcId = getDcId(dc, isCdn);
39
+ return ({ dc, isMedia }) => {
40
+ const dcId = getDcId(dc, isMedia);
41
41
  const connection = new ConnectionSocks5(getDcIps(dc, isIPv6(hostname) ? "ipv6" : "ipv4")[0], 80, hostname, port, params);
42
42
  const transport = new TransportAbridged(connection, false);
43
43
  return { connection, transport, dcId };
@@ -21,9 +21,9 @@ import { ConnectionTCP } from "../connection/1_connection_tcp.node.js";
21
21
  import { TransportAbridged } from "./1_transport_abridged.js";
22
22
  import { getDcId, getDcIps } from "./1_transport_provider.js";
23
23
  export function transportProviderTcp(params) {
24
- return ({ dc, isCdn: cdn }) => {
24
+ return ({ dc, isMedia }) => {
25
25
  const connection = new ConnectionTCP(getDcIps(dc, params?.ipv6 ? "ipv6" : "ipv4")[0], 80);
26
26
  const transport = new TransportAbridged(connection, params?.obfuscated);
27
- return { connection, transport, dcId: getDcId(dc, cdn) };
27
+ return { connection, transport, dcId: getDcId(dc, isMedia) };
28
28
  };
29
29
  }
@@ -31,12 +31,12 @@ const dcToNameMap = {
31
31
  "5": "flora",
32
32
  };
33
33
  export const transportProviderWebSocket = (params) => {
34
- return ({ dc, isCdn }) => {
34
+ return ({ dc, isMedia }) => {
35
35
  params ??= {};
36
36
  params.wss ??= typeof location !== "undefined" && location.protocol === "http:" && location.hostname !== "localhost" ? false : true;
37
- const url = `${params.wss ? "wss" : "ws"}://${dcToNameMap[dc]}${isCdn ? "-1" : ""}.web.telegram.org/${dc.endsWith("-test") ? "apiws_test" : "apiws"}`;
37
+ const url = `${params.wss ? "wss" : "ws"}://${dcToNameMap[dc]}${isMedia ? "-1" : ""}.web.telegram.org/${dc.endsWith("-test") ? "apiws_test" : "apiws"}`;
38
38
  const connection = new ConnectionWebSocket(url);
39
- const dcId = getDcId(dc, isCdn);
39
+ const dcId = getDcId(dc, isMedia);
40
40
  const transport = new TransportIntermediate(connection, { isObfuscated: true, dcId });
41
41
  return { connection, transport, dcId };
42
42
  };
@@ -21,6 +21,6 @@ import type { NetworkStatisticsEntry } from "./0_network_statistics_entry.js";
21
21
  /** A client's network statistics. */
22
22
  export interface NetworkStatistics {
23
23
  messages: NetworkStatisticsEntry;
24
- cdn: NetworkStatisticsEntry;
24
+ media: NetworkStatisticsEntry;
25
25
  }
26
26
  //# sourceMappingURL=1_network_statistics.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"1_network_statistics.d.ts","sourceRoot":"","sources":["../../src/types/1_network_statistics.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,iCAAiC,CAAC;AAE9E,qCAAqC;AACrC,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,sBAAsB,CAAC;IACjC,GAAG,EAAE,sBAAsB,CAAC;CAC7B"}
1
+ {"version":3,"file":"1_network_statistics.d.ts","sourceRoot":"","sources":["../../src/types/1_network_statistics.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,iCAAiC,CAAC;AAE9E,qCAAqC;AACrC,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,sBAAsB,CAAC;IACjC,KAAK,EAAE,sBAAsB,CAAC;CAC/B"}
@@ -254,7 +254,7 @@ function hasFileReference(fileType) {
254
254
  }
255
255
  export function deserializeFileId(fileId) {
256
256
  const reader = new TLReader(rleDecode(base64DecodeUrlSafe(fileId)));
257
- if (reader.buffer[reader.buffer.length - 1] !== PERSISTENT_ID_VERSION) {
257
+ if (reader.buffer[reader.buffer.byteLength - 1] !== PERSISTENT_ID_VERSION) {
258
258
  throw new InputError("Unsupported file ID format");
259
259
  }
260
260
  const originalType = reader.readInt32();
@@ -47,7 +47,7 @@ export function mod(n, m) {
47
47
  * @param params Additional parameters.
48
48
  */
49
49
  export function intFromBytes(bytes, { byteOrder = "little", isSigned = true } = {}) {
50
- const bytesLength = bytes.length;
50
+ const bytesLength = bytes.byteLength;
51
51
  if (byteOrder === "little") {
52
52
  bytes = bytes.toReversed();
53
53
  }
@@ -22,14 +22,14 @@ import { assert, assertEquals, concat, ige256Encrypt } from "../0_deps.js";
22
22
  import { sha256 } from "./0_hash.js";
23
23
  import { intFromBytes, intToBytes, modExp } from "./0_int.js";
24
24
  export async function rsaPad(data, [serverKey, exponent]) {
25
- assert(data.length <= 144);
25
+ assert(data.byteLength <= 144);
26
26
  let keyAesEncryptedInt;
27
27
  let tries = 0;
28
28
  do {
29
29
  if (++tries === 10) {
30
30
  throw new Error("Out of tries");
31
31
  }
32
- const dataWithPadding = concat([data, new Uint8Array(192 - data.length)]);
32
+ const dataWithPadding = concat([data, new Uint8Array(192 - data.byteLength)]);
33
33
  const dataPadReversed = new Uint8Array(dataWithPadding).reverse();
34
34
  const tempKey = dntShim.crypto.getRandomValues(new Uint8Array(32));
35
35
  const dataWithHash = concat([dataPadReversed, await sha256(concat([tempKey, dataWithPadding]))]);
@@ -37,11 +37,11 @@ export async function rsaPad(data, [serverKey, exponent]) {
37
37
  const aesEncryptedSha256 = await sha256(aesEncrypted);
38
38
  const tempKeyXor = tempKey.map((v, i) => v ^ aesEncryptedSha256[i]);
39
39
  const keyAesEncrypted = concat([tempKeyXor, aesEncrypted]);
40
- assertEquals(keyAesEncrypted.length, 256);
40
+ assertEquals(keyAesEncrypted.byteLength, 256);
41
41
  keyAesEncryptedInt = intFromBytes(keyAesEncrypted, { byteOrder: "big", isSigned: false });
42
42
  } while (keyAesEncryptedInt >= serverKey);
43
43
  const encryptedDataInt = modExp(keyAesEncryptedInt, exponent, serverKey);
44
44
  const encryptedData = intToBytes(encryptedDataInt, 256, { byteOrder: "big", isSigned: false });
45
- assertEquals(encryptedData.length, 256);
45
+ assertEquals(encryptedData.byteLength, 256);
46
46
  return encryptedData;
47
47
  }
@@ -44,11 +44,11 @@ export class CTR {
44
44
  async #call(data) {
45
45
  let header;
46
46
  if (this.#bytesUntilNextBlock) {
47
- const headerLength = Math.min(data.length, this.#iv.length - this.#bytesUntilNextBlock);
47
+ const headerLength = Math.min(data.byteLength, this.#iv.byteLength - this.#bytesUntilNextBlock);
48
48
  const encrypted = await this.#encrypt(concat([new Uint8Array(this.#bytesUntilNextBlock), data.subarray(0, headerLength)]));
49
49
  header = encrypted.subarray(this.#bytesUntilNextBlock);
50
50
  data = data.subarray(headerLength);
51
- if (encrypted.length === this.#iv.length) {
51
+ if (encrypted.byteLength === this.#iv.byteLength) {
52
52
  this.#increaseIv(1);
53
53
  this.#bytesUntilNextBlock = 0;
54
54
  }
@@ -56,26 +56,26 @@ export class CTR {
56
56
  this.#bytesUntilNextBlock += headerLength;
57
57
  }
58
58
  }
59
- if (!data.length && header) {
59
+ if (!data.byteLength && header) {
60
60
  return header;
61
61
  }
62
62
  const encrypted = await this.#encrypt(data);
63
- this.#bytesUntilNextBlock = encrypted.length % this.#iv.length;
64
- this.#increaseIv((encrypted.length - this.#bytesUntilNextBlock) / this.#iv.length);
63
+ this.#bytesUntilNextBlock = encrypted.byteLength % this.#iv.byteLength;
64
+ this.#increaseIv((encrypted.byteLength - this.#bytesUntilNextBlock) / this.#iv.byteLength);
65
65
  return header ? concat([header, encrypted]) : encrypted;
66
66
  }
67
67
  async #encrypt(data) {
68
68
  return new Uint8Array(await dntShim.crypto.subtle.encrypt({
69
69
  name: "AES-CTR",
70
70
  counter: new Uint8Array(this.#iv),
71
- length: this.#iv.length * 8,
71
+ length: this.#iv.byteLength * 8,
72
72
  }, this.#key, data));
73
73
  }
74
74
  #increaseIv(amount) {
75
75
  if (amount < 1) {
76
76
  return;
77
77
  }
78
- this.#iv = intToBytes(intFromBytes(this.#iv, { byteOrder: "big", isSigned: false }) + BigInt(amount), this.#iv.length, { byteOrder: "big", isSigned: false });
78
+ this.#iv = intToBytes(intFromBytes(this.#iv, { byteOrder: "big", isSigned: false }) + BigInt(amount), this.#iv.byteLength, { byteOrder: "big", isSigned: false });
79
79
  }
80
80
  }
81
81
  export async function hmacSha256(data, secret) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mtkruto/node",
3
- "version": "0.152.0",
3
+ "version": "0.154.0",
4
4
  "description": "MTKruto for Node.js",
5
5
  "author": "Roj <rojvv@icloud.com>",
6
6
  "repository": {
@@ -16,4 +16,5 @@ export declare const MAX_CHANNEL_ID = 997852516352;
16
16
  export declare const CHANNEL_DIFFERENCE_LIMIT_USER = 100;
17
17
  export declare const CHANNEL_DIFFERENCE_LIMIT_BOT = 100000;
18
18
  export declare const DOWNLOAD_MAX_CHUNK_SIZE: number;
19
+ export declare const TEMPORARY_AUTH_KEY_TTL = 86400;
19
20
  //# sourceMappingURL=4_constants.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"4_constants.d.ts","sourceRoot":"","sources":["../src/4_constants.ts"],"names":[],"mappings":"AAuBA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,kBAAkB,CAAC;AAE3C,MAAM,MAAM,UAAU,GAAG,SAAS,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,EAAE,CAAC;AAE/D,eAAO,MAAM,WAAW,EAAE,UAkDxB,CAAC;AAEH,eAAO,MAAM,UAAU,EAAE,EAAQ,CAAC;AAElC,eAAO,MAAM,WAAW,YAAY,CAAC;AAGrC,eAAO,MAAM,YAAY,EAAE,MAA+Q,CAAC;AAE3S,eAAO,MAAM,SAAS,EAAE,MAA6H,CAAC;AAEtJ,eAAO,MAAM,SAAS,KAAK,CAAC;AAE5B,eAAO,MAAM,gBAAgB,QAAY,CAAC;AAG1C,eAAO,MAAM,cAAc,QAA2I,CAAC;AAEvK,eAAO,MAAM,YAAY,QAAS,CAAC;AAEnC,eAAO,MAAM,gBAAgB,QAAS,CAAC;AAEvC,eAAO,MAAM,oBAAoB,SAAU,CAAC;AAE5C,eAAO,MAAM,WAAW,eAAe,CAAC;AAExC,eAAO,MAAM,cAAc,eAAe,CAAC;AAE3C,eAAO,MAAM,6BAA6B,MAAM,CAAC;AAEjD,eAAO,MAAM,4BAA4B,SAAU,CAAC;AAEpD,eAAO,MAAM,uBAAuB,QAAe,CAAC"}
1
+ {"version":3,"file":"4_constants.d.ts","sourceRoot":"","sources":["../src/4_constants.ts"],"names":[],"mappings":"AAuBA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,kBAAkB,CAAC;AAE3C,MAAM,MAAM,UAAU,GAAG,SAAS,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,EAAE,CAAC;AAE/D,eAAO,MAAM,WAAW,EAAE,UAkDxB,CAAC;AAEH,eAAO,MAAM,UAAU,EAAE,EAAQ,CAAC;AAElC,eAAO,MAAM,WAAW,YAAY,CAAC;AAGrC,eAAO,MAAM,YAAY,EAAE,MAA+Q,CAAC;AAE3S,eAAO,MAAM,SAAS,EAAE,MAA6H,CAAC;AAEtJ,eAAO,MAAM,SAAS,KAAK,CAAC;AAE5B,eAAO,MAAM,gBAAgB,QAAY,CAAC;AAG1C,eAAO,MAAM,cAAc,QAA2I,CAAC;AAEvK,eAAO,MAAM,YAAY,QAAS,CAAC;AAEnC,eAAO,MAAM,gBAAgB,QAAS,CAAC;AAEvC,eAAO,MAAM,oBAAoB,SAAU,CAAC;AAE5C,eAAO,MAAM,WAAW,eAAe,CAAC;AAExC,eAAO,MAAM,cAAc,eAAe,CAAC;AAE3C,eAAO,MAAM,6BAA6B,MAAM,CAAC;AAEjD,eAAO,MAAM,4BAA4B,SAAU,CAAC;AAEpD,eAAO,MAAM,uBAAuB,QAAe,CAAC;AAEpD,eAAO,MAAM,sBAAsB,QAAS,CAAC"}
@@ -33,7 +33,7 @@ var __importStar = (this && this.__importStar) || (function () {
33
33
  };
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.DOWNLOAD_MAX_CHUNK_SIZE = exports.CHANNEL_DIFFERENCE_LIMIT_BOT = exports.CHANNEL_DIFFERENCE_LIMIT_USER = exports.MAX_CHANNEL_ID = exports.MAX_CHAT_ID = exports.STICKER_SET_NAME_TTL = exports.PHONE_NUMBER_TTL = exports.USERNAME_TTL = exports.SYSTEM_VERSION = exports.SYSTEM_LANG_CODE = exports.LANG_PACK = exports.LANG_CODE = exports.DEVICE_MODEL = exports.APP_VERSION = exports.INITIAL_DC = exports.PUBLIC_KEYS = void 0;
36
+ exports.TEMPORARY_AUTH_KEY_TTL = exports.DOWNLOAD_MAX_CHUNK_SIZE = exports.CHANNEL_DIFFERENCE_LIMIT_BOT = exports.CHANNEL_DIFFERENCE_LIMIT_USER = exports.MAX_CHANNEL_ID = exports.MAX_CHAT_ID = exports.STICKER_SET_NAME_TTL = exports.PHONE_NUMBER_TTL = exports.USERNAME_TTL = exports.SYSTEM_VERSION = exports.SYSTEM_LANG_CODE = exports.LANG_PACK = exports.LANG_CODE = exports.DEVICE_MODEL = exports.APP_VERSION = exports.INITIAL_DC = exports.PUBLIC_KEYS = void 0;
37
37
  /**
38
38
  * MTKruto - Cross-runtime JavaScript library for building Telegram clients
39
39
  * Copyright (C) 2023-2026 Roj <https://roj.im/>
@@ -123,3 +123,4 @@ exports.MAX_CHANNEL_ID = 997852516352;
123
123
  exports.CHANNEL_DIFFERENCE_LIMIT_USER = 100;
124
124
  exports.CHANNEL_DIFFERENCE_LIMIT_BOT = 100_000;
125
125
  exports.DOWNLOAD_MAX_CHUNK_SIZE = 1 * _1_utilities_js_1.megabyte;
126
+ exports.TEMPORARY_AUTH_KEY_TTL = 86_400;
@@ -23,7 +23,7 @@ import type { Session } from "../4_session.js";
23
23
  export declare abstract class ClientAbstract {
24
24
  abstract session: Session;
25
25
  get dc(): DC;
26
- get isCdn(): boolean;
26
+ get isMedia(): boolean;
27
27
  set serverSalt(serverSalt: bigint);
28
28
  get serverSalt(): bigint;
29
29
  get isConnected(): boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"0_client_abstract.d.ts","sourceRoot":"","sources":["../../src/client/0_client_abstract.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AACzE,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAE/C,8BAAsB,cAAc;IAClC,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;IAE1B,IAAI,EAAE,IAAI,EAAE,CAEX;IAED,IAAI,KAAK,IAAI,OAAO,CAEnB;IAED,IAAI,UAAU,CAAC,UAAU,EAAE,MAAM,EAEhC;IAED,IAAI,UAAU,IAAI,MAAM,CAEvB;IAED,IAAI,WAAW,IAAI,OAAO,CAEzB;IAEK,OAAO;IAIb,IAAI,cAAc,IAAI,OAAO,CAE5B;IAED,UAAU;IAIV,IAAI,kBAAkB,CAAC,kBAAkB,EAAE,kBAAkB,GAAG,SAAS,EAExE;IAED,IAAI,uBAAuB,CAAC,uBAAuB,EAAE,UAAU,CAAC,oBAAoB,CAAC,EAEpF;CACF"}
1
+ {"version":3,"file":"0_client_abstract.d.ts","sourceRoot":"","sources":["../../src/client/0_client_abstract.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AACzE,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAE/C,8BAAsB,cAAc;IAClC,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;IAE1B,IAAI,EAAE,IAAI,EAAE,CAEX;IAED,IAAI,OAAO,IAAI,OAAO,CAErB;IAED,IAAI,UAAU,CAAC,UAAU,EAAE,MAAM,EAEhC;IAED,IAAI,UAAU,IAAI,MAAM,CAEvB;IAED,IAAI,WAAW,IAAI,OAAO,CAEzB;IAEK,OAAO;IAIb,IAAI,cAAc,IAAI,OAAO,CAE5B;IAED,UAAU;IAIV,IAAI,kBAAkB,CAAC,kBAAkB,EAAE,kBAAkB,GAAG,SAAS,EAExE;IAED,IAAI,uBAAuB,CAAC,uBAAuB,EAAE,UAAU,CAAC,oBAAoB,CAAC,EAEpF;CACF"}
@@ -24,8 +24,8 @@ class ClientAbstract {
24
24
  get dc() {
25
25
  return this.session.dc;
26
26
  }
27
- get isCdn() {
28
- return this.session.isCdn;
27
+ get isMedia() {
28
+ return this.session.isMedia;
29
29
  }
30
30
  set serverSalt(serverSalt) {
31
31
  this.session.serverSalt = serverSalt;
@@ -128,7 +128,7 @@ function pad(bigint) {
128
128
  return (0, _1_utilities_js_1.intToBytes)(bigint, 256, { byteOrder: "big", isSigned: false });
129
129
  }
130
130
  else {
131
- return (0, _0_deps_js_1.concat)([new Uint8Array(256 - bigint.length), bigint]);
131
+ return (0, _0_deps_js_1.concat)([new Uint8Array(256 - bigint.byteLength), bigint]);
132
132
  }
133
133
  }
134
134
  async function checkPassword(password_, ap) {
@@ -29,7 +29,7 @@ export declare function checkPollOption(option: string): void;
29
29
  export declare function checkArray<T>(array: T[], check: (value: T) => void): void;
30
30
  export declare function checkCallbackQueryId(id: string): void;
31
31
  export declare function checkInlineQueryId(id: string): void;
32
- export declare function isCdnFunction(value: unknown): value is Api.invokeWithBusinessConnectionPrefix | Api.invokeWithGooglePlayIntegrityPrefix | Api.invokeWithApnsSecretPrefix | Api.invokeWithReCaptchaPrefix | Api.auth_sendCode | Api.auth_signUp | Api.auth_signIn | Api.auth_logOut | Api.auth_resetAuthorizations | Api.auth_exportAuthorization | Api.auth_importAuthorization | Api.auth_bindTempAuthKey | Api.auth_importBotAuthorization | Api.auth_checkPassword | Api.auth_requestPasswordRecovery | Api.auth_recoverPassword | Api.auth_resendCode | Api.auth_cancelCode | Api.auth_dropTempAuthKeys | Api.auth_exportLoginToken | Api.auth_importLoginToken | Api.auth_acceptLoginToken | Api.auth_checkRecoveryPassword | Api.auth_importWebTokenAuthorization | Api.auth_requestFirebaseSms | Api.auth_resetLoginEmail | Api.auth_reportMissingCode | Api.auth_checkPaidAuth | Api.auth_initPasskeyLogin | Api.auth_finishPasskeyLogin | Api.account_registerDevice | Api.account_unregisterDevice | Api.account_updateNotifySettings | Api.account_getNotifySettings | Api.account_resetNotifySettings | Api.account_updateProfile | Api.account_updateStatus | Api.account_getWallPapers | Api.account_reportPeer | Api.account_checkUsername | Api.account_updateUsername | Api.account_getPrivacy | Api.account_setPrivacy | Api.account_deleteAccount | Api.account_getAccountTTL | Api.account_setAccountTTL | Api.account_sendChangePhoneCode | Api.account_changePhone | Api.account_updateDeviceLocked | Api.account_getAuthorizations | Api.account_resetAuthorization | Api.account_getPassword | Api.account_getPasswordSettings | Api.account_updatePasswordSettings | Api.account_sendConfirmPhoneCode | Api.account_confirmPhone | Api.account_getTmpPassword | Api.account_getWebAuthorizations | Api.account_resetWebAuthorization | Api.account_resetWebAuthorizations | Api.account_getAllSecureValues | Api.account_getSecureValue | Api.account_saveSecureValue | Api.account_deleteSecureValue | Api.account_getAuthorizationForm | Api.account_acceptAuthorization | Api.account_sendVerifyPhoneCode | Api.account_verifyPhone | Api.account_sendVerifyEmailCode | Api.account_verifyEmail | Api.account_initTakeoutSession | Api.account_finishTakeoutSession | Api.account_confirmPasswordEmail | Api.account_resendPasswordEmail | Api.account_cancelPasswordEmail | Api.account_getContactSignUpNotification | Api.account_setContactSignUpNotification | Api.account_getNotifyExceptions | Api.account_getWallPaper | Api.account_uploadWallPaper | Api.account_saveWallPaper | Api.account_installWallPaper | Api.account_resetWallPapers | Api.account_getAutoDownloadSettings | Api.account_saveAutoDownloadSettings | Api.account_uploadTheme | Api.account_createTheme | Api.account_updateTheme | Api.account_saveTheme | Api.account_installTheme | Api.account_getTheme | Api.account_getThemes | Api.account_setContentSettings | Api.account_getContentSettings | Api.account_getMultiWallPapers | Api.account_getGlobalPrivacySettings | Api.account_setGlobalPrivacySettings | Api.account_reportProfilePhoto | Api.account_resetPassword | Api.account_declinePasswordReset | Api.account_getChatThemes | Api.account_setAuthorizationTTL | Api.account_changeAuthorizationSettings | Api.account_getSavedRingtones | Api.account_saveRingtone | Api.account_uploadRingtone | Api.account_updateEmojiStatus | Api.account_getDefaultEmojiStatuses | Api.account_getRecentEmojiStatuses | Api.account_clearRecentEmojiStatuses | Api.account_reorderUsernames | Api.account_toggleUsername | Api.account_getDefaultProfilePhotoEmojis | Api.account_getDefaultGroupPhotoEmojis | Api.account_getAutoSaveSettings | Api.account_saveAutoSaveSettings | Api.account_deleteAutoSaveExceptions | Api.account_invalidateSignInCodes | Api.account_updateColor | Api.account_getDefaultBackgroundEmojis | Api.account_getChannelDefaultEmojiStatuses | Api.account_getChannelRestrictedStatusEmojis | Api.account_updateBusinessWorkHours | Api.account_updateBusinessLocation | Api.account_updateBusinessGreetingMessage | Api.account_updateBusinessAwayMessage | Api.account_updateConnectedBot | Api.account_getConnectedBots | Api.account_getBotBusinessConnection | Api.account_updateBusinessIntro | Api.account_toggleConnectedBotPaused | Api.account_disablePeerConnectedBot | Api.account_updateBirthday | Api.account_createBusinessChatLink | Api.account_editBusinessChatLink | Api.account_deleteBusinessChatLink | Api.account_getBusinessChatLinks | Api.account_resolveBusinessChatLink | Api.account_updatePersonalChannel | Api.account_toggleSponsoredMessages | Api.account_getReactionsNotifySettings | Api.account_setReactionsNotifySettings | Api.account_getCollectibleEmojiStatuses | Api.account_getPaidMessagesRevenue | Api.account_toggleNoPaidMessagesException | Api.account_setMainProfileTab | Api.account_saveMusic | Api.account_getSavedMusicIds | Api.account_getUniqueGiftChatThemes | Api.account_initPasskeyRegistration | Api.account_registerPasskey | Api.account_getPasskeys | Api.account_deletePasskey | Api.account_confirmBotConnection | Api.account_getWebBrowserSettings | Api.account_updateWebBrowserSettings | Api.account_toggleWebBrowserSettingsException | Api.account_deleteWebBrowserSettingsExceptions | Api.users_getUsers | Api.users_getFullUser | Api.users_setSecureValueErrors | Api.users_getRequirementsToContact | Api.users_getSavedMusic | Api.users_getSavedMusicByID | Api.users_suggestBirthday | Api.contacts_getContactIDs | Api.contacts_getStatuses | Api.contacts_getContacts | Api.contacts_importContacts | Api.contacts_deleteContacts | Api.contacts_deleteByPhones | Api.contacts_block | Api.contacts_unblock | Api.contacts_getBlocked | Api.contacts_search | Api.contacts_resolveUsername | Api.contacts_getTopPeers | Api.contacts_resetTopPeerRating | Api.contacts_resetSaved | Api.contacts_getSaved | Api.contacts_toggleTopPeers | Api.contacts_addContact | Api.contacts_acceptContact | Api.contacts_getLocated | Api.contacts_blockFromReplies | Api.contacts_resolvePhone | Api.contacts_exportContactToken | Api.contacts_importContactToken | Api.contacts_editCloseFriends | Api.contacts_setBlocked | Api.contacts_getBirthdays | Api.contacts_getSponsoredPeers | Api.contacts_updateContactNote | Api.messages_getMessages | Api.messages_getDialogs | Api.messages_getHistory | Api.messages_search | Api.messages_readHistory | Api.messages_deleteHistory | Api.messages_deleteMessages | Api.messages_receivedMessages | Api.messages_setTyping | Api.messages_sendMessage | Api.messages_sendMedia | Api.messages_forwardMessages | Api.messages_reportSpam | Api.messages_getPeerSettings | Api.messages_report | Api.messages_getChats | Api.messages_getFullChat | Api.messages_editChatTitle | Api.messages_editChatPhoto | Api.messages_addChatUser | Api.messages_deleteChatUser | Api.messages_createChat | Api.messages_getDhConfig | Api.messages_requestEncryption | Api.messages_acceptEncryption | Api.messages_discardEncryption | Api.messages_setEncryptedTyping | Api.messages_readEncryptedHistory | Api.messages_sendEncrypted | Api.messages_sendEncryptedFile | Api.messages_sendEncryptedService | Api.messages_receivedQueue | Api.messages_reportEncryptedSpam | Api.messages_readMessageContents | Api.messages_getStickers | Api.messages_getAllStickers | Api.messages_getWebPagePreview | Api.messages_exportChatInvite | Api.messages_checkChatInvite | Api.messages_importChatInvite | Api.messages_getStickerSet | Api.messages_installStickerSet | Api.messages_uninstallStickerSet | Api.messages_startBot | Api.messages_getMessagesViews | Api.messages_editChatAdmin | Api.messages_migrateChat | Api.messages_searchGlobal | Api.messages_reorderStickerSets | Api.messages_getDocumentByHash | Api.messages_getSavedGifs | Api.messages_saveGif | Api.messages_getInlineBotResults | Api.messages_setInlineBotResults | Api.messages_sendInlineBotResult | Api.messages_getMessageEditData | Api.messages_editMessage | Api.messages_editInlineBotMessage | Api.messages_getBotCallbackAnswer | Api.messages_setBotCallbackAnswer | Api.messages_getPeerDialogs | Api.messages_saveDraft | Api.messages_getAllDrafts | Api.messages_getFeaturedStickers | Api.messages_readFeaturedStickers | Api.messages_getRecentStickers | Api.messages_saveRecentSticker | Api.messages_clearRecentStickers | Api.messages_getArchivedStickers | Api.messages_getMaskStickers | Api.messages_getAttachedStickers | Api.messages_setGameScore | Api.messages_setInlineGameScore | Api.messages_getGameHighScores | Api.messages_getInlineGameHighScores | Api.messages_getCommonChats | Api.messages_getWebPage | Api.messages_toggleDialogPin | Api.messages_reorderPinnedDialogs | Api.messages_getPinnedDialogs | Api.messages_setBotShippingResults | Api.messages_setBotPrecheckoutResults | Api.messages_uploadMedia | Api.messages_sendScreenshotNotification | Api.messages_getFavedStickers | Api.messages_faveSticker | Api.messages_getUnreadMentions | Api.messages_readMentions | Api.messages_getRecentLocations | Api.messages_sendMultiMedia | Api.messages_uploadEncryptedFile | Api.messages_searchStickerSets | Api.messages_getSplitRanges | Api.messages_markDialogUnread | Api.messages_getDialogUnreadMarks | Api.messages_clearAllDrafts | Api.messages_updatePinnedMessage | Api.messages_sendVote | Api.messages_getPollResults | Api.messages_getOnlines | Api.messages_editChatAbout | Api.messages_editChatDefaultBannedRights | Api.messages_getEmojiKeywords | Api.messages_getEmojiKeywordsDifference | Api.messages_getEmojiKeywordsLanguages | Api.messages_getEmojiURL | Api.messages_getSearchCounters | Api.messages_requestUrlAuth | Api.messages_acceptUrlAuth | Api.messages_hidePeerSettingsBar | Api.messages_getScheduledHistory | Api.messages_getScheduledMessages | Api.messages_sendScheduledMessages | Api.messages_deleteScheduledMessages | Api.messages_getPollVotes | Api.messages_toggleStickerSets | Api.messages_getDialogFilters | Api.messages_getSuggestedDialogFilters | Api.messages_updateDialogFilter | Api.messages_updateDialogFiltersOrder | Api.messages_getOldFeaturedStickers | Api.messages_getReplies | Api.messages_getDiscussionMessage | Api.messages_readDiscussion | Api.messages_unpinAllMessages | Api.messages_deleteChat | Api.messages_deletePhoneCallHistory | Api.messages_checkHistoryImport | Api.messages_initHistoryImport | Api.messages_uploadImportedMedia | Api.messages_startHistoryImport | Api.messages_getExportedChatInvites | Api.messages_getExportedChatInvite | Api.messages_editExportedChatInvite | Api.messages_deleteRevokedExportedChatInvites | Api.messages_deleteExportedChatInvite | Api.messages_getAdminsWithInvites | Api.messages_getChatInviteImporters | Api.messages_setHistoryTTL | Api.messages_checkHistoryImportPeer | Api.messages_setChatTheme | Api.messages_getMessageReadParticipants | Api.messages_getSearchResultsCalendar | Api.messages_getSearchResultsPositions | Api.messages_hideChatJoinRequest | Api.messages_hideAllChatJoinRequests | Api.messages_toggleNoForwards | Api.messages_saveDefaultSendAs | Api.messages_sendReaction | Api.messages_getMessagesReactions | Api.messages_getMessageReactionsList | Api.messages_setChatAvailableReactions | Api.messages_getAvailableReactions | Api.messages_setDefaultReaction | Api.messages_translateText | Api.messages_getUnreadReactions | Api.messages_readReactions | Api.messages_searchSentMedia | Api.messages_getAttachMenuBots | Api.messages_getAttachMenuBot | Api.messages_toggleBotInAttachMenu | Api.messages_requestWebView | Api.messages_prolongWebView | Api.messages_requestSimpleWebView | Api.messages_sendWebViewResultMessage | Api.messages_sendWebViewData | Api.messages_transcribeAudio | Api.messages_rateTranscribedAudio | Api.messages_getCustomEmojiDocuments | Api.messages_getEmojiStickers | Api.messages_getFeaturedEmojiStickers | Api.messages_reportReaction | Api.messages_getTopReactions | Api.messages_getRecentReactions | Api.messages_clearRecentReactions | Api.messages_getExtendedMedia | Api.messages_setDefaultHistoryTTL | Api.messages_getDefaultHistoryTTL | Api.messages_sendBotRequestedPeer | Api.messages_getEmojiGroups | Api.messages_getEmojiStatusGroups | Api.messages_getEmojiProfilePhotoGroups | Api.messages_searchCustomEmoji | Api.messages_togglePeerTranslations | Api.messages_getBotApp | Api.messages_requestAppWebView | Api.messages_setChatWallPaper | Api.messages_searchEmojiStickerSets | Api.messages_getSavedDialogs | Api.messages_getSavedHistory | Api.messages_deleteSavedHistory | Api.messages_getPinnedSavedDialogs | Api.messages_toggleSavedDialogPin | Api.messages_reorderPinnedSavedDialogs | Api.messages_getSavedReactionTags | Api.messages_updateSavedReactionTag | Api.messages_getDefaultTagReactions | Api.messages_getOutboxReadDate | Api.messages_getQuickReplies | Api.messages_reorderQuickReplies | Api.messages_checkQuickReplyShortcut | Api.messages_editQuickReplyShortcut | Api.messages_deleteQuickReplyShortcut | Api.messages_getQuickReplyMessages | Api.messages_sendQuickReplyMessages | Api.messages_deleteQuickReplyMessages | Api.messages_toggleDialogFilterTags | Api.messages_getMyStickers | Api.messages_getEmojiStickerGroups | Api.messages_getAvailableEffects | Api.messages_editFactCheck | Api.messages_deleteFactCheck | Api.messages_getFactCheck | Api.messages_requestMainWebView | Api.messages_sendPaidReaction | Api.messages_togglePaidReactionPrivacy | Api.messages_getPaidReactionPrivacy | Api.messages_viewSponsoredMessage | Api.messages_clickSponsoredMessage | Api.messages_reportSponsoredMessage | Api.messages_getSponsoredMessages | Api.messages_savePreparedInlineMessage | Api.messages_getPreparedInlineMessage | Api.messages_searchStickers | Api.messages_reportMessagesDelivery | Api.messages_getSavedDialogsByID | Api.messages_readSavedHistory | Api.messages_toggleTodoCompleted | Api.messages_appendTodoList | Api.messages_toggleSuggestedPostApproval | Api.messages_getForumTopics | Api.messages_getForumTopicsByID | Api.messages_editForumTopic | Api.messages_updatePinnedForumTopic | Api.messages_reorderPinnedForumTopics | Api.messages_createForumTopic | Api.messages_deleteTopicHistory | Api.messages_getEmojiGameInfo | Api.messages_summarizeText | Api.messages_editChatCreator | Api.messages_getFutureChatCreatorAfterLeave | Api.messages_editChatParticipantRank | Api.messages_declineUrlAuth | Api.messages_checkUrlAuthMatchCode | Api.messages_composeMessageWithAI | Api.messages_reportReadMetrics | Api.messages_reportMusicListen | Api.messages_addPollAnswer | Api.messages_deletePollAnswer | Api.messages_getUnreadPollVotes | Api.messages_readPollVotes | Api.messages_setBotGuestChatResult | Api.messages_deleteParticipantReactions | Api.messages_deleteParticipantReaction | Api.messages_getPersonalChannelHistory | Api.messages_getRichMessage | Api.updates_getState | Api.updates_getDifference | Api.updates_getChannelDifference | Api.photos_updateProfilePhoto | Api.photos_uploadProfilePhoto | Api.photos_deletePhotos | Api.photos_getUserPhotos | Api.photos_uploadContactProfilePhoto | Api.upload_saveFilePart | Api.upload_getFile | Api.upload_saveBigFilePart | Api.upload_getWebFile | Api.upload_getCdnFile | Api.upload_reuploadCdnFile | Api.upload_getCdnFileHashes | Api.upload_getFileHashes | Api.help_getConfig | Api.help_getNearestDc | Api.help_getAppUpdate | Api.help_getInviteText | Api.help_getSupport | Api.help_setBotUpdatesStatus | Api.help_getCdnConfig | Api.help_getRecentMeUrls | Api.help_getTermsOfServiceUpdate | Api.help_acceptTermsOfService | Api.help_getDeepLinkInfo | Api.help_getAppConfig | Api.help_saveAppLog | Api.help_getPassportConfig | Api.help_getSupportName | Api.help_getUserInfo | Api.help_editUserInfo | Api.help_getPromoData | Api.help_hidePromoData | Api.help_dismissSuggestion | Api.help_getCountriesList | Api.help_getPremiumPromo | Api.help_getPeerColors | Api.help_getPeerProfileColors | Api.help_getTimezonesList | Api.channels_readHistory | Api.channels_deleteMessages | Api.channels_reportSpam | Api.channels_getMessages | Api.channels_getParticipants | Api.channels_getParticipant | Api.channels_getChannels | Api.channels_getFullChannel | Api.channels_createChannel | Api.channels_editAdmin | Api.channels_editTitle | Api.channels_editPhoto | Api.channels_checkUsername | Api.channels_updateUsername | Api.channels_joinChannel | Api.channels_leaveChannel | Api.channels_inviteToChannel | Api.channels_deleteChannel | Api.channels_exportMessageLink | Api.channels_toggleSignatures | Api.channels_getAdminedPublicChannels | Api.channels_editBanned | Api.channels_getAdminLog | Api.channels_setStickers | Api.channels_readMessageContents | Api.channels_deleteHistory | Api.channels_togglePreHistoryHidden | Api.channels_getLeftChannels | Api.channels_getGroupsForDiscussion | Api.channels_setDiscussionGroup | Api.channels_editLocation | Api.channels_toggleSlowMode | Api.channels_getInactiveChannels | Api.channels_convertToGigagroup | Api.channels_getSendAs | Api.channels_deleteParticipantHistory | Api.channels_toggleJoinToSend | Api.channels_toggleJoinRequest | Api.channels_reorderUsernames | Api.channels_toggleUsername | Api.channels_deactivateAllUsernames | Api.channels_toggleForum | Api.channels_toggleAntiSpam | Api.channels_reportAntiSpamFalsePositive | Api.channels_toggleParticipantsHidden | Api.channels_updateColor | Api.channels_toggleViewForumAsMessages | Api.channels_getChannelRecommendations | Api.channels_updateEmojiStatus | Api.channels_setBoostsToUnblockRestrictions | Api.channels_setEmojiStickers | Api.channels_restrictSponsoredMessages | Api.channels_searchPosts | Api.channels_updatePaidMessagesPrice | Api.channels_toggleAutotranslation | Api.channels_getMessageAuthor | Api.channels_checkSearchPostsFlood | Api.channels_setMainProfileTab | Api.bots_sendCustomRequest | Api.bots_answerWebhookJSONQuery | Api.bots_setBotCommands | Api.bots_resetBotCommands | Api.bots_getBotCommands | Api.bots_setBotMenuButton | Api.bots_getBotMenuButton | Api.bots_setBotBroadcastDefaultAdminRights | Api.bots_setBotGroupDefaultAdminRights | Api.bots_setBotInfo | Api.bots_getBotInfo | Api.bots_reorderUsernames | Api.bots_toggleUsername | Api.bots_canSendMessage | Api.bots_allowSendMessage | Api.bots_invokeWebViewCustomMethod | Api.bots_getPopularAppBots | Api.bots_addPreviewMedia | Api.bots_editPreviewMedia | Api.bots_deletePreviewMedia | Api.bots_reorderPreviewMedias | Api.bots_getPreviewInfo | Api.bots_getPreviewMedias | Api.bots_updateUserEmojiStatus | Api.bots_toggleUserEmojiStatusPermission | Api.bots_checkDownloadFileParams | Api.bots_getAdminedBots | Api.bots_updateStarRefProgram | Api.bots_setCustomVerification | Api.bots_getBotRecommendations | Api.bots_checkUsername | Api.bots_createBot | Api.bots_exportBotToken | Api.bots_requestWebViewButton | Api.bots_getRequestedWebViewButton | Api.bots_getAccessSettings | Api.bots_editAccessSettings | Api.bots_setJoinChatResults | Api.payments_getPaymentForm | Api.payments_getPaymentReceipt | Api.payments_validateRequestedInfo | Api.payments_sendPaymentForm | Api.payments_getSavedInfo | Api.payments_clearSavedInfo | Api.payments_getBankCardData | Api.payments_exportInvoice | Api.payments_assignAppStoreTransaction | Api.payments_assignPlayMarketTransaction | Api.payments_getPremiumGiftCodeOptions | Api.payments_checkGiftCode | Api.payments_applyGiftCode | Api.payments_getGiveawayInfo | Api.payments_launchPrepaidGiveaway | Api.payments_getStarsTopupOptions | Api.payments_getStarsStatus | Api.payments_getStarsTransactions | Api.payments_sendStarsForm | Api.payments_refundStarsCharge | Api.payments_getStarsRevenueStats | Api.payments_getStarsRevenueWithdrawalUrl | Api.payments_getStarsRevenueAdsAccountUrl | Api.payments_getStarsTransactionsByID | Api.payments_getStarsGiftOptions | Api.payments_getStarsSubscriptions | Api.payments_changeStarsSubscription | Api.payments_fulfillStarsSubscription | Api.payments_getStarsGiveawayOptions | Api.payments_getStarGifts | Api.payments_saveStarGift | Api.payments_convertStarGift | Api.payments_botCancelStarsSubscription | Api.payments_getConnectedStarRefBots | Api.payments_getConnectedStarRefBot | Api.payments_getSuggestedStarRefBots | Api.payments_connectStarRefBot | Api.payments_editConnectedStarRefBot | Api.payments_getStarGiftUpgradePreview | Api.payments_upgradeStarGift | Api.payments_transferStarGift | Api.payments_getUniqueStarGift | Api.payments_getSavedStarGifts | Api.payments_getSavedStarGift | Api.payments_getStarGiftWithdrawalUrl | Api.payments_toggleChatStarGiftNotifications | Api.payments_toggleStarGiftsPinnedToTop | Api.payments_canPurchaseStore | Api.payments_getResaleStarGifts | Api.payments_updateStarGiftPrice | Api.payments_createStarGiftCollection | Api.payments_updateStarGiftCollection | Api.payments_reorderStarGiftCollections | Api.payments_deleteStarGiftCollection | Api.payments_getStarGiftCollections | Api.payments_getUniqueStarGiftValueInfo | Api.payments_checkCanSendGift | Api.payments_getStarGiftAuctionState | Api.payments_getStarGiftAuctionAcquiredGifts | Api.payments_getStarGiftActiveAuctions | Api.payments_resolveStarGiftOffer | Api.payments_sendStarGiftOffer | Api.payments_getStarGiftUpgradeAttributes | Api.payments_getCraftStarGifts | Api.payments_craftStarGift | Api.stickers_createStickerSet | Api.stickers_removeStickerFromSet | Api.stickers_changeStickerPosition | Api.stickers_addStickerToSet | Api.stickers_setStickerSetThumb | Api.stickers_checkShortName | Api.stickers_suggestShortName | Api.stickers_changeSticker | Api.stickers_renameStickerSet | Api.stickers_deleteStickerSet | Api.stickers_replaceSticker | Api.phone_getCallConfig | Api.phone_requestCall | Api.phone_acceptCall | Api.phone_confirmCall | Api.phone_receivedCall | Api.phone_discardCall | Api.phone_setCallRating | Api.phone_saveCallDebug | Api.phone_sendSignalingData | Api.phone_createGroupCall | Api.phone_joinGroupCall | Api.phone_leaveGroupCall | Api.phone_inviteToGroupCall | Api.phone_discardGroupCall | Api.phone_toggleGroupCallSettings | Api.phone_getGroupCall | Api.phone_getGroupParticipants | Api.phone_checkGroupCall | Api.phone_toggleGroupCallRecord | Api.phone_editGroupCallParticipant | Api.phone_editGroupCallTitle | Api.phone_getGroupCallJoinAs | Api.phone_exportGroupCallInvite | Api.phone_toggleGroupCallStartSubscription | Api.phone_startScheduledGroupCall | Api.phone_saveDefaultGroupCallJoinAs | Api.phone_joinGroupCallPresentation | Api.phone_leaveGroupCallPresentation | Api.phone_getGroupCallStreamChannels | Api.phone_getGroupCallStreamRtmpUrl | Api.phone_saveCallLog | Api.phone_createConferenceCall | Api.phone_deleteConferenceCallParticipants | Api.phone_sendConferenceCallBroadcast | Api.phone_inviteConferenceCallParticipant | Api.phone_declineConferenceCallInvite | Api.phone_getGroupCallChainBlocks | Api.phone_sendGroupCallMessage | Api.phone_sendGroupCallEncryptedMessage | Api.phone_deleteGroupCallMessages | Api.phone_deleteGroupCallParticipantMessages | Api.phone_getGroupCallStars | Api.phone_saveDefaultSendAs | Api.langpack_getLangPack | Api.langpack_getStrings | Api.langpack_getDifference | Api.langpack_getLanguages | Api.langpack_getLanguage | Api.folders_editPeerFolders | Api.stats_getBroadcastStats | Api.stats_loadAsyncGraph | Api.stats_getMegagroupStats | Api.stats_getMessagePublicForwards | Api.stats_getMessageStats | Api.stats_getStoryStats | Api.stats_getStoryPublicForwards | Api.stats_getPollStats | Api.chatlists_exportChatlistInvite | Api.chatlists_deleteExportedInvite | Api.chatlists_editExportedInvite | Api.chatlists_getExportedInvites | Api.chatlists_checkChatlistInvite | Api.chatlists_joinChatlistInvite | Api.chatlists_getChatlistUpdates | Api.chatlists_joinChatlistUpdates | Api.chatlists_hideChatlistUpdates | Api.chatlists_getLeaveChatlistSuggestions | Api.chatlists_leaveChatlist | Api.stories_canSendStory | Api.stories_sendStory | Api.stories_editStory | Api.stories_deleteStories | Api.stories_togglePinned | Api.stories_getAllStories | Api.stories_getPinnedStories | Api.stories_getStoriesArchive | Api.stories_getStoriesByID | Api.stories_toggleAllStoriesHidden | Api.stories_readStories | Api.stories_incrementStoryViews | Api.stories_getStoryViewsList | Api.stories_getStoriesViews | Api.stories_exportStoryLink | Api.stories_report | Api.stories_activateStealthMode | Api.stories_sendReaction | Api.stories_getPeerStories | Api.stories_getAllReadPeerStories | Api.stories_getPeerMaxIDs | Api.stories_getChatsToSend | Api.stories_togglePeerStoriesHidden | Api.stories_getStoryReactionsList | Api.stories_togglePinnedToTop | Api.stories_searchPosts | Api.stories_createAlbum | Api.stories_updateAlbum | Api.stories_reorderAlbums | Api.stories_deleteAlbum | Api.stories_getAlbums | Api.stories_getAlbumStories | Api.stories_startLive | Api.premium_getBoostsList | Api.premium_getMyBoosts | Api.premium_applyBoost | Api.premium_getBoostsStatus | Api.premium_getUserBoosts | Api.smsjobs_isEligibleToJoin | Api.smsjobs_join | Api.smsjobs_leave | Api.smsjobs_updateSettings | Api.smsjobs_getStatus | Api.smsjobs_getSmsJob | Api.smsjobs_finishJob | Api.fragment_getCollectibleInfo | Api.aicompose_createTone | Api.aicompose_updateTone | Api.aicompose_saveTone | Api.aicompose_deleteTone | Api.aicompose_getTone | Api.aicompose_getTones | Api.aicompose_getToneExample | Api.invokeAfterMsg<Api.Function> | Api.invokeAfterMsgs<Api.Function> | Api.initConnection<Api.Function> | Api.invokeWithLayer<Api.Function> | Api.invokeWithoutUpdates<Api.Function> | Api.invokeWithMessagesRange<Api.Function> | Api.invokeWithTakeout<Api.Function> | Api.invokeWithBusinessConnection<Api.Function> | Api.invokeWithGooglePlayIntegrity<Api.Function> | Api.invokeWithApnsSecret<Api.Function> | Api.invokeWithReCaptcha<Api.Function>;
32
+ export declare function isMediaFunction(value: unknown): value is Api.invokeWithBusinessConnectionPrefix | Api.invokeWithGooglePlayIntegrityPrefix | Api.invokeWithApnsSecretPrefix | Api.invokeWithReCaptchaPrefix | Api.auth_sendCode | Api.auth_signUp | Api.auth_signIn | Api.auth_logOut | Api.auth_resetAuthorizations | Api.auth_exportAuthorization | Api.auth_importAuthorization | Api.auth_bindTempAuthKey | Api.auth_importBotAuthorization | Api.auth_checkPassword | Api.auth_requestPasswordRecovery | Api.auth_recoverPassword | Api.auth_resendCode | Api.auth_cancelCode | Api.auth_dropTempAuthKeys | Api.auth_exportLoginToken | Api.auth_importLoginToken | Api.auth_acceptLoginToken | Api.auth_checkRecoveryPassword | Api.auth_importWebTokenAuthorization | Api.auth_requestFirebaseSms | Api.auth_resetLoginEmail | Api.auth_reportMissingCode | Api.auth_checkPaidAuth | Api.auth_initPasskeyLogin | Api.auth_finishPasskeyLogin | Api.account_registerDevice | Api.account_unregisterDevice | Api.account_updateNotifySettings | Api.account_getNotifySettings | Api.account_resetNotifySettings | Api.account_updateProfile | Api.account_updateStatus | Api.account_getWallPapers | Api.account_reportPeer | Api.account_checkUsername | Api.account_updateUsername | Api.account_getPrivacy | Api.account_setPrivacy | Api.account_deleteAccount | Api.account_getAccountTTL | Api.account_setAccountTTL | Api.account_sendChangePhoneCode | Api.account_changePhone | Api.account_updateDeviceLocked | Api.account_getAuthorizations | Api.account_resetAuthorization | Api.account_getPassword | Api.account_getPasswordSettings | Api.account_updatePasswordSettings | Api.account_sendConfirmPhoneCode | Api.account_confirmPhone | Api.account_getTmpPassword | Api.account_getWebAuthorizations | Api.account_resetWebAuthorization | Api.account_resetWebAuthorizations | Api.account_getAllSecureValues | Api.account_getSecureValue | Api.account_saveSecureValue | Api.account_deleteSecureValue | Api.account_getAuthorizationForm | Api.account_acceptAuthorization | Api.account_sendVerifyPhoneCode | Api.account_verifyPhone | Api.account_sendVerifyEmailCode | Api.account_verifyEmail | Api.account_initTakeoutSession | Api.account_finishTakeoutSession | Api.account_confirmPasswordEmail | Api.account_resendPasswordEmail | Api.account_cancelPasswordEmail | Api.account_getContactSignUpNotification | Api.account_setContactSignUpNotification | Api.account_getNotifyExceptions | Api.account_getWallPaper | Api.account_uploadWallPaper | Api.account_saveWallPaper | Api.account_installWallPaper | Api.account_resetWallPapers | Api.account_getAutoDownloadSettings | Api.account_saveAutoDownloadSettings | Api.account_uploadTheme | Api.account_createTheme | Api.account_updateTheme | Api.account_saveTheme | Api.account_installTheme | Api.account_getTheme | Api.account_getThemes | Api.account_setContentSettings | Api.account_getContentSettings | Api.account_getMultiWallPapers | Api.account_getGlobalPrivacySettings | Api.account_setGlobalPrivacySettings | Api.account_reportProfilePhoto | Api.account_resetPassword | Api.account_declinePasswordReset | Api.account_getChatThemes | Api.account_setAuthorizationTTL | Api.account_changeAuthorizationSettings | Api.account_getSavedRingtones | Api.account_saveRingtone | Api.account_uploadRingtone | Api.account_updateEmojiStatus | Api.account_getDefaultEmojiStatuses | Api.account_getRecentEmojiStatuses | Api.account_clearRecentEmojiStatuses | Api.account_reorderUsernames | Api.account_toggleUsername | Api.account_getDefaultProfilePhotoEmojis | Api.account_getDefaultGroupPhotoEmojis | Api.account_getAutoSaveSettings | Api.account_saveAutoSaveSettings | Api.account_deleteAutoSaveExceptions | Api.account_invalidateSignInCodes | Api.account_updateColor | Api.account_getDefaultBackgroundEmojis | Api.account_getChannelDefaultEmojiStatuses | Api.account_getChannelRestrictedStatusEmojis | Api.account_updateBusinessWorkHours | Api.account_updateBusinessLocation | Api.account_updateBusinessGreetingMessage | Api.account_updateBusinessAwayMessage | Api.account_updateConnectedBot | Api.account_getConnectedBots | Api.account_getBotBusinessConnection | Api.account_updateBusinessIntro | Api.account_toggleConnectedBotPaused | Api.account_disablePeerConnectedBot | Api.account_updateBirthday | Api.account_createBusinessChatLink | Api.account_editBusinessChatLink | Api.account_deleteBusinessChatLink | Api.account_getBusinessChatLinks | Api.account_resolveBusinessChatLink | Api.account_updatePersonalChannel | Api.account_toggleSponsoredMessages | Api.account_getReactionsNotifySettings | Api.account_setReactionsNotifySettings | Api.account_getCollectibleEmojiStatuses | Api.account_getPaidMessagesRevenue | Api.account_toggleNoPaidMessagesException | Api.account_setMainProfileTab | Api.account_saveMusic | Api.account_getSavedMusicIds | Api.account_getUniqueGiftChatThemes | Api.account_initPasskeyRegistration | Api.account_registerPasskey | Api.account_getPasskeys | Api.account_deletePasskey | Api.account_confirmBotConnection | Api.account_getWebBrowserSettings | Api.account_updateWebBrowserSettings | Api.account_toggleWebBrowserSettingsException | Api.account_deleteWebBrowserSettingsExceptions | Api.users_getUsers | Api.users_getFullUser | Api.users_setSecureValueErrors | Api.users_getRequirementsToContact | Api.users_getSavedMusic | Api.users_getSavedMusicByID | Api.users_suggestBirthday | Api.contacts_getContactIDs | Api.contacts_getStatuses | Api.contacts_getContacts | Api.contacts_importContacts | Api.contacts_deleteContacts | Api.contacts_deleteByPhones | Api.contacts_block | Api.contacts_unblock | Api.contacts_getBlocked | Api.contacts_search | Api.contacts_resolveUsername | Api.contacts_getTopPeers | Api.contacts_resetTopPeerRating | Api.contacts_resetSaved | Api.contacts_getSaved | Api.contacts_toggleTopPeers | Api.contacts_addContact | Api.contacts_acceptContact | Api.contacts_getLocated | Api.contacts_blockFromReplies | Api.contacts_resolvePhone | Api.contacts_exportContactToken | Api.contacts_importContactToken | Api.contacts_editCloseFriends | Api.contacts_setBlocked | Api.contacts_getBirthdays | Api.contacts_getSponsoredPeers | Api.contacts_updateContactNote | Api.messages_getMessages | Api.messages_getDialogs | Api.messages_getHistory | Api.messages_search | Api.messages_readHistory | Api.messages_deleteHistory | Api.messages_deleteMessages | Api.messages_receivedMessages | Api.messages_setTyping | Api.messages_sendMessage | Api.messages_sendMedia | Api.messages_forwardMessages | Api.messages_reportSpam | Api.messages_getPeerSettings | Api.messages_report | Api.messages_getChats | Api.messages_getFullChat | Api.messages_editChatTitle | Api.messages_editChatPhoto | Api.messages_addChatUser | Api.messages_deleteChatUser | Api.messages_createChat | Api.messages_getDhConfig | Api.messages_requestEncryption | Api.messages_acceptEncryption | Api.messages_discardEncryption | Api.messages_setEncryptedTyping | Api.messages_readEncryptedHistory | Api.messages_sendEncrypted | Api.messages_sendEncryptedFile | Api.messages_sendEncryptedService | Api.messages_receivedQueue | Api.messages_reportEncryptedSpam | Api.messages_readMessageContents | Api.messages_getStickers | Api.messages_getAllStickers | Api.messages_getWebPagePreview | Api.messages_exportChatInvite | Api.messages_checkChatInvite | Api.messages_importChatInvite | Api.messages_getStickerSet | Api.messages_installStickerSet | Api.messages_uninstallStickerSet | Api.messages_startBot | Api.messages_getMessagesViews | Api.messages_editChatAdmin | Api.messages_migrateChat | Api.messages_searchGlobal | Api.messages_reorderStickerSets | Api.messages_getDocumentByHash | Api.messages_getSavedGifs | Api.messages_saveGif | Api.messages_getInlineBotResults | Api.messages_setInlineBotResults | Api.messages_sendInlineBotResult | Api.messages_getMessageEditData | Api.messages_editMessage | Api.messages_editInlineBotMessage | Api.messages_getBotCallbackAnswer | Api.messages_setBotCallbackAnswer | Api.messages_getPeerDialogs | Api.messages_saveDraft | Api.messages_getAllDrafts | Api.messages_getFeaturedStickers | Api.messages_readFeaturedStickers | Api.messages_getRecentStickers | Api.messages_saveRecentSticker | Api.messages_clearRecentStickers | Api.messages_getArchivedStickers | Api.messages_getMaskStickers | Api.messages_getAttachedStickers | Api.messages_setGameScore | Api.messages_setInlineGameScore | Api.messages_getGameHighScores | Api.messages_getInlineGameHighScores | Api.messages_getCommonChats | Api.messages_getWebPage | Api.messages_toggleDialogPin | Api.messages_reorderPinnedDialogs | Api.messages_getPinnedDialogs | Api.messages_setBotShippingResults | Api.messages_setBotPrecheckoutResults | Api.messages_uploadMedia | Api.messages_sendScreenshotNotification | Api.messages_getFavedStickers | Api.messages_faveSticker | Api.messages_getUnreadMentions | Api.messages_readMentions | Api.messages_getRecentLocations | Api.messages_sendMultiMedia | Api.messages_uploadEncryptedFile | Api.messages_searchStickerSets | Api.messages_getSplitRanges | Api.messages_markDialogUnread | Api.messages_getDialogUnreadMarks | Api.messages_clearAllDrafts | Api.messages_updatePinnedMessage | Api.messages_sendVote | Api.messages_getPollResults | Api.messages_getOnlines | Api.messages_editChatAbout | Api.messages_editChatDefaultBannedRights | Api.messages_getEmojiKeywords | Api.messages_getEmojiKeywordsDifference | Api.messages_getEmojiKeywordsLanguages | Api.messages_getEmojiURL | Api.messages_getSearchCounters | Api.messages_requestUrlAuth | Api.messages_acceptUrlAuth | Api.messages_hidePeerSettingsBar | Api.messages_getScheduledHistory | Api.messages_getScheduledMessages | Api.messages_sendScheduledMessages | Api.messages_deleteScheduledMessages | Api.messages_getPollVotes | Api.messages_toggleStickerSets | Api.messages_getDialogFilters | Api.messages_getSuggestedDialogFilters | Api.messages_updateDialogFilter | Api.messages_updateDialogFiltersOrder | Api.messages_getOldFeaturedStickers | Api.messages_getReplies | Api.messages_getDiscussionMessage | Api.messages_readDiscussion | Api.messages_unpinAllMessages | Api.messages_deleteChat | Api.messages_deletePhoneCallHistory | Api.messages_checkHistoryImport | Api.messages_initHistoryImport | Api.messages_uploadImportedMedia | Api.messages_startHistoryImport | Api.messages_getExportedChatInvites | Api.messages_getExportedChatInvite | Api.messages_editExportedChatInvite | Api.messages_deleteRevokedExportedChatInvites | Api.messages_deleteExportedChatInvite | Api.messages_getAdminsWithInvites | Api.messages_getChatInviteImporters | Api.messages_setHistoryTTL | Api.messages_checkHistoryImportPeer | Api.messages_setChatTheme | Api.messages_getMessageReadParticipants | Api.messages_getSearchResultsCalendar | Api.messages_getSearchResultsPositions | Api.messages_hideChatJoinRequest | Api.messages_hideAllChatJoinRequests | Api.messages_toggleNoForwards | Api.messages_saveDefaultSendAs | Api.messages_sendReaction | Api.messages_getMessagesReactions | Api.messages_getMessageReactionsList | Api.messages_setChatAvailableReactions | Api.messages_getAvailableReactions | Api.messages_setDefaultReaction | Api.messages_translateText | Api.messages_getUnreadReactions | Api.messages_readReactions | Api.messages_searchSentMedia | Api.messages_getAttachMenuBots | Api.messages_getAttachMenuBot | Api.messages_toggleBotInAttachMenu | Api.messages_requestWebView | Api.messages_prolongWebView | Api.messages_requestSimpleWebView | Api.messages_sendWebViewResultMessage | Api.messages_sendWebViewData | Api.messages_transcribeAudio | Api.messages_rateTranscribedAudio | Api.messages_getCustomEmojiDocuments | Api.messages_getEmojiStickers | Api.messages_getFeaturedEmojiStickers | Api.messages_reportReaction | Api.messages_getTopReactions | Api.messages_getRecentReactions | Api.messages_clearRecentReactions | Api.messages_getExtendedMedia | Api.messages_setDefaultHistoryTTL | Api.messages_getDefaultHistoryTTL | Api.messages_sendBotRequestedPeer | Api.messages_getEmojiGroups | Api.messages_getEmojiStatusGroups | Api.messages_getEmojiProfilePhotoGroups | Api.messages_searchCustomEmoji | Api.messages_togglePeerTranslations | Api.messages_getBotApp | Api.messages_requestAppWebView | Api.messages_setChatWallPaper | Api.messages_searchEmojiStickerSets | Api.messages_getSavedDialogs | Api.messages_getSavedHistory | Api.messages_deleteSavedHistory | Api.messages_getPinnedSavedDialogs | Api.messages_toggleSavedDialogPin | Api.messages_reorderPinnedSavedDialogs | Api.messages_getSavedReactionTags | Api.messages_updateSavedReactionTag | Api.messages_getDefaultTagReactions | Api.messages_getOutboxReadDate | Api.messages_getQuickReplies | Api.messages_reorderQuickReplies | Api.messages_checkQuickReplyShortcut | Api.messages_editQuickReplyShortcut | Api.messages_deleteQuickReplyShortcut | Api.messages_getQuickReplyMessages | Api.messages_sendQuickReplyMessages | Api.messages_deleteQuickReplyMessages | Api.messages_toggleDialogFilterTags | Api.messages_getMyStickers | Api.messages_getEmojiStickerGroups | Api.messages_getAvailableEffects | Api.messages_editFactCheck | Api.messages_deleteFactCheck | Api.messages_getFactCheck | Api.messages_requestMainWebView | Api.messages_sendPaidReaction | Api.messages_togglePaidReactionPrivacy | Api.messages_getPaidReactionPrivacy | Api.messages_viewSponsoredMessage | Api.messages_clickSponsoredMessage | Api.messages_reportSponsoredMessage | Api.messages_getSponsoredMessages | Api.messages_savePreparedInlineMessage | Api.messages_getPreparedInlineMessage | Api.messages_searchStickers | Api.messages_reportMessagesDelivery | Api.messages_getSavedDialogsByID | Api.messages_readSavedHistory | Api.messages_toggleTodoCompleted | Api.messages_appendTodoList | Api.messages_toggleSuggestedPostApproval | Api.messages_getForumTopics | Api.messages_getForumTopicsByID | Api.messages_editForumTopic | Api.messages_updatePinnedForumTopic | Api.messages_reorderPinnedForumTopics | Api.messages_createForumTopic | Api.messages_deleteTopicHistory | Api.messages_getEmojiGameInfo | Api.messages_summarizeText | Api.messages_editChatCreator | Api.messages_getFutureChatCreatorAfterLeave | Api.messages_editChatParticipantRank | Api.messages_declineUrlAuth | Api.messages_checkUrlAuthMatchCode | Api.messages_composeMessageWithAI | Api.messages_reportReadMetrics | Api.messages_reportMusicListen | Api.messages_addPollAnswer | Api.messages_deletePollAnswer | Api.messages_getUnreadPollVotes | Api.messages_readPollVotes | Api.messages_setBotGuestChatResult | Api.messages_deleteParticipantReactions | Api.messages_deleteParticipantReaction | Api.messages_getPersonalChannelHistory | Api.messages_getRichMessage | Api.updates_getState | Api.updates_getDifference | Api.updates_getChannelDifference | Api.photos_updateProfilePhoto | Api.photos_uploadProfilePhoto | Api.photos_deletePhotos | Api.photos_getUserPhotos | Api.photos_uploadContactProfilePhoto | Api.upload_saveFilePart | Api.upload_getFile | Api.upload_saveBigFilePart | Api.upload_getWebFile | Api.upload_getCdnFile | Api.upload_reuploadCdnFile | Api.upload_getCdnFileHashes | Api.upload_getFileHashes | Api.help_getConfig | Api.help_getNearestDc | Api.help_getAppUpdate | Api.help_getInviteText | Api.help_getSupport | Api.help_setBotUpdatesStatus | Api.help_getCdnConfig | Api.help_getRecentMeUrls | Api.help_getTermsOfServiceUpdate | Api.help_acceptTermsOfService | Api.help_getDeepLinkInfo | Api.help_getAppConfig | Api.help_saveAppLog | Api.help_getPassportConfig | Api.help_getSupportName | Api.help_getUserInfo | Api.help_editUserInfo | Api.help_getPromoData | Api.help_hidePromoData | Api.help_dismissSuggestion | Api.help_getCountriesList | Api.help_getPremiumPromo | Api.help_getPeerColors | Api.help_getPeerProfileColors | Api.help_getTimezonesList | Api.channels_readHistory | Api.channels_deleteMessages | Api.channels_reportSpam | Api.channels_getMessages | Api.channels_getParticipants | Api.channels_getParticipant | Api.channels_getChannels | Api.channels_getFullChannel | Api.channels_createChannel | Api.channels_editAdmin | Api.channels_editTitle | Api.channels_editPhoto | Api.channels_checkUsername | Api.channels_updateUsername | Api.channels_joinChannel | Api.channels_leaveChannel | Api.channels_inviteToChannel | Api.channels_deleteChannel | Api.channels_exportMessageLink | Api.channels_toggleSignatures | Api.channels_getAdminedPublicChannels | Api.channels_editBanned | Api.channels_getAdminLog | Api.channels_setStickers | Api.channels_readMessageContents | Api.channels_deleteHistory | Api.channels_togglePreHistoryHidden | Api.channels_getLeftChannels | Api.channels_getGroupsForDiscussion | Api.channels_setDiscussionGroup | Api.channels_editLocation | Api.channels_toggleSlowMode | Api.channels_getInactiveChannels | Api.channels_convertToGigagroup | Api.channels_getSendAs | Api.channels_deleteParticipantHistory | Api.channels_toggleJoinToSend | Api.channels_toggleJoinRequest | Api.channels_reorderUsernames | Api.channels_toggleUsername | Api.channels_deactivateAllUsernames | Api.channels_toggleForum | Api.channels_toggleAntiSpam | Api.channels_reportAntiSpamFalsePositive | Api.channels_toggleParticipantsHidden | Api.channels_updateColor | Api.channels_toggleViewForumAsMessages | Api.channels_getChannelRecommendations | Api.channels_updateEmojiStatus | Api.channels_setBoostsToUnblockRestrictions | Api.channels_setEmojiStickers | Api.channels_restrictSponsoredMessages | Api.channels_searchPosts | Api.channels_updatePaidMessagesPrice | Api.channels_toggleAutotranslation | Api.channels_getMessageAuthor | Api.channels_checkSearchPostsFlood | Api.channels_setMainProfileTab | Api.bots_sendCustomRequest | Api.bots_answerWebhookJSONQuery | Api.bots_setBotCommands | Api.bots_resetBotCommands | Api.bots_getBotCommands | Api.bots_setBotMenuButton | Api.bots_getBotMenuButton | Api.bots_setBotBroadcastDefaultAdminRights | Api.bots_setBotGroupDefaultAdminRights | Api.bots_setBotInfo | Api.bots_getBotInfo | Api.bots_reorderUsernames | Api.bots_toggleUsername | Api.bots_canSendMessage | Api.bots_allowSendMessage | Api.bots_invokeWebViewCustomMethod | Api.bots_getPopularAppBots | Api.bots_addPreviewMedia | Api.bots_editPreviewMedia | Api.bots_deletePreviewMedia | Api.bots_reorderPreviewMedias | Api.bots_getPreviewInfo | Api.bots_getPreviewMedias | Api.bots_updateUserEmojiStatus | Api.bots_toggleUserEmojiStatusPermission | Api.bots_checkDownloadFileParams | Api.bots_getAdminedBots | Api.bots_updateStarRefProgram | Api.bots_setCustomVerification | Api.bots_getBotRecommendations | Api.bots_checkUsername | Api.bots_createBot | Api.bots_exportBotToken | Api.bots_requestWebViewButton | Api.bots_getRequestedWebViewButton | Api.bots_getAccessSettings | Api.bots_editAccessSettings | Api.bots_setJoinChatResults | Api.payments_getPaymentForm | Api.payments_getPaymentReceipt | Api.payments_validateRequestedInfo | Api.payments_sendPaymentForm | Api.payments_getSavedInfo | Api.payments_clearSavedInfo | Api.payments_getBankCardData | Api.payments_exportInvoice | Api.payments_assignAppStoreTransaction | Api.payments_assignPlayMarketTransaction | Api.payments_getPremiumGiftCodeOptions | Api.payments_checkGiftCode | Api.payments_applyGiftCode | Api.payments_getGiveawayInfo | Api.payments_launchPrepaidGiveaway | Api.payments_getStarsTopupOptions | Api.payments_getStarsStatus | Api.payments_getStarsTransactions | Api.payments_sendStarsForm | Api.payments_refundStarsCharge | Api.payments_getStarsRevenueStats | Api.payments_getStarsRevenueWithdrawalUrl | Api.payments_getStarsRevenueAdsAccountUrl | Api.payments_getStarsTransactionsByID | Api.payments_getStarsGiftOptions | Api.payments_getStarsSubscriptions | Api.payments_changeStarsSubscription | Api.payments_fulfillStarsSubscription | Api.payments_getStarsGiveawayOptions | Api.payments_getStarGifts | Api.payments_saveStarGift | Api.payments_convertStarGift | Api.payments_botCancelStarsSubscription | Api.payments_getConnectedStarRefBots | Api.payments_getConnectedStarRefBot | Api.payments_getSuggestedStarRefBots | Api.payments_connectStarRefBot | Api.payments_editConnectedStarRefBot | Api.payments_getStarGiftUpgradePreview | Api.payments_upgradeStarGift | Api.payments_transferStarGift | Api.payments_getUniqueStarGift | Api.payments_getSavedStarGifts | Api.payments_getSavedStarGift | Api.payments_getStarGiftWithdrawalUrl | Api.payments_toggleChatStarGiftNotifications | Api.payments_toggleStarGiftsPinnedToTop | Api.payments_canPurchaseStore | Api.payments_getResaleStarGifts | Api.payments_updateStarGiftPrice | Api.payments_createStarGiftCollection | Api.payments_updateStarGiftCollection | Api.payments_reorderStarGiftCollections | Api.payments_deleteStarGiftCollection | Api.payments_getStarGiftCollections | Api.payments_getUniqueStarGiftValueInfo | Api.payments_checkCanSendGift | Api.payments_getStarGiftAuctionState | Api.payments_getStarGiftAuctionAcquiredGifts | Api.payments_getStarGiftActiveAuctions | Api.payments_resolveStarGiftOffer | Api.payments_sendStarGiftOffer | Api.payments_getStarGiftUpgradeAttributes | Api.payments_getCraftStarGifts | Api.payments_craftStarGift | Api.stickers_createStickerSet | Api.stickers_removeStickerFromSet | Api.stickers_changeStickerPosition | Api.stickers_addStickerToSet | Api.stickers_setStickerSetThumb | Api.stickers_checkShortName | Api.stickers_suggestShortName | Api.stickers_changeSticker | Api.stickers_renameStickerSet | Api.stickers_deleteStickerSet | Api.stickers_replaceSticker | Api.phone_getCallConfig | Api.phone_requestCall | Api.phone_acceptCall | Api.phone_confirmCall | Api.phone_receivedCall | Api.phone_discardCall | Api.phone_setCallRating | Api.phone_saveCallDebug | Api.phone_sendSignalingData | Api.phone_createGroupCall | Api.phone_joinGroupCall | Api.phone_leaveGroupCall | Api.phone_inviteToGroupCall | Api.phone_discardGroupCall | Api.phone_toggleGroupCallSettings | Api.phone_getGroupCall | Api.phone_getGroupParticipants | Api.phone_checkGroupCall | Api.phone_toggleGroupCallRecord | Api.phone_editGroupCallParticipant | Api.phone_editGroupCallTitle | Api.phone_getGroupCallJoinAs | Api.phone_exportGroupCallInvite | Api.phone_toggleGroupCallStartSubscription | Api.phone_startScheduledGroupCall | Api.phone_saveDefaultGroupCallJoinAs | Api.phone_joinGroupCallPresentation | Api.phone_leaveGroupCallPresentation | Api.phone_getGroupCallStreamChannels | Api.phone_getGroupCallStreamRtmpUrl | Api.phone_saveCallLog | Api.phone_createConferenceCall | Api.phone_deleteConferenceCallParticipants | Api.phone_sendConferenceCallBroadcast | Api.phone_inviteConferenceCallParticipant | Api.phone_declineConferenceCallInvite | Api.phone_getGroupCallChainBlocks | Api.phone_sendGroupCallMessage | Api.phone_sendGroupCallEncryptedMessage | Api.phone_deleteGroupCallMessages | Api.phone_deleteGroupCallParticipantMessages | Api.phone_getGroupCallStars | Api.phone_saveDefaultSendAs | Api.langpack_getLangPack | Api.langpack_getStrings | Api.langpack_getDifference | Api.langpack_getLanguages | Api.langpack_getLanguage | Api.folders_editPeerFolders | Api.stats_getBroadcastStats | Api.stats_loadAsyncGraph | Api.stats_getMegagroupStats | Api.stats_getMessagePublicForwards | Api.stats_getMessageStats | Api.stats_getStoryStats | Api.stats_getStoryPublicForwards | Api.stats_getPollStats | Api.chatlists_exportChatlistInvite | Api.chatlists_deleteExportedInvite | Api.chatlists_editExportedInvite | Api.chatlists_getExportedInvites | Api.chatlists_checkChatlistInvite | Api.chatlists_joinChatlistInvite | Api.chatlists_getChatlistUpdates | Api.chatlists_joinChatlistUpdates | Api.chatlists_hideChatlistUpdates | Api.chatlists_getLeaveChatlistSuggestions | Api.chatlists_leaveChatlist | Api.stories_canSendStory | Api.stories_sendStory | Api.stories_editStory | Api.stories_deleteStories | Api.stories_togglePinned | Api.stories_getAllStories | Api.stories_getPinnedStories | Api.stories_getStoriesArchive | Api.stories_getStoriesByID | Api.stories_toggleAllStoriesHidden | Api.stories_readStories | Api.stories_incrementStoryViews | Api.stories_getStoryViewsList | Api.stories_getStoriesViews | Api.stories_exportStoryLink | Api.stories_report | Api.stories_activateStealthMode | Api.stories_sendReaction | Api.stories_getPeerStories | Api.stories_getAllReadPeerStories | Api.stories_getPeerMaxIDs | Api.stories_getChatsToSend | Api.stories_togglePeerStoriesHidden | Api.stories_getStoryReactionsList | Api.stories_togglePinnedToTop | Api.stories_searchPosts | Api.stories_createAlbum | Api.stories_updateAlbum | Api.stories_reorderAlbums | Api.stories_deleteAlbum | Api.stories_getAlbums | Api.stories_getAlbumStories | Api.stories_startLive | Api.premium_getBoostsList | Api.premium_getMyBoosts | Api.premium_applyBoost | Api.premium_getBoostsStatus | Api.premium_getUserBoosts | Api.smsjobs_isEligibleToJoin | Api.smsjobs_join | Api.smsjobs_leave | Api.smsjobs_updateSettings | Api.smsjobs_getStatus | Api.smsjobs_getSmsJob | Api.smsjobs_finishJob | Api.fragment_getCollectibleInfo | Api.aicompose_createTone | Api.aicompose_updateTone | Api.aicompose_saveTone | Api.aicompose_deleteTone | Api.aicompose_getTone | Api.aicompose_getTones | Api.aicompose_getToneExample | Api.invokeAfterMsg<Api.Function> | Api.invokeAfterMsgs<Api.Function> | Api.initConnection<Api.Function> | Api.invokeWithLayer<Api.Function> | Api.invokeWithoutUpdates<Api.Function> | Api.invokeWithMessagesRange<Api.Function> | Api.invokeWithTakeout<Api.Function> | Api.invokeWithBusinessConnection<Api.Function> | Api.invokeWithGooglePlayIntegrity<Api.Function> | Api.invokeWithApnsSecret<Api.Function> | Api.invokeWithReCaptcha<Api.Function>;
33
33
  export declare function canBeInputUser(inputPeer: Api.InputPeer): inputPeer is Api.inputPeerSelf | Api.inputPeerUser | Api.inputPeerUserFromMessage;
34
34
  export declare function toInputUser(inputPeer: Api.InputPeer): Api.inputUserSelf | Api.inputUser | Api.inputUserFromMessage;
35
35
  export declare function canBeInputChannel(inputPeer: Api.InputPeer): inputPeer is Api.inputPeerChannel | Api.inputPeerChannelFromMessage;
@@ -1 +1 @@
1
- {"version":3,"file":"0_utilities.d.ts","sourceRoot":"","sources":["../../src/client/0_utilities.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAIH,OAAO,EAAE,GAAG,EAAiB,MAAM,YAAY,CAAC;AAEhD,MAAM,MAAM,YAAY,CAAC,CAAC,GAAG,IAAI,IAAI,MAAM,OAAO,CAAC,CAAC,CAAC,CAAC;AAEtD,eAAO,MAAM,OAAO,qBAA0B,CAAC;AAE/C,wBAAgB,SAAS,CAAC,MAAM,EAAE,MAAM,WAMvC;AAsCD,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,UAyBzC;AAED,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,SAS7C;AAED,wBAAgB,cAAc,CAAC,SAAS,EAAE,MAAM,UAK/C;AAED,wBAAgB,YAAY,CAAC,OAAO,EAAE,MAAM,UAK3C;AAED,wBAAgB,eAAe,CAAC,MAAM,EAAE,MAAM,QAI7C;AAED,wBAAgB,UAAU,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,KAAK,EAAE,CAAC,KAAK,EAAE,CAAC,KAAK,IAAI,QAIlE;AAED,wBAAgB,oBAAoB,CAAC,EAAE,EAAE,MAAM,QAI9C;AAED,wBAAgB,kBAAkB,CAAC,EAAE,EAAE,MAAM,QAI5C;AAYD,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,8iyBAE3C;AAED,wBAAgB,cAAc,CAAC,SAAS,EAAE,GAAG,CAAC,SAAS,qFAEtD;AACD,wBAAgB,WAAW,CAAC,SAAS,EAAE,GAAG,CAAC,SAAS,gEAYnD;AAED,wBAAgB,iBAAiB,CAAC,SAAS,EAAE,GAAG,CAAC,SAAS,uEAEzD;AACD,wBAAgB,cAAc,CAAC,SAAS,EAAE,GAAG,CAAC,SAAS,kDAUtD;AAED,wBAAgB,IAAI,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,GAAG,IAAI,CAMlD;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,UAUjD;AAED,eAAO,MAAM,6BAA6B,IAAI,CAAC;AAE/C,eAAO,MAAM,kBAAkB,IAAI,CAAC;AACpC,eAAO,MAAM,+BAA+B,IAAI,CAAC;AAEjD,wBAAgB,cAAc,CAAC,MAAM,CAAC,EAAE;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAE,IACnD,MAAM,MAAM,EAAE,YAAY,UAAU,YAU7C;AAED,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,UAAU,0CAQrD"}
1
+ {"version":3,"file":"0_utilities.d.ts","sourceRoot":"","sources":["../../src/client/0_utilities.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAIH,OAAO,EAAE,GAAG,EAAiB,MAAM,YAAY,CAAC;AAEhD,MAAM,MAAM,YAAY,CAAC,CAAC,GAAG,IAAI,IAAI,MAAM,OAAO,CAAC,CAAC,CAAC,CAAC;AAEtD,eAAO,MAAM,OAAO,qBAA0B,CAAC;AAE/C,wBAAgB,SAAS,CAAC,MAAM,EAAE,MAAM,WAMvC;AAsCD,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,UAyBzC;AAED,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,SAS7C;AAED,wBAAgB,cAAc,CAAC,SAAS,EAAE,MAAM,UAK/C;AAED,wBAAgB,YAAY,CAAC,OAAO,EAAE,MAAM,UAK3C;AAED,wBAAgB,eAAe,CAAC,MAAM,EAAE,MAAM,QAI7C;AAED,wBAAgB,UAAU,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,KAAK,EAAE,CAAC,KAAK,EAAE,CAAC,KAAK,IAAI,QAIlE;AAED,wBAAgB,oBAAoB,CAAC,EAAE,EAAE,MAAM,QAI9C;AAED,wBAAgB,kBAAkB,CAAC,EAAE,EAAE,MAAM,QAI5C;AAYD,wBAAgB,eAAe,CAAC,KAAK,EAAE,OAAO,8iyBAE7C;AAED,wBAAgB,cAAc,CAAC,SAAS,EAAE,GAAG,CAAC,SAAS,qFAEtD;AACD,wBAAgB,WAAW,CAAC,SAAS,EAAE,GAAG,CAAC,SAAS,gEAYnD;AAED,wBAAgB,iBAAiB,CAAC,SAAS,EAAE,GAAG,CAAC,SAAS,uEAEzD;AACD,wBAAgB,cAAc,CAAC,SAAS,EAAE,GAAG,CAAC,SAAS,kDAUtD;AAED,wBAAgB,IAAI,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,GAAG,IAAI,CAMlD;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,UAUjD;AAED,eAAO,MAAM,6BAA6B,IAAI,CAAC;AAE/C,eAAO,MAAM,kBAAkB,IAAI,CAAC;AACpC,eAAO,MAAM,+BAA+B,IAAI,CAAC;AAEjD,wBAAgB,cAAc,CAAC,MAAM,CAAC,EAAE;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAE,IACnD,MAAM,MAAM,EAAE,YAAY,UAAU,YAU7C;AAED,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,UAAU,0CAQrD"}