mirror of
https://github.com/Mayuri-Chan/pyrofork.git
synced 2026-01-03 14:04:51 +00:00
Added the ability to specify a payload in send_paid_media which is not used currently
Signed-off-by: wulan17 <wulan17@nusantararom.org>
This commit is contained in:
parent
e5327d2216
commit
2faae08064
1 changed files with 7 additions and 2 deletions
|
|
@ -42,7 +42,8 @@ class SendPaidMedia:
|
||||||
disable_notification: bool = None,
|
disable_notification: bool = None,
|
||||||
schedule_date: datetime = None,
|
schedule_date: datetime = None,
|
||||||
protect_content: bool = None,
|
protect_content: bool = None,
|
||||||
invert_media: bool = None
|
invert_media: bool = None,
|
||||||
|
payload: str = None
|
||||||
) -> "types.Message":
|
) -> "types.Message":
|
||||||
"""Send paid media.
|
"""Send paid media.
|
||||||
Only for channels.
|
Only for channels.
|
||||||
|
|
@ -83,6 +84,9 @@ class SendPaidMedia:
|
||||||
|
|
||||||
invert_media (``bool``, *optional*):
|
invert_media (``bool``, *optional*):
|
||||||
Invert the media.
|
Invert the media.
|
||||||
|
|
||||||
|
payload (``str``, *optional*):
|
||||||
|
Bot-defined paid media payload, 0-128 bytes. This will not be displayed to the user, use it for your internal processes.
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
|
|
@ -268,7 +272,8 @@ class SendPaidMedia:
|
||||||
peer=await self.resolve_peer(chat_id),
|
peer=await self.resolve_peer(chat_id),
|
||||||
media=raw.types.InputMediaPaidMedia(
|
media=raw.types.InputMediaPaidMedia(
|
||||||
stars_amount=stars_amount,
|
stars_amount=stars_amount,
|
||||||
extended_media=multi_media
|
extended_media=multi_media,
|
||||||
|
payload=payload
|
||||||
),
|
),
|
||||||
silent=disable_notification or None,
|
silent=disable_notification or None,
|
||||||
random_id=self.rnd_id(),
|
random_id=self.rnd_id(),
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue