From 313dd665e775d19c673512bed14a80990d442fd4 Mon Sep 17 00:00:00 2001 From: KurimuzonAkuma Date: Fri, 23 Feb 2024 11:55:29 +0300 Subject: [PATCH] Add raw attribute to Story class --- pyrogram/types/messages_and_media/story.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/pyrogram/types/messages_and_media/story.py b/pyrogram/types/messages_and_media/story.py index ee93c89d..f84b18b3 100644 --- a/pyrogram/types/messages_and_media/story.py +++ b/pyrogram/types/messages_and_media/story.py @@ -123,6 +123,9 @@ class Story(Object, Update): deleted (``bool``, *optional*): The story is deleted. A story can be deleted in case it was deleted or you tried to retrieve a story that doesn't exist yet. + + raw (``pyrogram.raw.types.StoryItem``, *optional*): + The raw story object, as received from the Telegram API. """ # TODO: Add Media Areas @@ -160,7 +163,8 @@ class Story(Object, Update): disallowed_users: List[Union[int, str]] = None, reactions: List["types.Reaction"] = None, skipped: bool = None, - deleted: bool = None + deleted: bool = None, + raw: "raw.types.StoryItem" = None ): super().__init__(client) @@ -194,6 +198,7 @@ class Story(Object, Update): self.reactions = reactions self.skipped = skipped self.deleted = deleted + self.raw = raw @staticmethod async def _parse( @@ -340,6 +345,7 @@ class Story(Object, Update): allowed_users=allowed_users, disallowed_users=disallowed_users, reactions=reactions, + raw=story, client=client )