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: src/Layers/Generated.php
+44-6Lines changed: 44 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -591,11 +591,12 @@ public function sendVideoNote(
591
591
}
592
592
593
593
/**
594
-
* Use this method to send paid media to channel chats. On success, the sent <a href="https://core.telegram.org/bots/api#message">Message</a> is returned.
594
+
* Use this method to send paid media. On success, the sent <a href="https://core.telegram.org/bots/api#message">Message</a> is returned.
595
595
*
596
-
* @param int|string $chat_id Unique identifier for the target chat or username of the target channel (in the format @channelusername)
596
+
* @param int|string $chat_id Unique identifier for the target chat or username of the target channel (in the format @channelusername). If the chat is a channel, all Telegram Star proceeds from this media will be credited to the chat's balance. Otherwise, they will be credited to the bot's balance.
597
597
* @param int $star_count The number of Telegram Stars that must be paid to buy access to the media
598
598
* @param InputPaidMedia[] $media A JSON-serialized array describing the media to be sent; up to 10 items
599
+
* @param string $business_connection_id Unique identifier of the business connection on behalf of which the message will be sent
599
600
* @param string $caption Media caption, 0-1024 characters after entities parsing
600
601
* @param ParseMode|string $parse_mode Mode for parsing entities in the media caption. See <a href="https://core.telegram.org/bots/api#formatting-options">formatting options</a> for more details.
601
602
* @param MessageEntity[] $caption_entities A JSON-serialized list of special entities that appear in the caption, which can be specified instead of <em>parse_mode</em>
@@ -611,6 +612,7 @@ public function sendPaidMedia(
611
612
int|string$chat_id,
612
613
int$star_count,
613
614
array$media,
615
+
?string$business_connection_id = null,
614
616
?string$caption = null,
615
617
ParseMode|string|null$parse_mode = null,
616
618
?array$caption_entities = null,
@@ -872,11 +874,11 @@ public function sendChatAction(
872
874
}
873
875
874
876
/**
875
-
* 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. Returns <em>True</em> on success.
877
+
* 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 <em>True</em> on success.
876
878
*
877
879
* @param int|string $chat_id Unique identifier for the target chat or username of the target channel (in the format @channelusername)
878
880
* @param int $message_id Identifier of the target message. If the message belongs to a media group, the reaction is set to the first non-deleted message in the group instead.
879
-
* @param ReactionType[] $reaction A JSON-serialized list of reaction types to set on the message. Currently, as non-premium users, bots can set up to one reaction per message. A custom emoji reaction can be used if it is either already present on the message or explicitly allowed by chat administrators.
881
+
* @param ReactionType[] $reaction A JSON-serialized list of reaction types to set on the message. Currently, as non-premium users, bots can set up to one reaction per message. A custom emoji reaction can be used if it is either already present on the message or explicitly allowed by chat administrators. Paid reactions can't be used by bots.
880
882
* @param bool $is_big Pass <em>True</em> to set the reaction with a big animation
881
883
*
882
884
* @throws TelegramException
@@ -1128,6 +1130,42 @@ public function editChatInviteLink(
* Use this method to create a <a href="https://telegram.org/blog/superchannels-star-reactions-subscriptions#star-subscriptions">subscription invite link</a> for a channel chat. The bot must have the <em>can_invite_users</em> administrator rights. The link can be edited using the method <a href="https://core.telegram.org/bots/api#editchatsubscriptioninvitelink">editChatSubscriptionInviteLink</a> or revoked using the method <a href="https://core.telegram.org/bots/api#revokechatinvitelink">revokeChatInviteLink</a>. Returns the new invite link as a <a href="https://core.telegram.org/bots/api#chatinvitelink">ChatInviteLink</a> object.
1135
+
*
1136
+
* @param int|string $chat_id Unique identifier for the target channel chat or username of the target channel (in the format @channelusername)
1137
+
* @param int $subscription_period The number of seconds the subscription will be active for before the next payment. Currently, it must always be 2592000 (30 days).
1138
+
* @param int $subscription_price The amount of Telegram Stars a user must pay initially and after each subsequent subscription period to be a member of the chat; 1-2500
1139
+
* @param string $name Invite link name; 0-32 characters
* Use this method to edit a subscription invite link created by the bot. The bot must have the <em>can_invite_users</em> administrator rights. Returns the edited invite link as a <a href="https://core.telegram.org/bots/api#chatinvitelink">ChatInviteLink</a> object.
1154
+
*
1155
+
* @param int|string $chat_id Unique identifier for the target chat or username of the target channel (in the format @channelusername)
1156
+
* @param string $invite_link The invite link to edit
1157
+
* @param string $name Invite link name; 0-32 characters
* Use this method to revoke an invite link created by the bot. If the primary link is revoked, a new link is automatically generated. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns the revoked invite link as <a href="https://core.telegram.org/bots/api#chatinvitelink">ChatInviteLink</a> object.
1133
1171
*
@@ -1385,7 +1423,7 @@ public function createForumTopic(
1385
1423
}
1386
1424
1387
1425
/**
1388
-
* Use this method to edit name and icon of a topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have <em>can_manage_topics</em> administrator rights, unless it is the creator of the topic. Returns <em>True</em> on success.
1426
+
* Use this method to edit name and icon of a topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the <em>can_manage_topics</em> administrator rights, unless it is the creator of the topic. Returns <em>True</em> on success.
1389
1427
*
1390
1428
* @param int|string $chat_id Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
1391
1429
* @param int $message_thread_id Unique identifier for the target message thread of the forum topic
@@ -1456,7 +1494,7 @@ public function unpinAllForumTopicMessages(int|string $chat_id, int $message_thr
1456
1494
}
1457
1495
1458
1496
/**
1459
-
* Use this method to edit the name of the 'General' topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have <em>can_manage_topics</em> administrator rights. Returns <em>True</em> on success.
1497
+
* Use this method to edit the name of the 'General' topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the <em>can_manage_topics</em> administrator rights. Returns <em>True</em> on success.
1460
1498
*
1461
1499
* @param int|string $chat_id Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
1462
1500
* @param string $name New topic name, 1-128 characters
Copy file name to clipboardExpand all lines: src/Telegram/Message.php
+4-4Lines changed: 4 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -18,10 +18,10 @@ class Message extends MaybeInaccessibleMessage
18
18
/** <em>Optional</em>. Unique identifier of a message thread to which the message belongs; for supergroups only */
19
19
public ?int$message_thread_id = null;
20
20
21
-
/** <em>Optional</em>. 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. */
21
+
/** <em>Optional</em>. Sender of the message; may be empty for messages sent to channels. For backward compatibility, if the message was sent on behalf of a chat, the field contains a fake sender user in non-channel chats */
22
22
public ?User$from = null;
23
23
24
-
/** <em>Optional</em>. 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 <em>from</em> contains a fake sender user in non-channel chats, if the message was sent on behalf of a chat. */
24
+
/** <em>Optional</em>. Sender of the message when sent on behalf of a chat. For example, the supergroup itself for messages sent by its anonymous administrators or a linked channel for messages automatically forwarded to the channel's discussion group. For backward compatibility, if the message was sent on behalf of a chat, the field <em>from</em> contains a fake sender user in non-channel chats. */
25
25
public ?Chat$sender_chat = null;
26
26
27
27
/** <em>Optional</em>. If the sender of the message boosted the chat, the number of boosts added by the user */
@@ -286,8 +286,8 @@ class Message extends MaybeInaccessibleMessage
286
286
* @param int $date Date the message was sent in Unix time. It is always a positive number, representing a valid date.
287
287
* @param Chat $chat Chat the message belongs to
288
288
* @param int $message_thread_id <em>Optional</em>. Unique identifier of a message thread to which the message belongs; for supergroups only
289
-
* @param User $from <em>Optional</em>. 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.
290
-
* @param Chat $sender_chat <em>Optional</em>. 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 <em>from</em> contains a fake sender user in non-channel chats, if the message was sent on behalf of a chat.
289
+
* @param User $from <em>Optional</em>. Sender of the message; may be empty for messages sent to channels. For backward compatibility, if the message was sent on behalf of a chat, the field contains a fake sender user in non-channel chats
290
+
* @param Chat $sender_chat <em>Optional</em>. Sender of the message when sent on behalf of a chat. For example, the supergroup itself for messages sent by its anonymous administrators or a linked channel for messages automatically forwarded to the channel's discussion group. For backward compatibility, if the message was sent on behalf of a chat, the field <em>from</em> contains a fake sender user in non-channel chats.
291
291
* @param int $sender_boost_count <em>Optional</em>. If the sender of the message boosted the chat, the number of boosts added by the user
292
292
* @param User $sender_business_bot <em>Optional</em>. The bot that actually sent the message on behalf of the business account. Available only for outgoing messages sent on behalf of the connected business account.
293
293
* @param string $business_connection_id <em>Optional</em>. Unique identifier of the business connection from which the message was received. If non-empty, the message belongs to a chat of the corresponding business account that is independent from any potential bot chat which might share the same identifier.
0 commit comments