@grammyjs/types 2.4.2 → 2.4.6
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/manage.d.ts +3 -3
- package/message.d.ts +4 -4
- package/package.json +1 -1
- package/proxied.d.ts +1 -8
package/manage.d.ts
CHANGED
|
@@ -118,7 +118,7 @@ export namespace Chat {
|
|
|
118
118
|
/** Default chat member permissions, for groups and supergroups. Returned only in getChat. */
|
|
119
119
|
permissions?: ChatPermissions;
|
|
120
120
|
/** True, if the bot can change the group sticker set. Returned only in getChat. */
|
|
121
|
-
can_set_sticker_set?:
|
|
121
|
+
can_set_sticker_set?: true;
|
|
122
122
|
}
|
|
123
123
|
/** Internal type holding properties that those supergroup and channel chats returned from `getChat` share. */
|
|
124
124
|
interface LargeGetChat extends NonPrivateGetChat {
|
|
@@ -381,9 +381,9 @@ export interface ChatLocation {
|
|
|
381
381
|
|
|
382
382
|
/** This object represents a bot command. */
|
|
383
383
|
export interface BotCommand {
|
|
384
|
-
/** Text of the command
|
|
384
|
+
/** Text of the command; 1-32 characters. Can contain only lowercase English letters, digits and underscores. */
|
|
385
385
|
command: string;
|
|
386
|
-
/** Description of the command
|
|
386
|
+
/** Description of the command; 1-256 characters. */
|
|
387
387
|
description: string;
|
|
388
388
|
}
|
|
389
389
|
|
package/message.d.ts
CHANGED
|
@@ -9,9 +9,9 @@ export namespace Message {
|
|
|
9
9
|
interface ServiceMessage {
|
|
10
10
|
/** Unique message identifier inside this chat */
|
|
11
11
|
message_id: number;
|
|
12
|
-
/** Sender
|
|
12
|
+
/** Sender of the message; empty for messages sent to channels. For backward compatibility, the field contains a fake sender user in non-channel chats, if the message was sent on behalf of a chat. */
|
|
13
13
|
from?: User;
|
|
14
|
-
/** Sender of the message, sent on behalf of a chat.
|
|
14
|
+
/** Sender of the message, sent on behalf of a chat. For example, the channel itself for channel posts, the supergroup itself for messages from anonymous group administrators, the linked channel for messages automatically forwarded to the discussion group. For backward compatibility, the field from contains a fake sender user in non-channel chats, if the message was sent on behalf of a chat. */
|
|
15
15
|
sender_chat?: Chat;
|
|
16
16
|
/** Date the message was sent in Unix time */
|
|
17
17
|
date: number;
|
|
@@ -25,7 +25,7 @@ export namespace Message {
|
|
|
25
25
|
forward_from_chat?: Chat;
|
|
26
26
|
/** For messages forwarded from channels, identifier of the original message in the channel */
|
|
27
27
|
forward_from_message_id?: number;
|
|
28
|
-
/** For messages
|
|
28
|
+
/** For forwarded messages that were originally sent in channels or by an anonymous chat administrator, signature of the message sender if present */
|
|
29
29
|
forward_signature?: string;
|
|
30
30
|
/** Sender's name for messages forwarded from users who disallow adding a link to their account in forwarded messages */
|
|
31
31
|
forward_sender_name?: string;
|
|
@@ -217,7 +217,7 @@ export interface MessageId {
|
|
|
217
217
|
Note that Telegram clients will display an **alert** to the user before opening an inline link ('Open this link?' together with the full URL).
|
|
218
218
|
|
|
219
219
|
Message entities can be nested, providing following restrictions are met:
|
|
220
|
-
- If two entities
|
|
220
|
+
- If two entities have common characters then one of them is fully contained inside another.
|
|
221
221
|
- bold, italic, underline and strikethrough entities can contain and to be contained in any other entities, except pre and code.
|
|
222
222
|
- All other entities can't contain each other.
|
|
223
223
|
|
package/package.json
CHANGED
package/proxied.d.ts
CHANGED
|
@@ -722,14 +722,7 @@ export interface InputFileProxy<F> {
|
|
|
722
722
|
custom_title: string;
|
|
723
723
|
}): true;
|
|
724
724
|
|
|
725
|
-
/**
|
|
726
|
-
* Use this method to ban a channel chat in a supergroup or a channel. Until the chat is unbanned, the owner of the banned chat:
|
|
727
|
-
*
|
|
728
|
-
* - Won't be able to send messages on behalf of any of their channels.
|
|
729
|
-
* - Won't be able to join live streams on behalf of the banned chat.
|
|
730
|
-
*
|
|
731
|
-
* The bot must be an administrator in the supergroup or channel for this to work and must have the appropriate administrator rights. Returns True on success.
|
|
732
|
-
*/
|
|
725
|
+
/** Use this method to ban a channel chat in a supergroup or a channel. Until the chat is unbanned, the owner of the banned chat won't be able to send messages on behalf of any of their channels. The bot must be an administrator in the supergroup or channel for this to work and must have the appropriate administrator rights. Returns True on success. */
|
|
733
726
|
banChatSenderChat(args: {
|
|
734
727
|
/** Unique identifier for the target chat or username of the target channel (in the format @channelusername) */
|
|
735
728
|
chat_id: number | string;
|