Skip to content

Api 9.0 business stories #4769

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Apr 28, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions changes/unreleased/4756.JT5nmUmGRG6qDEh5ScMn5f.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,7 @@ closes_threads = []
[[pull_requests]]
uid = "4766"
author_uid = "Bibo-Joshi"
[[pull_requests]]
uid = "4769"
author_uid = "aelkheir"
closes_threads = []
6 changes: 6 additions & 0 deletions docs/source/inclusions/bot_methods.rst
Original file line number Diff line number Diff line change
Expand Up @@ -415,6 +415,8 @@
- Used for getting gifts owned by the business account.
* - :meth:`~telegram.Bot.read_business_message`
- Used for marking a message as read.
* - :meth:`~telegram.Bot.delete_story`
- Used for deleting business stories posted by the bot.
* - :meth:`~telegram.Bot.delete_business_messages`
- Used for deleting business messages.
* - :meth:`~telegram.Bot.remove_business_account_profile_photo`
Expand All @@ -429,6 +431,10 @@
- Used for setting the business account gift settings.
* - :meth:`~telegram.Bot.set_business_account_profile_photo`
- Used for setting the business accounts profile photo
* - :meth:`~telegram.Bot.post_story`
- Used for posting a story on behalf of business account.
* - :meth:`~telegram.Bot.edit_story`
- Used for editing business stories posted by the bot.
* - :meth:`~telegram.Bot.convert_gift_to_stars`
- Used for converting owned reqular gifts to stars.
* - :meth:`~telegram.Bot.upgrade_gift`
Expand Down
12 changes: 12 additions & 0 deletions docs/source/telegram.at-tree.rst
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,16 @@ Available Types
telegram.inputprofilephotoanimated
telegram.inputprofilephotostatic
telegram.inputpolloption
telegram.inputstorycontent
telegram.inputstorycontentphoto
telegram.inputstorycontentvideo
telegram.keyboardbutton
telegram.keyboardbuttonpolltype
telegram.keyboardbuttonrequestchat
telegram.keyboardbuttonrequestusers
telegram.linkpreviewoptions
telegram.location
telegram.locationaddress
telegram.loginurl
telegram.maybeinaccessiblemessage
telegram.menubutton
Expand Down Expand Up @@ -148,6 +152,14 @@ Available Types
telegram.sentwebappmessage
telegram.shareduser
telegram.story
telegram.storyarea
telegram.storyareaposition
telegram.storyareatype
telegram.storyareatypelink
telegram.storyareatypelocation
telegram.storyareatypesuggestedreaction
telegram.storyareatypeuniquegift
telegram.storyareatypeweather
telegram.switchinlinequerychosenchat
telegram.telegramobject
telegram.textquote
Expand Down
6 changes: 6 additions & 0 deletions docs/source/telegram.inputstorycontent.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
InputStoryContent
=================

.. autoclass:: telegram.InputStoryContent
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.inputstorycontentphoto.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
InputStoryContentPhoto
======================

.. autoclass:: telegram.InputStoryContentPhoto
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.inputstorycontentvideo.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
InputStoryContentVideo
======================

.. autoclass:: telegram.InputStoryContentVideo
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.locationaddress.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
LocationAddress
===============

.. autoclass:: telegram.LocationAddress
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.storyarea.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
StoryArea
=========

.. autoclass:: telegram.StoryArea
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.storyareaposition.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
StoryAreaPosition
=================

.. autoclass:: telegram.StoryAreaPosition
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.storyareatype.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
StoryAreaType
=============

.. autoclass:: telegram.StoryAreaType
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.storyareatypelink.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
StoryAreaTypeLink
=================

.. autoclass:: telegram.StoryAreaTypeLink
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.storyareatypelocation.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
StoryAreaTypeLocation
=====================

.. autoclass:: telegram.StoryAreaTypeLocation
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.storyareatypesuggestedreaction.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
StoryAreaTypeSuggestedReaction
==============================

.. autoclass:: telegram.StoryAreaTypeSuggestedReaction
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.storyareatypeuniquegift.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
StoryAreaTypeUniqueGift
=======================

.. autoclass:: telegram.StoryAreaTypeUniqueGift
:members:
:show-inheritance:
6 changes: 6 additions & 0 deletions docs/source/telegram.storyareatypeweather.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
StoryAreaTypeWeather
====================

.. autoclass:: telegram.StoryAreaTypeWeather
:members:
:show-inheritance:
28 changes: 28 additions & 0 deletions telegram/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,9 @@
"InputProfilePhotoAnimated",
"InputProfilePhotoStatic",
"InputSticker",
"InputStoryContent",
"InputStoryContentPhoto",
"InputStoryContentVideo",
"InputTextMessageContent",
"InputVenueMessageContent",
"Invoice",
Expand All @@ -167,6 +170,7 @@
"LabeledPrice",
"LinkPreviewOptions",
"Location",
"LocationAddress",
"LoginUrl",
"MaskPosition",
"MaybeInaccessibleMessage",
Expand Down Expand Up @@ -242,6 +246,14 @@
"Sticker",
"StickerSet",
"Story",
"StoryArea",
"StoryAreaPosition",
"StoryAreaType",
"StoryAreaTypeLink",
"StoryAreaTypeLocation",
"StoryAreaTypeSuggestedReaction",
"StoryAreaTypeUniqueGift",
"StoryAreaTypeWeather",
"SuccessfulPayment",
"SwitchInlineQueryChosenChat",
"TelegramObject",
Expand Down Expand Up @@ -369,6 +381,11 @@
from ._choseninlineresult import ChosenInlineResult
from ._copytextbutton import CopyTextButton
from ._dice import Dice
from ._files._inputstorycontent import (
InputStoryContent,
InputStoryContentPhoto,
InputStoryContentVideo,
)
from ._files.animation import Animation
from ._files.audio import Audio
from ._files.chatphoto import ChatPhoto
Expand Down Expand Up @@ -529,6 +546,17 @@
from ._sentwebappmessage import SentWebAppMessage
from ._shared import ChatShared, SharedUser, UsersShared
from ._story import Story
from ._storyarea import (
LocationAddress,
StoryArea,
StoryAreaPosition,
StoryAreaType,
StoryAreaTypeLink,
StoryAreaTypeLocation,
StoryAreaTypeSuggestedReaction,
StoryAreaTypeUniqueGift,
StoryAreaTypeWeather,
)
from ._switchinlinequerychosenchat import SwitchInlineQueryChosenChat
from ._telegramobject import TelegramObject
from ._uniquegift import (
Expand Down
Loading
Loading