You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: methods.ts
+19-5Lines changed: 19 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -180,6 +180,8 @@ export type ApiMethods<F> = {
180
180
message_thread_id?: number;
181
181
/** Unique identifier for the chat where the original message was sent (or channel username in the format `@channelusername`) */
182
182
from_chat_id: number|string;
183
+
/** New start timestamp for the forwarded video in the message */
184
+
video_start_timestamp?: number;
183
185
/** Sends the message silently. Users will receive a notification with no sound. */
184
186
disable_notification?: boolean;
185
187
/** Protects the contents of the forwarded message from forwarding and saving */
@@ -214,6 +216,8 @@ export type ApiMethods<F> = {
214
216
from_chat_id: number|string;
215
217
/** Message identifier in the chat specified in from_chat_id */
216
218
message_id: number;
219
+
/** New start timestamp for the copied video in the message */
220
+
video_start_timestamp?: number;
217
221
/** New caption for media, 0-1024 characters after entities parsing. If not specified, the original caption is kept */
218
222
caption?: string;
219
223
/** Mode for parsing entities in the new caption. See formatting options for more details. */
@@ -832,7 +836,7 @@ export type ApiMethods<F> = {
832
836
|"upload_video_note";
833
837
}): true;
834
838
835
-
/** Use this method to change the chosen reactions on a message. Service messages can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. Bots can't use paid reactions. Returns True on success. */
839
+
/** Use this method to change the chosen reactions on a message. Service messages of some types can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. Bots can't use paid reactions. Returns True on success. */
836
840
setMessageReaction(args: {
837
841
/** Unique identifier for the target chat or username of the target channel (in the format `@channelusername`) */
838
842
chat_id: number|string;
@@ -1730,13 +1734,15 @@ export type ApiMethods<F> = {
1730
1734
name: string;
1731
1735
}): true;
1732
1736
1733
-
/** Returns the list of gifts that can be sent by the bot to users. Requires no parameters. Returns a Gifts object. */
1737
+
/** Returns the list of gifts that can be sent by the bot to users and channel chats. Requires no parameters. Returns a Gifts object. */
1734
1738
getAvailableGifts(): Gifts;
1735
1739
1736
-
/** Sends a gift to the given user. The gift can't be converted to Telegram Stars by the user. Returns True on success. */
1740
+
/** Sends a gift to the given user or channel chat. The gift can't be converted to Telegram Stars by the receiver. Returns True on success. */
1737
1741
sendGift(args: {
1738
-
/** Unique identifier of the target user that will receive the gift */
1739
-
user_id: number;
1742
+
/** Required if chat_id is not specified. Unique identifier of the target user who will receive the gift */
1743
+
user_id?: number;
1744
+
/** Required if user_id is not specified. Unique identifier for the chat or username of the channel (in the format `@channelusername`) that will receive the gift */
1745
+
chat_id?: number|string;
1740
1746
/** Identifier of the gift */
1741
1747
gift_id: string;
1742
1748
/** Pass True to pay for the gift upgrade from the bot's balance, thereby making the upgrade free for the receiver */
/** Thumbnail of the file sent; can be ignored if thumbnail generation for the file is supported server-side. The thumbnail should be in JPEG format and less than 200 kB in size. A thumbnail's width and height should not exceed 320. Thumbnails can't be reused and can be only uploaded as a new file. Use Telegraf's [Input helpers](https://telegraf.js.org/modules/Input.html) to upload a new thumbnail. */
2101
2107
thumbnail?: F;
2108
+
/** Cover for the video in the message. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or use Telegraf's [Input helpers](https://telegraf.js.org/modules/Input.html) to upload a new one. */
2109
+
cover?: F|string;
2110
+
/** Start timestamp for the video in the message */
2111
+
start_timestamp?: number;
2102
2112
/** Caption of the video to be sent, 0-1024 characters after entities parsing */
2103
2113
caption?: string;
2104
2114
/** Mode for parsing entities in the video caption. See formatting options for more details. */
/** Thumbnail of the file sent; can be ignored if thumbnail generation for the file is supported server-side. The thumbnail should be in JPEG format and less than 200 kB in size. A thumbnail's width and height should not exceed 320. Thumbnails can't be reused and can be only uploaded as a new file. Use Telegraf's [Input helpers](https://telegraf.js.org/modules/Input.html) to upload a new thumbnail. */
2210
2220
thumbnail?: F|string;
2221
+
/** Cover for the video in the message. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or use Telegraf's [Input helpers](https://telegraf.js.org/modules/Input.html) to upload a new one. */
2222
+
cover?: F|string;
2223
+
/** Start timestamp for the video in the message */
0 commit comments