Skip to content

Commit 09f321b

Browse files
committed
Update code to reflect latest changes to the Bot API documentation
1 parent 7e25039 commit 09f321b

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

src/Telegram/ChatInviteLink.php

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,12 @@ class ChatInviteLink extends Type
4040
/** <em>Optional</em>. Number of pending join requests created using this link */
4141
public ?int $pending_join_request_count = null;
4242

43+
/** <em>Optional</em>. The number of seconds the subscription will be active for before the next payment */
44+
public ?int $subscription_period = null;
45+
46+
/** <em>Optional</em>. The amount of Telegram Stars a user must pay initially and after each subsequent subscription period to be a member of the chat using the link */
47+
public ?int $subscription_price = null;
48+
4349
/**
4450
* @param string $invite_link The invite link. If the link was created by another chat administrator, then the second part of the link will be replaced with “…”.
4551
* @param User $creator Creator of the link
@@ -50,6 +56,8 @@ class ChatInviteLink extends Type
5056
* @param int $expire_date <em>Optional</em>. Point in time (Unix timestamp) when the link will expire or has been expired
5157
* @param int $member_limit <em>Optional</em>. The maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999
5258
* @param int $pending_join_request_count <em>Optional</em>. Number of pending join requests created using this link
59+
* @param int $subscription_period <em>Optional</em>. The number of seconds the subscription will be active for before the next payment
60+
* @param int $subscription_price <em>Optional</em>. The amount of Telegram Stars a user must pay initially and after each subsequent subscription period to be a member of the chat using the link
5361
*/
5462
public static function make(
5563
string $invite_link,
@@ -61,6 +69,8 @@ public static function make(
6169
?int $expire_date = null,
6270
?int $member_limit = null,
6371
?int $pending_join_request_count = null,
72+
?int $subscription_period = null,
73+
?int $subscription_price = null,
6474
): static {
6575
return new static([
6676
'invite_link' => $invite_link,
@@ -72,6 +82,8 @@ public static function make(
7282
'expire_date' => $expire_date,
7383
'member_limit' => $member_limit,
7484
'pending_join_request_count' => $pending_join_request_count,
85+
'subscription_period' => $subscription_period,
86+
'subscription_price' => $subscription_price,
7587
]);
7688
}
7789
}

0 commit comments

Comments
 (0)