Skip to content

Commit

Permalink
Add reply_to_story_id parameter to send_inline_bot_result
Browse files Browse the repository at this point in the history
  • Loading branch information
KurimuzonAkuma committed Nov 25, 2024
1 parent 5d41f95 commit ba49bbf
Show file tree
Hide file tree
Showing 16 changed files with 26 additions and 21 deletions.
17 changes: 11 additions & 6 deletions pyrogram/methods/bots/send_inline_bot_result.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,15 @@ async def send_inline_bot_result(
chat_id: Union[int, str],
query_id: int,
result_id: str,
disable_notification: bool = None,
message_thread_id: int = None,
reply_to_message_id: int = None,
disable_notification: Optional[bool] = None,
message_thread_id: Optional[int] = None,
reply_to_message_id: Optional[int] = None,
reply_to_chat_id: Union[int, str] = None,
quote_text: str = None,
reply_to_story_id: Optional[int] = None,
quote_text: Optional[str] = None,
parse_mode: Optional["enums.ParseMode"] = None,
quote_entities: List["types.MessageEntity"] = None,
quote_offset: int = None
quote_entities: Optional[List["types.MessageEntity"]] = None,
quote_offset: Optional[int] = None
) -> "raw.base.Updates":
"""Send an inline bot result.
Bot results can be retrieved using :meth:`~pyrogram.Client.get_inline_bot_results`
Expand Down Expand Up @@ -69,6 +70,9 @@ async def send_inline_bot_result(
reply_to_chat_id (``int``, *optional*):
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down Expand Up @@ -102,6 +106,7 @@ async def send_inline_bot_result(
reply_to=utils.get_reply_to(
reply_to_message_id=reply_to_message_id,
reply_to_peer=await self.resolve_peer(reply_to_chat_id) if reply_to_chat_id else None,
reply_to_story_id=reply_to_story_id,
message_thread_id=message_thread_id,
quote_text=quote_text,
quote_entities=quote_entities,
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/copy_media_group.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ async def copy_media_group(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_animation.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ async def send_animation(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_audio.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ async def send_audio(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_cached_media.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ async def send_cached_media(
If the message is a reply, ID of the original message.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_dice.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ async def send_dice(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_document.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ async def send_document(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_media_group.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ async def send_media_group(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_message.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ async def send_message(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_photo.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ async def send_photo(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_sticker.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ async def send_sticker(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_video.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ async def send_video(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_video_note.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ async def send_video_note(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_voice.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ async def send_voice(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/methods/messages/send_web_page.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ async def send_web_page(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down
2 changes: 1 addition & 1 deletion pyrogram/types/messages_and_media/message.py
Original file line number Diff line number Diff line change
Expand Up @@ -4160,7 +4160,7 @@ async def reply_web_page(
If the message is a reply, ID of the original chat.
reply_to_story_id (``int``, *optional*):
Unique identifier for the target story.
If the message is a reply, ID of the target story.
quote_text (``str``, *optional*):
Text of the quote to be sent.
Expand Down

0 comments on commit ba49bbf

Please sign in to comment.