@mtcute/core 0.27.0 → 0.27.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/client.cjs +12 -0
- package/client.js +13 -1
- package/highlevel/client.d.cts +131 -90
- package/highlevel/client.d.ts +131 -90
- package/highlevel/client.test.d.cts +1 -0
- package/highlevel/client.test.d.ts +1 -0
- package/highlevel/methods/auth/start.d.cts +3 -3
- package/highlevel/methods/auth/start.d.ts +3 -3
- package/highlevel/methods/contacts/set-contact-note.cjs +21 -0
- package/highlevel/methods/contacts/set-contact-note.js +16 -0
- package/highlevel/methods/files/download-chunk.cjs +63 -0
- package/highlevel/methods/files/download-chunk.d.cts +29 -0
- package/highlevel/methods/files/download-chunk.d.ts +29 -0
- package/highlevel/methods/files/download-chunk.js +58 -0
- package/highlevel/methods/files/download-chunk.test.d.cts +1 -0
- package/highlevel/methods/files/download-chunk.test.d.ts +1 -0
- package/highlevel/methods/files/download-iterable.cjs +40 -23
- package/highlevel/methods/files/download-iterable.d.cts +6 -0
- package/highlevel/methods/files/download-iterable.d.ts +6 -0
- package/highlevel/methods/files/download-iterable.js +34 -17
- package/highlevel/methods/forums/reorder-pinned-forum-topics.cjs +2 -2
- package/highlevel/methods/forums/reorder-pinned-forum-topics.js +3 -3
- package/highlevel/methods/forums/toggle-forum-topic-closed.cjs +2 -2
- package/highlevel/methods/forums/toggle-forum-topic-closed.js +3 -3
- package/highlevel/methods/forums/toggle-forum-topic-pinned.cjs +2 -2
- package/highlevel/methods/forums/toggle-forum-topic-pinned.js +3 -3
- package/highlevel/methods.d.cts +3 -0
- package/highlevel/methods.d.ts +3 -0
- package/highlevel/types/premium/star-gift.cjs +5 -1
- package/highlevel/types/premium/star-gift.d.cts +3 -1
- package/highlevel/types/premium/star-gift.d.ts +3 -1
- package/highlevel/types/premium/star-gift.js +5 -1
- package/methods.cjs +5 -0
- package/methods.js +6 -1
- package/network/network-manager.cjs +1 -1
- package/network/network-manager.js +1 -1
- package/package.json +2 -2
- package/utils/binary/compat.cjs +29 -0
- package/utils/binary/compat.js +29 -0
package/highlevel/client.d.ts
CHANGED
|
@@ -169,7 +169,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
169
169
|
* When you log out, you can immediately log back in using
|
|
170
170
|
* the same {@link TelegramClient} instance.
|
|
171
171
|
*
|
|
172
|
-
* **Available**:
|
|
172
|
+
* **Available**: 👤 users only
|
|
173
173
|
*
|
|
174
174
|
* @returns On success, `true` is returned
|
|
175
175
|
*/
|
|
@@ -231,7 +231,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
231
231
|
/**
|
|
232
232
|
* Authorize a bot using its token issued by [@BotFather](//t.me/BotFather)
|
|
233
233
|
*
|
|
234
|
-
* **Available**:
|
|
234
|
+
* **Available**: 👤 users only
|
|
235
235
|
*
|
|
236
236
|
* @param token Bot token issued by BotFather
|
|
237
237
|
* @returns Bot's {@link User} object
|
|
@@ -297,7 +297,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
297
297
|
* > **Note**: Using this method assumes that you
|
|
298
298
|
* > are using a test DC in `primaryDc` parameter.
|
|
299
299
|
*
|
|
300
|
-
* **Available**:
|
|
300
|
+
* **Available**: 👤 users only
|
|
301
301
|
*
|
|
302
302
|
* @param params Additional parameters
|
|
303
303
|
*/
|
|
@@ -328,9 +328,9 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
328
328
|
* All parameters are `MaybeDynamic<T>`, meaning you
|
|
329
329
|
* can either supply `T`, or a function that returns `MaybePromise<T>`
|
|
330
330
|
*
|
|
331
|
-
* This method is intended for
|
|
332
|
-
*
|
|
333
|
-
*
|
|
331
|
+
* This method is intended for *interactive* login.
|
|
332
|
+
* If you are building some kind of headless service, you will most likely
|
|
333
|
+
* want to use the underlying authorization methods directly.
|
|
334
334
|
* **Available**: ✅ both users and bots
|
|
335
335
|
*
|
|
336
336
|
*/
|
|
@@ -412,7 +412,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
412
412
|
/**
|
|
413
413
|
* Send an answer to a callback query.
|
|
414
414
|
*
|
|
415
|
-
* **Available**:
|
|
415
|
+
* **Available**: 👤 users only
|
|
416
416
|
*
|
|
417
417
|
* @param queryId ID of the callback query, or the query itself
|
|
418
418
|
* @param params Parameters of the answer
|
|
@@ -452,7 +452,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
452
452
|
/**
|
|
453
453
|
* Answer an inline query.
|
|
454
454
|
*
|
|
455
|
-
* **Available**:
|
|
455
|
+
* **Available**: 👤 users only
|
|
456
456
|
*
|
|
457
457
|
* @param queryId Inline query ID
|
|
458
458
|
* @param results Results of the query
|
|
@@ -538,7 +538,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
538
538
|
/**
|
|
539
539
|
* Answer a pre-checkout query.
|
|
540
540
|
*
|
|
541
|
-
* **Available**:
|
|
541
|
+
* **Available**: 👤 users only
|
|
542
542
|
*
|
|
543
543
|
* @param queryId Pre-checkout query ID
|
|
544
544
|
*/
|
|
@@ -552,7 +552,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
552
552
|
* Does the same as passing `null` to {@link setMyCommands}
|
|
553
553
|
*
|
|
554
554
|
* Learn more about scopes in the [Bot API docs](https://core.telegram.org/bots/api#botcommandscope)
|
|
555
|
-
* **Available**:
|
|
555
|
+
* **Available**: 👤 users only
|
|
556
556
|
*
|
|
557
557
|
*/
|
|
558
558
|
deleteMyCommands(params?: {
|
|
@@ -569,7 +569,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
569
569
|
}): Promise<void>;
|
|
570
570
|
/**
|
|
571
571
|
* Gets information about a bot the current uzer owns (or the current bot)
|
|
572
|
-
* **Available**:
|
|
572
|
+
* **Available**: 👤 users only
|
|
573
573
|
*
|
|
574
574
|
*/
|
|
575
575
|
getBotInfo(params: {
|
|
@@ -586,7 +586,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
586
586
|
}): Promise<tl.bots.RawBotInfo>;
|
|
587
587
|
/**
|
|
588
588
|
* Fetches the menu button set for the given user.
|
|
589
|
-
* **Available**:
|
|
589
|
+
* **Available**: 👤 users only
|
|
590
590
|
*
|
|
591
591
|
*/
|
|
592
592
|
getBotMenuButton(user: InputPeerLike): Promise<tl.TypeBotMenuButton>;
|
|
@@ -632,7 +632,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
632
632
|
}): Promise<tl.messages.TypeBotCallbackAnswer>;
|
|
633
633
|
/**
|
|
634
634
|
* Get high scores of a game
|
|
635
|
-
* **Available**:
|
|
635
|
+
* **Available**: 👤 users only
|
|
636
636
|
*
|
|
637
637
|
*/
|
|
638
638
|
getGameHighScores(params: InputMessageId & {
|
|
@@ -642,7 +642,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
642
642
|
/**
|
|
643
643
|
* Get high scores of a game from an inline message
|
|
644
644
|
*
|
|
645
|
-
* **Available**:
|
|
645
|
+
* **Available**: 👤 users only
|
|
646
646
|
*
|
|
647
647
|
* @param messageId ID of the inline message containing the game
|
|
648
648
|
* @param userId ID of the user to find high scores for
|
|
@@ -653,7 +653,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
653
653
|
* and user language. If they are not set, empty set is returned.
|
|
654
654
|
*
|
|
655
655
|
* Learn more about scopes in the [Bot API docs](https://core.telegram.org/bots/api#botcommandscope)
|
|
656
|
-
* **Available**:
|
|
656
|
+
* **Available**: 👤 users only
|
|
657
657
|
*
|
|
658
658
|
*/
|
|
659
659
|
getMyCommands(params?: {
|
|
@@ -744,7 +744,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
744
744
|
/**
|
|
745
745
|
* Prepare an inline message result to be sent later via the
|
|
746
746
|
* `shareMessage` [mini-app api method](https://core.telegram.org/bots/webapps#initializing-mini-apps).
|
|
747
|
-
* **Available**:
|
|
747
|
+
* **Available**: 👤 users only
|
|
748
748
|
*
|
|
749
749
|
*/
|
|
750
750
|
prepareInlineMessage(params: {
|
|
@@ -773,7 +773,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
773
773
|
}): Promise<tl.messages.TypeBotPreparedInlineMessage>;
|
|
774
774
|
/**
|
|
775
775
|
* Sets information about a bot the current uzer owns (or the current bot)
|
|
776
|
-
* **Available**:
|
|
776
|
+
* **Available**: 👤 users only
|
|
777
777
|
*
|
|
778
778
|
*/
|
|
779
779
|
setBotInfo(params: {
|
|
@@ -796,14 +796,14 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
796
796
|
}): Promise<void>;
|
|
797
797
|
/**
|
|
798
798
|
* Sets a menu button for the given user.
|
|
799
|
-
* **Available**:
|
|
799
|
+
* **Available**: 👤 users only
|
|
800
800
|
*
|
|
801
801
|
*/
|
|
802
802
|
setBotMenuButton(user: InputPeerLike, button: tl.TypeBotMenuButton): Promise<void>;
|
|
803
803
|
/**
|
|
804
804
|
* Set a score of a user in a game
|
|
805
805
|
*
|
|
806
|
-
* **Available**:
|
|
806
|
+
* **Available**: 👤 users only
|
|
807
807
|
*
|
|
808
808
|
* @param params
|
|
809
809
|
* @returns The modified message
|
|
@@ -833,7 +833,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
833
833
|
* Set a score of a user in a game contained in
|
|
834
834
|
* an inline message
|
|
835
835
|
*
|
|
836
|
-
* **Available**:
|
|
836
|
+
* **Available**: 👤 users only
|
|
837
837
|
*
|
|
838
838
|
* @param params
|
|
839
839
|
*/
|
|
@@ -859,7 +859,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
859
859
|
* Set or delete commands for the current bot and the given scope
|
|
860
860
|
*
|
|
861
861
|
* Learn more about scopes in the [Bot API docs](https://core.telegram.org/bots/api#botcommandscope)
|
|
862
|
-
* **Available**:
|
|
862
|
+
* **Available**: 👤 users only
|
|
863
863
|
*
|
|
864
864
|
*/
|
|
865
865
|
setMyCommands(params: {
|
|
@@ -882,7 +882,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
882
882
|
}): Promise<void>;
|
|
883
883
|
/**
|
|
884
884
|
* Sets the default chat permissions for the bot in the supergroup or channel.
|
|
885
|
-
* **Available**:
|
|
885
|
+
* **Available**: 👤 users only
|
|
886
886
|
*
|
|
887
887
|
*/
|
|
888
888
|
setMyDefaultRights(params: {
|
|
@@ -936,7 +936,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
936
936
|
* When banning a channel, the user won't be able to use
|
|
937
937
|
* any of their channels to post until the ban is lifted.
|
|
938
938
|
*
|
|
939
|
-
* **Available**:
|
|
939
|
+
* **Available**: 👤 users only
|
|
940
940
|
*
|
|
941
941
|
* @returns Service message about removed user, if one was generated.
|
|
942
942
|
*/
|
|
@@ -1042,7 +1042,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1042
1042
|
*
|
|
1043
1043
|
* You must be an administrator and have the appropriate permissions.
|
|
1044
1044
|
*
|
|
1045
|
-
* **Available**:
|
|
1045
|
+
* **Available**: 👤 users only
|
|
1046
1046
|
*
|
|
1047
1047
|
* @param chatId Chat ID or username
|
|
1048
1048
|
*/
|
|
@@ -1095,7 +1095,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1095
1095
|
}): Promise<void>;
|
|
1096
1096
|
/**
|
|
1097
1097
|
* Edit supergroup/channel admin rights of a user.
|
|
1098
|
-
* **Available**:
|
|
1098
|
+
* **Available**: 👤 users only
|
|
1099
1099
|
*
|
|
1100
1100
|
*/
|
|
1101
1101
|
editAdminRights(params: {
|
|
@@ -1170,7 +1170,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1170
1170
|
/**
|
|
1171
1171
|
* Get information about a single chat member
|
|
1172
1172
|
*
|
|
1173
|
-
* **Available**:
|
|
1173
|
+
* **Available**: 👤 users only
|
|
1174
1174
|
*
|
|
1175
1175
|
* @param chatId Chat ID or username
|
|
1176
1176
|
* @param userId User ID, username, phone number, `"me"` or `"self"`
|
|
@@ -1187,7 +1187,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1187
1187
|
*
|
|
1188
1188
|
* You can retrieve up to 200 members at once
|
|
1189
1189
|
*
|
|
1190
|
-
* **Available**:
|
|
1190
|
+
* **Available**: 👤 users only
|
|
1191
1191
|
*
|
|
1192
1192
|
* @param chatId Chat ID or username
|
|
1193
1193
|
* @param params Additional parameters
|
|
@@ -1385,7 +1385,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1385
1385
|
/**
|
|
1386
1386
|
* Leave a group chat, supergroup or channel
|
|
1387
1387
|
*
|
|
1388
|
-
* **Available**:
|
|
1388
|
+
* **Available**: 👤 users only
|
|
1389
1389
|
*
|
|
1390
1390
|
* @param chatId Chat ID or username
|
|
1391
1391
|
*/
|
|
@@ -1441,7 +1441,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1441
1441
|
reorderUsernames(peerId: InputPeerLike, order: string[]): Promise<void>;
|
|
1442
1442
|
/**
|
|
1443
1443
|
* Restrict a user in a supergroup.
|
|
1444
|
-
* **Available**:
|
|
1444
|
+
* **Available**: 👤 users only
|
|
1445
1445
|
*
|
|
1446
1446
|
*/
|
|
1447
1447
|
restrictChatMember(params: {
|
|
@@ -1507,8 +1507,6 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1507
1507
|
/**
|
|
1508
1508
|
* Whether to set this color for the profile
|
|
1509
1509
|
* header instead of chat name/replies.
|
|
1510
|
-
*
|
|
1511
|
-
* Currently only available for the current user.
|
|
1512
1510
|
*/
|
|
1513
1511
|
forProfile?: boolean;
|
|
1514
1512
|
}): Promise<void>;
|
|
@@ -1517,7 +1515,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1517
1515
|
*
|
|
1518
1516
|
* You must be an administrator in the chat and have appropriate permissions.
|
|
1519
1517
|
*
|
|
1520
|
-
* **Available**:
|
|
1518
|
+
* **Available**: 👤 users only
|
|
1521
1519
|
*
|
|
1522
1520
|
* @param chatId Chat ID or username
|
|
1523
1521
|
* @param restrictions
|
|
@@ -1532,7 +1530,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1532
1530
|
*
|
|
1533
1531
|
* You must be an administrator and have the appropriate permissions.
|
|
1534
1532
|
*
|
|
1535
|
-
* **Available**:
|
|
1533
|
+
* **Available**: 👤 users only
|
|
1536
1534
|
*
|
|
1537
1535
|
* @param chatId Chat ID or username
|
|
1538
1536
|
* @param description New chat description, 0-255 characters
|
|
@@ -1542,7 +1540,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1542
1540
|
* Set a new chat photo or video.
|
|
1543
1541
|
*
|
|
1544
1542
|
* You must be an administrator and have the appropriate permissions.
|
|
1545
|
-
* **Available**:
|
|
1543
|
+
* **Available**: 👤 users only
|
|
1546
1544
|
*
|
|
1547
1545
|
*/
|
|
1548
1546
|
setChatPhoto(params: {
|
|
@@ -1563,7 +1561,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1563
1561
|
*
|
|
1564
1562
|
* You must be an administrator and have the appropriate permissions.
|
|
1565
1563
|
*
|
|
1566
|
-
* **Available**:
|
|
1564
|
+
* **Available**: 👤 users only
|
|
1567
1565
|
*
|
|
1568
1566
|
* @param chatId Chat ID or username
|
|
1569
1567
|
* @param title New chat title, 1-255 characters
|
|
@@ -1669,7 +1667,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1669
1667
|
* just allows the user to join the chat again, if they want.
|
|
1670
1668
|
*
|
|
1671
1669
|
* This method acts as a no-op in case a legacy group is passed.
|
|
1672
|
-
* **Available**:
|
|
1670
|
+
* **Available**: 👤 users only
|
|
1673
1671
|
*
|
|
1674
1672
|
*/
|
|
1675
1673
|
unbanChatMember(params: {
|
|
@@ -1685,7 +1683,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1685
1683
|
* just allows the user to join the chat again, if they want.
|
|
1686
1684
|
*
|
|
1687
1685
|
* This method acts as a no-op in case a legacy group is passed.
|
|
1688
|
-
* **Available**:
|
|
1686
|
+
* **Available**: 👤 users only
|
|
1689
1687
|
*
|
|
1690
1688
|
*/
|
|
1691
1689
|
unrestrictChatMember(params: {
|
|
@@ -1721,6 +1719,10 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1721
1719
|
* @default false
|
|
1722
1720
|
*/
|
|
1723
1721
|
sharePhone?: boolean;
|
|
1722
|
+
/**
|
|
1723
|
+
* Note to the contact
|
|
1724
|
+
*/
|
|
1725
|
+
note?: InputText;
|
|
1724
1726
|
}): Promise<User>;
|
|
1725
1727
|
/**
|
|
1726
1728
|
* Delete one or more contacts from your Telegram contacts list
|
|
@@ -1747,6 +1749,13 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1747
1749
|
* @param contacts List of contacts
|
|
1748
1750
|
*/
|
|
1749
1751
|
importContacts(contacts: PartialOnly<Omit<tl.RawInputPhoneContact, '_'>, 'clientId'>[]): Promise<tl.contacts.RawImportedContacts>;
|
|
1752
|
+
/**
|
|
1753
|
+
* Set a note for a contact
|
|
1754
|
+
*
|
|
1755
|
+
* @param userId ID of the user to set the note for
|
|
1756
|
+
* @param note Note text
|
|
1757
|
+
*/
|
|
1758
|
+
setContactNote(userId: InputPeerLike, note: InputText): Promise<void>;
|
|
1750
1759
|
/**
|
|
1751
1760
|
* Create a folder from given parameters
|
|
1752
1761
|
*
|
|
@@ -1971,6 +1980,35 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1971
1980
|
* @param params File download parameters
|
|
1972
1981
|
*/
|
|
1973
1982
|
downloadAsBuffer(location: FileDownloadLocation, params?: FileDownloadParameters): Promise<Uint8Array>;
|
|
1983
|
+
/**
|
|
1984
|
+
* Download a single chunk of a file, using [`precise`](https://core.telegram.org/api/files#downloading-files) download mode
|
|
1985
|
+
*
|
|
1986
|
+
* **Available**: 👤 users only
|
|
1987
|
+
*
|
|
1988
|
+
* @param params Download parameters
|
|
1989
|
+
*/
|
|
1990
|
+
downloadChunk(params: {
|
|
1991
|
+
/** File from which to download a chunk */
|
|
1992
|
+
location: FileDownloadLocation;
|
|
1993
|
+
/**
|
|
1994
|
+
* DC id from which the file will be downloaded.
|
|
1995
|
+
*
|
|
1996
|
+
* If provided DC is not the one storing the file,
|
|
1997
|
+
* redirection will be handled automatically.
|
|
1998
|
+
*/
|
|
1999
|
+
dcId?: number;
|
|
2000
|
+
/** Offset of the chunk in bytes */
|
|
2001
|
+
offset: number;
|
|
2002
|
+
/**
|
|
2003
|
+
* Number of bytes to download (starting from the offset)
|
|
2004
|
+
*
|
|
2005
|
+
* Max 1MB (1048576)
|
|
2006
|
+
*/
|
|
2007
|
+
limit: number;
|
|
2008
|
+
maxRetryCount?: number;
|
|
2009
|
+
floodSleepThreshold?: number;
|
|
2010
|
+
abortSignal?: AbortSignal;
|
|
2011
|
+
}): Promise<Uint8Array>;
|
|
1974
2012
|
/**
|
|
1975
2013
|
* Download a remote file to a local file (only for Node.js).
|
|
1976
2014
|
* Promise will resolve once the download is complete.
|
|
@@ -1981,6 +2019,11 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
1981
2019
|
* @param params File download parameters
|
|
1982
2020
|
*/
|
|
1983
2021
|
downloadToFile(filename: string, location: FileDownloadLocation, params?: FileDownloadParameters): Promise<void>;
|
|
2022
|
+
_normalizeFileDownloadLocation(input: FileDownloadLocation): Promise<{
|
|
2023
|
+
location: tl.TypeInputFileLocation | tl.TypeInputWebFileLocation | Uint8Array<ArrayBufferLike>;
|
|
2024
|
+
dcId?: number;
|
|
2025
|
+
fileSize?: number;
|
|
2026
|
+
}>;
|
|
1984
2027
|
/**
|
|
1985
2028
|
* Download a file and return it as an iterable, which yields file contents
|
|
1986
2029
|
* in chunks of a given size. Order of the chunks is guaranteed to be
|
|
@@ -2024,7 +2067,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2024
2067
|
/**
|
|
2025
2068
|
* Normalize an {@link InputMediaLike} to `InputMedia`,
|
|
2026
2069
|
* uploading the file if needed.
|
|
2027
|
-
* **Available**:
|
|
2070
|
+
* **Available**: 👤 users only
|
|
2028
2071
|
*
|
|
2029
2072
|
*/
|
|
2030
2073
|
_normalizeInputMedia(media: InputMediaLike, params?: {
|
|
@@ -2114,7 +2157,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2114
2157
|
* the returned object will act like a message media
|
|
2115
2158
|
* and contain fields like File ID.
|
|
2116
2159
|
*
|
|
2117
|
-
* **Available**:
|
|
2160
|
+
* **Available**: 👤 users only
|
|
2118
2161
|
*
|
|
2119
2162
|
* @param media Media to upload
|
|
2120
2163
|
* @param [params={}] Upload parameters
|
|
@@ -2128,8 +2171,6 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2128
2171
|
*
|
|
2129
2172
|
* Only admins with `manageTopics` permission can do this.
|
|
2130
2173
|
*
|
|
2131
|
-
* **Available**: ✅ both users and bots
|
|
2132
|
-
*
|
|
2133
2174
|
* @returns Service message for the created topic
|
|
2134
2175
|
*/
|
|
2135
2176
|
createForumTopic(params: {
|
|
@@ -2161,8 +2202,6 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2161
2202
|
/**
|
|
2162
2203
|
* Delete a forum topic and all its history
|
|
2163
2204
|
*
|
|
2164
|
-
* **Available**: ✅ both users and bots
|
|
2165
|
-
*
|
|
2166
2205
|
* @param chat Chat or user ID, username, phone number, `"me"` or `"self"`
|
|
2167
2206
|
* @param topicId ID of the topic (i.e. its top message ID)
|
|
2168
2207
|
*/
|
|
@@ -2178,8 +2217,6 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2178
2217
|
*
|
|
2179
2218
|
* Only admins with `manageTopics` permission can do this.
|
|
2180
2219
|
*
|
|
2181
|
-
* **Available**: ✅ both users and bots
|
|
2182
|
-
*
|
|
2183
2220
|
* @param chatId Chat ID or username
|
|
2184
2221
|
* @param topicId ID of the topic (i.e. its top message ID)
|
|
2185
2222
|
* @returns Service message about the modification
|
|
@@ -2205,20 +2242,20 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2205
2242
|
* to the client's update handler.
|
|
2206
2243
|
*/
|
|
2207
2244
|
shouldDispatch?: true;
|
|
2245
|
+
/** Whether to (un)close the topic */
|
|
2246
|
+
closed?: boolean;
|
|
2247
|
+
/** Whether to (un)hide the topic */
|
|
2248
|
+
hidden?: boolean;
|
|
2208
2249
|
}): Promise<Message>;
|
|
2209
2250
|
/**
|
|
2210
2251
|
* Get forum topics by their IDs
|
|
2211
2252
|
*
|
|
2212
|
-
* **Available**: 👤 users only
|
|
2213
|
-
*
|
|
2214
2253
|
* @param chatId Chat ID or username
|
|
2215
2254
|
*/
|
|
2216
2255
|
getForumTopicsById(chatId: InputPeerLike, ids: MaybeArray<number>): Promise<ForumTopic[]>;
|
|
2217
2256
|
/**
|
|
2218
2257
|
* Get forum topics
|
|
2219
2258
|
*
|
|
2220
|
-
* **Available**: 👤 users only
|
|
2221
|
-
*
|
|
2222
2259
|
* @param chatId Chat ID or username
|
|
2223
2260
|
*/
|
|
2224
2261
|
getForumTopics(chatId: InputPeerLike, params?: {
|
|
@@ -2260,8 +2297,6 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2260
2297
|
* Reorder pinned forum topics
|
|
2261
2298
|
*
|
|
2262
2299
|
* Only admins with `manageTopics` permission can do this.
|
|
2263
|
-
* **Available**: 👤 users only
|
|
2264
|
-
*
|
|
2265
2300
|
*/
|
|
2266
2301
|
reorderPinnedForumTopics(params: {
|
|
2267
2302
|
/** Chat ID or username */
|
|
@@ -2280,8 +2315,6 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2280
2315
|
*
|
|
2281
2316
|
* Only admins with `manageTopics` permission can do this.
|
|
2282
2317
|
*
|
|
2283
|
-
* **Available**: ✅ both users and bots
|
|
2284
|
-
*
|
|
2285
2318
|
* @returns Service message about the modification
|
|
2286
2319
|
*/
|
|
2287
2320
|
toggleForumTopicClosed(parmas: {
|
|
@@ -2301,8 +2334,6 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2301
2334
|
* Toggle whether a topic in a forum is pinned
|
|
2302
2335
|
*
|
|
2303
2336
|
* Only admins with `manageTopics` permission can do this.
|
|
2304
|
-
* **Available**: 👤 users only
|
|
2305
|
-
*
|
|
2306
2337
|
*/
|
|
2307
2338
|
toggleForumTopicPinned(params: {
|
|
2308
2339
|
/** Chat ID or username */
|
|
@@ -2332,7 +2363,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2332
2363
|
*
|
|
2333
2364
|
* Only admins with `manageTopics` permission can do this.
|
|
2334
2365
|
*
|
|
2335
|
-
* **Available**:
|
|
2366
|
+
* **Available**: 👤 users only
|
|
2336
2367
|
*
|
|
2337
2368
|
* @returns Service message about the modification
|
|
2338
2369
|
*/
|
|
@@ -2352,7 +2383,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2352
2383
|
*
|
|
2353
2384
|
* You must be an administrator and have appropriate rights.
|
|
2354
2385
|
*
|
|
2355
|
-
* **Available**:
|
|
2386
|
+
* **Available**: 👤 users only
|
|
2356
2387
|
*
|
|
2357
2388
|
* @param chatId Chat ID
|
|
2358
2389
|
* @param params
|
|
@@ -2390,7 +2421,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2390
2421
|
*
|
|
2391
2422
|
* Only pass the fields that you want to modify.
|
|
2392
2423
|
*
|
|
2393
|
-
* **Available**:
|
|
2424
|
+
* **Available**: 👤 users only
|
|
2394
2425
|
*
|
|
2395
2426
|
* @param chatId Chat ID
|
|
2396
2427
|
* @param link Invite link to edit
|
|
@@ -2427,7 +2458,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2427
2458
|
* > **Note**: each administrator has their own primary invite link,
|
|
2428
2459
|
* > and bots by default don't have one.
|
|
2429
2460
|
*
|
|
2430
|
-
* **Available**:
|
|
2461
|
+
* **Available**: 👤 users only
|
|
2431
2462
|
*
|
|
2432
2463
|
* @param chatId Chat IDs
|
|
2433
2464
|
*/
|
|
@@ -2543,7 +2574,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2543
2574
|
}): Promise<void>;
|
|
2544
2575
|
/**
|
|
2545
2576
|
* Approve or decline join request to a chat.
|
|
2546
|
-
* **Available**:
|
|
2577
|
+
* **Available**: 👤 users only
|
|
2547
2578
|
*
|
|
2548
2579
|
*/
|
|
2549
2580
|
hideJoinRequest(params: {
|
|
@@ -2610,7 +2641,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2610
2641
|
* If `link` is a primary invite link, a new invite link will be
|
|
2611
2642
|
* generated automatically by Telegram
|
|
2612
2643
|
*
|
|
2613
|
-
* **Available**:
|
|
2644
|
+
* **Available**: 👤 users only
|
|
2614
2645
|
*
|
|
2615
2646
|
* @param chatId Chat ID
|
|
2616
2647
|
* @param link Invite link to revoke
|
|
@@ -2620,7 +2651,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2620
2651
|
/**
|
|
2621
2652
|
* Append item(s) to a todo list
|
|
2622
2653
|
*
|
|
2623
|
-
* **Available**:
|
|
2654
|
+
* **Available**: 👤 users only
|
|
2624
2655
|
*
|
|
2625
2656
|
* @returns Service message about the appended todo item(s), if any.
|
|
2626
2657
|
*/
|
|
@@ -2638,7 +2669,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2638
2669
|
*
|
|
2639
2670
|
* Once closed, poll can't be re-opened, and nobody
|
|
2640
2671
|
* will be able to vote in it
|
|
2641
|
-
* **Available**:
|
|
2672
|
+
* **Available**: 👤 users only
|
|
2642
2673
|
*
|
|
2643
2674
|
*/
|
|
2644
2675
|
closePoll(params: InputMessageId & {
|
|
@@ -2651,7 +2682,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2651
2682
|
/**
|
|
2652
2683
|
* Delete messages by their IDs
|
|
2653
2684
|
*
|
|
2654
|
-
* **Available**:
|
|
2685
|
+
* **Available**: 👤 users only
|
|
2655
2686
|
*
|
|
2656
2687
|
* @param chatId Chat's marked ID, its username, phone or `"me"` or `"self"`.
|
|
2657
2688
|
* @param ids Message(s) ID(s) to delete.
|
|
@@ -2677,7 +2708,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2677
2708
|
/**
|
|
2678
2709
|
* Edit sent inline message text, media and reply markup.
|
|
2679
2710
|
*
|
|
2680
|
-
* **Available**:
|
|
2711
|
+
* **Available**: 👤 users only
|
|
2681
2712
|
*
|
|
2682
2713
|
* @param messageId
|
|
2683
2714
|
* Inline message ID, either as a TL object, or as a
|
|
@@ -2783,7 +2814,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2783
2814
|
* Forward one or more messages by their IDs.
|
|
2784
2815
|
* You can forward no more than 100 messages at once.
|
|
2785
2816
|
*
|
|
2786
|
-
* **Available**:
|
|
2817
|
+
* **Available**: 👤 users only
|
|
2787
2818
|
*
|
|
2788
2819
|
* @param toChatId Destination chat ID, username, phone, `"me"` or `"self"`
|
|
2789
2820
|
* @param fromChatId Source chat ID, username, phone, `"me"` or `"self"`
|
|
@@ -2968,7 +2999,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
2968
2999
|
* For messages that were not found, `null` will be
|
|
2969
3000
|
* returned at that position.
|
|
2970
3001
|
*
|
|
2971
|
-
* **Available**:
|
|
3002
|
+
* **Available**: 👤 users only
|
|
2972
3003
|
*
|
|
2973
3004
|
* @param messageIds Messages IDs
|
|
2974
3005
|
* @param [fromReply]
|
|
@@ -3148,7 +3179,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
3148
3179
|
* For supergroups/channels, you must have appropriate permissions,
|
|
3149
3180
|
* either as an admin, or as default permissions
|
|
3150
3181
|
*
|
|
3151
|
-
* **Available**:
|
|
3182
|
+
* **Available**: 👤 users only
|
|
3152
3183
|
*
|
|
3153
3184
|
* @returns Service message about pinned message, if one was generated.
|
|
3154
3185
|
*/
|
|
@@ -3709,7 +3740,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
3709
3740
|
*
|
|
3710
3741
|
* This status is automatically renewed by mtcute until a further
|
|
3711
3742
|
* call with `cancel` is made, or a message is sent to the chat.
|
|
3712
|
-
* **Available**:
|
|
3743
|
+
* **Available**: 👤 users only
|
|
3713
3744
|
*
|
|
3714
3745
|
*/
|
|
3715
3746
|
setTyping(params: {
|
|
@@ -3737,7 +3768,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
3737
3768
|
/**
|
|
3738
3769
|
* Toggle the completion status of a todo list item(s)
|
|
3739
3770
|
*
|
|
3740
|
-
* **Available**:
|
|
3771
|
+
* **Available**: 👤 users only
|
|
3741
3772
|
*
|
|
3742
3773
|
* @returns Service message about the toggled items, if any.
|
|
3743
3774
|
*/
|
|
@@ -3775,7 +3806,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
3775
3806
|
/**
|
|
3776
3807
|
* Unpin all pinned messages in a chat.
|
|
3777
3808
|
*
|
|
3778
|
-
* **Available**:
|
|
3809
|
+
* **Available**: 👤 users only
|
|
3779
3810
|
*
|
|
3780
3811
|
* @param chatId Chat or user ID
|
|
3781
3812
|
*/
|
|
@@ -3796,7 +3827,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
3796
3827
|
* For supergroups/channels, you must have appropriate permissions,
|
|
3797
3828
|
* either as an admin, or as default permissions
|
|
3798
3829
|
*
|
|
3799
|
-
* **Available**:
|
|
3830
|
+
* **Available**: 👤 users only
|
|
3800
3831
|
*
|
|
3801
3832
|
* @param chatId Chat ID, username, phone number, `"self"` or `"me"`
|
|
3802
3833
|
* @param messageId Message ID
|
|
@@ -4019,7 +4050,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4019
4050
|
getMyBoostSlots(): Promise<BoostSlot[]>;
|
|
4020
4051
|
/**
|
|
4021
4052
|
* Get a list of star gifts up for resale
|
|
4022
|
-
* **Available**:
|
|
4053
|
+
* **Available**: 👤 users only
|
|
4023
4054
|
*
|
|
4024
4055
|
*/
|
|
4025
4056
|
getStarGiftResaleOptions(params: {
|
|
@@ -4049,7 +4080,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4049
4080
|
* Get a list of saved star gifts of a user/channel
|
|
4050
4081
|
*
|
|
4051
4082
|
* Note that filters currently only work for channels
|
|
4052
|
-
* **Available**:
|
|
4083
|
+
* **Available**: 👤 users only
|
|
4053
4084
|
*
|
|
4054
4085
|
*/
|
|
4055
4086
|
getSavedStarGifts(params: {
|
|
@@ -4067,6 +4098,10 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4067
4098
|
excludeUnupgradable?: boolean;
|
|
4068
4099
|
/** Whether to exclude gifts that can be upgraded */
|
|
4069
4100
|
excludeUpgradable?: boolean;
|
|
4101
|
+
/** Whether to exclude "hosted" gifts (i.e. those that are actually stored on the TON blockchain) */
|
|
4102
|
+
excludeHosted?: boolean;
|
|
4103
|
+
/** Whether to only return gifts with peer color available */
|
|
4104
|
+
peerColorAvailable?: boolean;
|
|
4070
4105
|
/** ID of the collection to get gifts from */
|
|
4071
4106
|
collectionId?: number;
|
|
4072
4107
|
/** Whether to sort by value */
|
|
@@ -4084,6 +4119,8 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4084
4119
|
getStarGiftOptions(): Promise<StarGift[]>;
|
|
4085
4120
|
/**
|
|
4086
4121
|
* Get the value of a unique star gift
|
|
4122
|
+
* **Available**: 👤 users only
|
|
4123
|
+
*
|
|
4087
4124
|
*/
|
|
4088
4125
|
getStarGiftValue(params: {
|
|
4089
4126
|
/** Slug of the star gift */
|
|
@@ -4101,7 +4138,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4101
4138
|
* You can either pass `self` to get your own transactions,
|
|
4102
4139
|
* or a chat/bot ID to get transactions of that peer.
|
|
4103
4140
|
*
|
|
4104
|
-
* **Available**:
|
|
4141
|
+
* **Available**: 👤 users only
|
|
4105
4142
|
*
|
|
4106
4143
|
* @param peerId Peer ID
|
|
4107
4144
|
* @param params Additional parameters
|
|
@@ -4132,7 +4169,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4132
4169
|
}): Promise<StarsStatus>;
|
|
4133
4170
|
/**
|
|
4134
4171
|
* Get information about a unique star gift by its slug
|
|
4135
|
-
* **Available**:
|
|
4172
|
+
* **Available**: 👤 users only
|
|
4136
4173
|
*
|
|
4137
4174
|
*/
|
|
4138
4175
|
getUniqueStarGift(slug: string): Promise<StarGiftUnique>;
|
|
@@ -4161,7 +4198,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4161
4198
|
/**
|
|
4162
4199
|
* Iterate over saved star gifts of a user,
|
|
4163
4200
|
* wrapper over {@link getSavedStarGifts}
|
|
4164
|
-
* **Available**:
|
|
4201
|
+
* **Available**: 👤 users only
|
|
4165
4202
|
*
|
|
4166
4203
|
*/
|
|
4167
4204
|
iterSavedStarGifts(params: Parameters<typeof getSavedStarGifts>[1] & {
|
|
@@ -4208,7 +4245,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4208
4245
|
}): AsyncIterableIterator<StarsTransaction>;
|
|
4209
4246
|
/**
|
|
4210
4247
|
* Toggles whether one or more star gift is pinned to the top of the list
|
|
4211
|
-
* **Available**:
|
|
4248
|
+
* **Available**: 👤 users only
|
|
4212
4249
|
*
|
|
4213
4250
|
*/
|
|
4214
4251
|
togglePinnedStarGifts(params: {
|
|
@@ -4372,7 +4409,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4372
4409
|
*
|
|
4373
4410
|
* For bots the sticker set must have been created by this bot.
|
|
4374
4411
|
*
|
|
4375
|
-
* **Available**:
|
|
4412
|
+
* **Available**: 👤 users only
|
|
4376
4413
|
*
|
|
4377
4414
|
* @param setId Sticker set short name or TL object with input sticker set
|
|
4378
4415
|
* @param sticker Sticker to be added
|
|
@@ -4391,7 +4428,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4391
4428
|
/**
|
|
4392
4429
|
* Create a new sticker set.
|
|
4393
4430
|
*
|
|
4394
|
-
* **Available**:
|
|
4431
|
+
* **Available**: 👤 users only
|
|
4395
4432
|
*
|
|
4396
4433
|
* @param params
|
|
4397
4434
|
* @returns Newly created sticker set
|
|
@@ -4459,7 +4496,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4459
4496
|
*
|
|
4460
4497
|
* For bots the sticker set must have been created by this bot.
|
|
4461
4498
|
*
|
|
4462
|
-
* **Available**:
|
|
4499
|
+
* **Available**: 👤 users only
|
|
4463
4500
|
*
|
|
4464
4501
|
* @param sticker
|
|
4465
4502
|
* TDLib and Bot API compatible File ID, or a
|
|
@@ -4470,7 +4507,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4470
4507
|
/**
|
|
4471
4508
|
* Get custom emoji stickers by their IDs
|
|
4472
4509
|
*
|
|
4473
|
-
* **Available**:
|
|
4510
|
+
* **Available**: 👤 users only
|
|
4474
4511
|
*
|
|
4475
4512
|
* @param ids IDs of the stickers (as defined in {@link MessageEntity.emojiId})
|
|
4476
4513
|
*/
|
|
@@ -4505,7 +4542,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4505
4542
|
/**
|
|
4506
4543
|
* Get a sticker set and stickers inside of it.
|
|
4507
4544
|
*
|
|
4508
|
-
* **Available**:
|
|
4545
|
+
* **Available**: 👤 users only
|
|
4509
4546
|
*
|
|
4510
4547
|
* @param setId Sticker set identifier
|
|
4511
4548
|
*/
|
|
@@ -4516,7 +4553,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4516
4553
|
*
|
|
4517
4554
|
* For bots the sticker set must have been created by this bot.
|
|
4518
4555
|
*
|
|
4519
|
-
* **Available**:
|
|
4556
|
+
* **Available**: 👤 users only
|
|
4520
4557
|
*
|
|
4521
4558
|
* @param sticker
|
|
4522
4559
|
* TDLib and Bot API compatible File ID, or a
|
|
@@ -4550,7 +4587,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4550
4587
|
/**
|
|
4551
4588
|
* Set group sticker set for a supergroup
|
|
4552
4589
|
*
|
|
4553
|
-
* **Available**:
|
|
4590
|
+
* **Available**: 👤 users only
|
|
4554
4591
|
*
|
|
4555
4592
|
* @param setId Sticker set short name or a TL object with input sticker set
|
|
4556
4593
|
* @param thumb Sticker set thumbnail
|
|
@@ -4561,7 +4598,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
4561
4598
|
/**
|
|
4562
4599
|
* Set sticker set thumbnail
|
|
4563
4600
|
*
|
|
4564
|
-
* **Available**:
|
|
4601
|
+
* **Available**: 👤 users only
|
|
4565
4602
|
*
|
|
4566
4603
|
* @param id Sticker set short name or a TL object with input sticker set
|
|
4567
4604
|
* @param thumb Sticker set thumbnail
|
|
@@ -5002,7 +5039,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
5002
5039
|
getGlobalTtl(): Promise<number>;
|
|
5003
5040
|
/**
|
|
5004
5041
|
* Get currently authorized user's full information
|
|
5005
|
-
* **Available**:
|
|
5042
|
+
* **Available**: 👤 users only
|
|
5006
5043
|
*
|
|
5007
5044
|
*/
|
|
5008
5045
|
getMe(): Promise<User>;
|
|
@@ -5020,7 +5057,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
5020
5057
|
/**
|
|
5021
5058
|
* Get a single profile picture of a user by its ID
|
|
5022
5059
|
*
|
|
5023
|
-
* **Available**:
|
|
5060
|
+
* **Available**: 👤 users only
|
|
5024
5061
|
*
|
|
5025
5062
|
* @param userId User ID, username, phone number, `"me"` or `"self"`
|
|
5026
5063
|
* @param photoId ID of the photo to fetch
|
|
@@ -5030,7 +5067,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
5030
5067
|
/**
|
|
5031
5068
|
* Get a list of profile pictures of a user
|
|
5032
5069
|
*
|
|
5033
|
-
* **Available**:
|
|
5070
|
+
* **Available**: 👤 users only
|
|
5034
5071
|
*
|
|
5035
5072
|
* @param userId User ID, username, phone number, `"me"` or `"self"`
|
|
5036
5073
|
* @param params
|
|
@@ -5051,6 +5088,8 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
5051
5088
|
}): Promise<ArrayPaginated<Photo, number>>;
|
|
5052
5089
|
/**
|
|
5053
5090
|
* Get music files saved to the user's profile
|
|
5091
|
+
* **Available**: 👤 users only
|
|
5092
|
+
*
|
|
5054
5093
|
*/
|
|
5055
5094
|
getSavedMusic(params: {
|
|
5056
5095
|
/** User ID, username, phone number, `"me"` or `"self"` */
|
|
@@ -5192,6 +5231,8 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
5192
5231
|
* - yourself (`self`)
|
|
5193
5232
|
* - supergroups or channels with enough boosts which you are an admin of
|
|
5194
5233
|
* - for bots – users who gave you the appropriate permissions
|
|
5234
|
+
* **Available**: 👤 users only
|
|
5235
|
+
*
|
|
5195
5236
|
*/
|
|
5196
5237
|
setEmojiStatus(params: {
|
|
5197
5238
|
/** User or chat where the emoji status should be set */
|
|
@@ -5231,7 +5272,7 @@ export interface TelegramClient extends ITelegramClient {
|
|
|
5231
5272
|
* Set a new profile photo or video for the current user.
|
|
5232
5273
|
*
|
|
5233
5274
|
* You can also pass a file ID or an InputPhoto to re-use existing photo.
|
|
5234
|
-
* **Available**:
|
|
5275
|
+
* **Available**: 👤 users only
|
|
5235
5276
|
*
|
|
5236
5277
|
*/
|
|
5237
5278
|
setMyProfilePhoto(params: {
|