diff --git a/pyrogram/methods/payments/send_star_gift.py b/pyrogram/methods/payments/send_star_gift.py index 9a8b81b2..c12db86e 100644 --- a/pyrogram/methods/payments/send_star_gift.py +++ b/pyrogram/methods/payments/send_star_gift.py @@ -45,6 +45,7 @@ class SendStarGift: star_gift_id (``int``): Unique identifier of star gift. + To get all available star gifts use :meth:`~pyrogram.Client.get_star_gifts`. text (``str``, *optional*): Text of the message to be sent. diff --git a/pyrogram/types/bots_and_keyboards/inline_keyboard_button.py b/pyrogram/types/bots_and_keyboards/inline_keyboard_button.py index 3090c3dc..d3fbef2c 100644 --- a/pyrogram/types/bots_and_keyboards/inline_keyboard_button.py +++ b/pyrogram/types/bots_and_keyboards/inline_keyboard_button.py @@ -74,11 +74,14 @@ class InlineKeyboardButton(Object): A button that asks for the 2-step verification password of the current user and then sends a callback query to a bot Data to be sent to the bot via a callback query. pay (``bool``, *optional*): - Change text of pay button. + Pass True, to send a Pay button. + Substrings `⭐` and `XTR` in the buttons's text will be replaced with a Telegram Star icon. Available in :meth:`~pyrogram.Client.send_invoice`. - + + **NOTE**: This type of button **must** always be the first button in the first row and can only be used in invoice messages. + copy_text (``str``, *optional*): - Text to copy. + A button that copies specified text to clipboard. Limited to 256 character. """ @@ -177,7 +180,7 @@ class InlineKeyboardButton(Object): text=b.text, pay=True ) - + if isinstance(b, raw.types.KeyboardButtonCopy): return InlineKeyboardButton( text=b.text, @@ -239,7 +242,7 @@ class InlineKeyboardButton(Object): if self.pay is not None: return raw.types.KeyboardButtonBuy(text=self.text) - + if self.copy_text is not None: return raw.types.KeyboardButtonCopy( text=self.text,