Pytdbot 0.9.8.dev0__tar.gz → 0.9.8.post1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/PKG-INFO +11 -2
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/Pytdbot.egg-info/PKG-INFO +11 -2
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/README.md +10 -1
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/__init__.py +1 -1
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/client.py +3 -1
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/client_manager.py +9 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/handlers/td_updates.py +118 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/methods/methods.py +43 -42
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/methods/td_functions.py +2283 -1896
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/tdjson/tdjson.py +15 -10
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/__init__.py +21 -1
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/bound_methods/chatActions.py +5 -4
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/bound_methods/message.py +24 -24
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/td_types.py +2126 -1450
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/setup.py +3 -3
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/LICENSE +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/MANIFEST.in +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/Pytdbot.egg-info/SOURCES.txt +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/Pytdbot.egg-info/dependency_links.txt +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/Pytdbot.egg-info/requires.txt +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/Pytdbot.egg-info/top_level.txt +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/exception/__init__.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/filters.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/handlers/__init__.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/handlers/decorators.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/handlers/handler.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/methods/__init__.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/tdjson/__init__.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/bound_methods/__init__.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/bound_methods/callback_query.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/bound_methods/file.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/bound_methods/sender_id.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/plugins/__init__.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/tdserver/__init__.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/tdserver/schedule.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/types/tdserver/stats.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/utils/__init__.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/utils/asyncio_utils.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/utils/escape.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/utils/json_utils.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/utils/obj_encoder.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/utils/strings.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/utils/text_format.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/pytdbot/utils/webapps.py +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/requirements.txt +0 -0
- {pytdbot-0.9.8.dev0 → pytdbot-0.9.8.post1}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: Pytdbot
|
|
3
|
-
Version: 0.9.8.
|
|
3
|
+
Version: 0.9.8.post1
|
|
4
4
|
Summary: Easy-to-use asynchronous TDLib wrapper for Python.
|
|
5
5
|
Home-page: https://github.com/pytdbot/client
|
|
6
6
|
Author: AYMEN Mohammed
|
|
@@ -32,7 +32,11 @@ Dynamic: summary
|
|
|
32
32
|
|
|
33
33
|
# Pytdbot [](https://pypi.org/project/Pytdbot) [](https://github.com/tdlib/td) [](https://pepy.tech/project/pytdbot) [](https://t.me/pytdbotchat)
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
<a href="https://cupofton.pages.dev/donate?a=UQCeySURtYxvqF2jNXlsFrXuTEqPjJhGx8uoev6tUbD_HELL&n=AYMEN&t=5&c=You+deserve+a+Cup+of+TON+for+Pytdbot%2521" target="_blank" rel="noopener">
|
|
36
|
+
<img src="https://cupofton.pages.dev/assets/badge-1.svg" alt="Buy me a Cup of TON" style="width: 600px; height: auto;">
|
|
37
|
+
</a>
|
|
38
|
+
|
|
39
|
+
Pytdbot is an asynchronous [**TDLib**](https://github.com/tdlib/td) wrapper for **Telegram** users/bots written in **Python**.
|
|
36
40
|
|
|
37
41
|
### Features
|
|
38
42
|
|
|
@@ -86,9 +90,14 @@ Basic example:
|
|
|
86
90
|
```python
|
|
87
91
|
|
|
88
92
|
import asyncio
|
|
93
|
+
import logging
|
|
89
94
|
|
|
90
95
|
from pytdbot import Client, types
|
|
91
96
|
|
|
97
|
+
logging.basicConfig(
|
|
98
|
+
level=logging.INFO,
|
|
99
|
+
format="[%(levelname)s][p %(process)d %(threadName)s][%(created)f][%(filename)s:%(lineno)d][%(funcName)s][%(name)s] %(message)s",
|
|
100
|
+
)
|
|
92
101
|
client = Client(
|
|
93
102
|
token="1088394097:AAQX2DnWiw4ihwiJUhIHOGog8gGOI", # Your bot token
|
|
94
103
|
api_id=0,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: Pytdbot
|
|
3
|
-
Version: 0.9.8.
|
|
3
|
+
Version: 0.9.8.post1
|
|
4
4
|
Summary: Easy-to-use asynchronous TDLib wrapper for Python.
|
|
5
5
|
Home-page: https://github.com/pytdbot/client
|
|
6
6
|
Author: AYMEN Mohammed
|
|
@@ -32,7 +32,11 @@ Dynamic: summary
|
|
|
32
32
|
|
|
33
33
|
# Pytdbot [](https://pypi.org/project/Pytdbot) [](https://github.com/tdlib/td) [](https://pepy.tech/project/pytdbot) [](https://t.me/pytdbotchat)
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
<a href="https://cupofton.pages.dev/donate?a=UQCeySURtYxvqF2jNXlsFrXuTEqPjJhGx8uoev6tUbD_HELL&n=AYMEN&t=5&c=You+deserve+a+Cup+of+TON+for+Pytdbot%2521" target="_blank" rel="noopener">
|
|
36
|
+
<img src="https://cupofton.pages.dev/assets/badge-1.svg" alt="Buy me a Cup of TON" style="width: 600px; height: auto;">
|
|
37
|
+
</a>
|
|
38
|
+
|
|
39
|
+
Pytdbot is an asynchronous [**TDLib**](https://github.com/tdlib/td) wrapper for **Telegram** users/bots written in **Python**.
|
|
36
40
|
|
|
37
41
|
### Features
|
|
38
42
|
|
|
@@ -86,9 +90,14 @@ Basic example:
|
|
|
86
90
|
```python
|
|
87
91
|
|
|
88
92
|
import asyncio
|
|
93
|
+
import logging
|
|
89
94
|
|
|
90
95
|
from pytdbot import Client, types
|
|
91
96
|
|
|
97
|
+
logging.basicConfig(
|
|
98
|
+
level=logging.INFO,
|
|
99
|
+
format="[%(levelname)s][p %(process)d %(threadName)s][%(created)f][%(filename)s:%(lineno)d][%(funcName)s][%(name)s] %(message)s",
|
|
100
|
+
)
|
|
92
101
|
client = Client(
|
|
93
102
|
token="1088394097:AAQX2DnWiw4ihwiJUhIHOGog8gGOI", # Your bot token
|
|
94
103
|
api_id=0,
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
# Pytdbot [](https://pypi.org/project/Pytdbot) [](https://github.com/tdlib/td) [](https://pepy.tech/project/pytdbot) [](https://t.me/pytdbotchat)
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
<a href="https://cupofton.pages.dev/donate?a=UQCeySURtYxvqF2jNXlsFrXuTEqPjJhGx8uoev6tUbD_HELL&n=AYMEN&t=5&c=You+deserve+a+Cup+of+TON+for+Pytdbot%2521" target="_blank" rel="noopener">
|
|
4
|
+
<img src="https://cupofton.pages.dev/assets/badge-1.svg" alt="Buy me a Cup of TON" style="width: 600px; height: auto;">
|
|
5
|
+
</a>
|
|
6
|
+
|
|
7
|
+
Pytdbot is an asynchronous [**TDLib**](https://github.com/tdlib/td) wrapper for **Telegram** users/bots written in **Python**.
|
|
4
8
|
|
|
5
9
|
### Features
|
|
6
10
|
|
|
@@ -54,9 +58,14 @@ Basic example:
|
|
|
54
58
|
```python
|
|
55
59
|
|
|
56
60
|
import asyncio
|
|
61
|
+
import logging
|
|
57
62
|
|
|
58
63
|
from pytdbot import Client, types
|
|
59
64
|
|
|
65
|
+
logging.basicConfig(
|
|
66
|
+
level=logging.INFO,
|
|
67
|
+
format="[%(levelname)s][p %(process)d %(threadName)s][%(created)f][%(filename)s:%(lineno)d][%(funcName)s][%(name)s] %(message)s",
|
|
68
|
+
)
|
|
60
69
|
client = Client(
|
|
61
70
|
token="1088394097:AAQX2DnWiw4ihwiJUhIHOGog8gGOI", # Your bot token
|
|
62
71
|
api_id=0,
|
|
@@ -1133,7 +1133,9 @@ class Client(Decorators, Methods):
|
|
|
1133
1133
|
notify_queue = await self.__rchannel.declare_queue(
|
|
1134
1134
|
f"{self.my_id}_notify_{self._rabbitmq_instance_id}", exclusive=True
|
|
1135
1135
|
)
|
|
1136
|
-
await notify_queue.bind(
|
|
1136
|
+
await notify_queue.bind(
|
|
1137
|
+
await self.__rchannel.get_exchange(f"{self.my_id}_broadcast")
|
|
1138
|
+
)
|
|
1137
1139
|
|
|
1138
1140
|
responses_queue = await self.__rchannel.declare_queue(
|
|
1139
1141
|
f"{self.my_id}_res_{self._rabbitmq_instance_id}", exclusive=True
|
|
@@ -48,6 +48,7 @@ class ClientManager:
|
|
|
48
48
|
|
|
49
49
|
self.loop = loop or pytdbot.utils.get_running_loop()
|
|
50
50
|
self.__tdjson = TdJson(lib_path, verbosity)
|
|
51
|
+
self.check_tdlib_version()
|
|
51
52
|
|
|
52
53
|
self.__clients: dict[int, pytdbot.Client] = {}
|
|
53
54
|
|
|
@@ -137,6 +138,14 @@ class ClientManager:
|
|
|
137
138
|
|
|
138
139
|
self.__tdjson.send(client_id, request)
|
|
139
140
|
|
|
141
|
+
def check_tdlib_version(self):
|
|
142
|
+
if self.__tdjson.version != pytdbot.types.TDLIB_VERSION:
|
|
143
|
+
logger.warning(
|
|
144
|
+
f"Pytdbot v{pytdbot.VERSION} is designed for TDLib v{pytdbot.types.TDLIB_VERSION}, "
|
|
145
|
+
f"but the installed TDLib version is v{self.__tdjson.version}. "
|
|
146
|
+
"This may cause unexpected behavior or errors"
|
|
147
|
+
)
|
|
148
|
+
|
|
140
149
|
async def __td_receiver_loop(self) -> None:
|
|
141
150
|
with ThreadPoolExecutor(
|
|
142
151
|
max_workers=1, thread_name_prefix="ClientManager"
|
|
@@ -4082,6 +4082,65 @@ class Updates:
|
|
|
4082
4082
|
|
|
4083
4083
|
return decorator
|
|
4084
4084
|
|
|
4085
|
+
def on_updatePendingTextMessage(
|
|
4086
|
+
self: "pytdbot.Client" = None,
|
|
4087
|
+
filters: "pytdbot.filters.Filter" = None,
|
|
4088
|
+
position: int = None,
|
|
4089
|
+
timeout: float = None,
|
|
4090
|
+
) -> Callable:
|
|
4091
|
+
r"""A new pending text message was received in a chat with a bot\. The message must be shown in the chat for at most getOption\(\"pending\_text\_message\_period\"\) seconds, replace any other pending message with the same draft\_id, and be deleted whenever any incoming message from the bot in the message thread is received
|
|
4092
|
+
|
|
4093
|
+
Parameters:
|
|
4094
|
+
filters (:class:`pytdbot.filters.Filter`, *optional*):
|
|
4095
|
+
An update filter
|
|
4096
|
+
|
|
4097
|
+
position (``int``, *optional*):
|
|
4098
|
+
The function position in handlers list. Default is ``None`` (append)
|
|
4099
|
+
|
|
4100
|
+
timeout (``float``, *optional*):
|
|
4101
|
+
Max execution time for the handler before it timeout. Default is ``None``
|
|
4102
|
+
|
|
4103
|
+
Raises:
|
|
4104
|
+
:py:class:`TypeError`
|
|
4105
|
+
"""
|
|
4106
|
+
|
|
4107
|
+
def decorator(func: Callable) -> Callable:
|
|
4108
|
+
if hasattr(func, "_handler"):
|
|
4109
|
+
return func
|
|
4110
|
+
elif isinstance(self, pytdbot.Client):
|
|
4111
|
+
if iscoroutinefunction(func):
|
|
4112
|
+
self.add_handler(
|
|
4113
|
+
update_type="updatePendingTextMessage",
|
|
4114
|
+
func=func,
|
|
4115
|
+
filters=filters,
|
|
4116
|
+
position=position,
|
|
4117
|
+
inner_object=False,
|
|
4118
|
+
timeout=timeout,
|
|
4119
|
+
)
|
|
4120
|
+
else:
|
|
4121
|
+
raise TypeError("Handler must be async")
|
|
4122
|
+
elif isinstance(self, pytdbot.filters.Filter):
|
|
4123
|
+
func._handler = Handler(
|
|
4124
|
+
func=func,
|
|
4125
|
+
update_type="updatePendingTextMessage",
|
|
4126
|
+
filter=self,
|
|
4127
|
+
position=position,
|
|
4128
|
+
inner_object=False,
|
|
4129
|
+
timeout=timeout,
|
|
4130
|
+
)
|
|
4131
|
+
else:
|
|
4132
|
+
func._handler = Handler(
|
|
4133
|
+
func=func,
|
|
4134
|
+
update_type="updatePendingTextMessage",
|
|
4135
|
+
filter=filters,
|
|
4136
|
+
position=position,
|
|
4137
|
+
inner_object=False,
|
|
4138
|
+
timeout=timeout,
|
|
4139
|
+
)
|
|
4140
|
+
return func
|
|
4141
|
+
|
|
4142
|
+
return decorator
|
|
4143
|
+
|
|
4085
4144
|
def on_updateUserStatus(
|
|
4086
4145
|
self: "pytdbot.Client" = None,
|
|
4087
4146
|
filters: "pytdbot.filters.Filter" = None,
|
|
@@ -5439,6 +5498,65 @@ class Updates:
|
|
|
5439
5498
|
|
|
5440
5499
|
return decorator
|
|
5441
5500
|
|
|
5501
|
+
def on_updateGroupCallNewMessage(
|
|
5502
|
+
self: "pytdbot.Client" = None,
|
|
5503
|
+
filters: "pytdbot.filters.Filter" = None,
|
|
5504
|
+
position: int = None,
|
|
5505
|
+
timeout: float = None,
|
|
5506
|
+
) -> Callable:
|
|
5507
|
+
r"""A new message was received in a group call\. It must be shown for at most getOption\(\"group\_call\_message\_show\_time\_max\"\) seconds after receiving
|
|
5508
|
+
|
|
5509
|
+
Parameters:
|
|
5510
|
+
filters (:class:`pytdbot.filters.Filter`, *optional*):
|
|
5511
|
+
An update filter
|
|
5512
|
+
|
|
5513
|
+
position (``int``, *optional*):
|
|
5514
|
+
The function position in handlers list. Default is ``None`` (append)
|
|
5515
|
+
|
|
5516
|
+
timeout (``float``, *optional*):
|
|
5517
|
+
Max execution time for the handler before it timeout. Default is ``None``
|
|
5518
|
+
|
|
5519
|
+
Raises:
|
|
5520
|
+
:py:class:`TypeError`
|
|
5521
|
+
"""
|
|
5522
|
+
|
|
5523
|
+
def decorator(func: Callable) -> Callable:
|
|
5524
|
+
if hasattr(func, "_handler"):
|
|
5525
|
+
return func
|
|
5526
|
+
elif isinstance(self, pytdbot.Client):
|
|
5527
|
+
if iscoroutinefunction(func):
|
|
5528
|
+
self.add_handler(
|
|
5529
|
+
update_type="updateGroupCallNewMessage",
|
|
5530
|
+
func=func,
|
|
5531
|
+
filters=filters,
|
|
5532
|
+
position=position,
|
|
5533
|
+
inner_object=False,
|
|
5534
|
+
timeout=timeout,
|
|
5535
|
+
)
|
|
5536
|
+
else:
|
|
5537
|
+
raise TypeError("Handler must be async")
|
|
5538
|
+
elif isinstance(self, pytdbot.filters.Filter):
|
|
5539
|
+
func._handler = Handler(
|
|
5540
|
+
func=func,
|
|
5541
|
+
update_type="updateGroupCallNewMessage",
|
|
5542
|
+
filter=self,
|
|
5543
|
+
position=position,
|
|
5544
|
+
inner_object=False,
|
|
5545
|
+
timeout=timeout,
|
|
5546
|
+
)
|
|
5547
|
+
else:
|
|
5548
|
+
func._handler = Handler(
|
|
5549
|
+
func=func,
|
|
5550
|
+
update_type="updateGroupCallNewMessage",
|
|
5551
|
+
filter=filters,
|
|
5552
|
+
position=position,
|
|
5553
|
+
inner_object=False,
|
|
5554
|
+
timeout=timeout,
|
|
5555
|
+
)
|
|
5556
|
+
return func
|
|
5557
|
+
|
|
5558
|
+
return decorator
|
|
5559
|
+
|
|
5442
5560
|
def on_updateNewCallSignalingData(
|
|
5443
5561
|
self: "pytdbot.Client" = None,
|
|
5444
5562
|
filters: "pytdbot.filters.Filter" = None,
|
|
@@ -25,6 +25,7 @@ from ..types import (
|
|
|
25
25
|
InputThumbnail,
|
|
26
26
|
LinkPreviewOptions,
|
|
27
27
|
Message,
|
|
28
|
+
MessageTopic,
|
|
28
29
|
MessageCopyOptions,
|
|
29
30
|
MessageSelfDestructType,
|
|
30
31
|
MessageSendOptions,
|
|
@@ -117,7 +118,7 @@ class Methods(TDLibFunctions):
|
|
|
117
118
|
disable_notification: bool = False,
|
|
118
119
|
protect_content: bool = False,
|
|
119
120
|
allow_paid_broadcast: bool = False,
|
|
120
|
-
|
|
121
|
+
topic_id: MessageTopic = None,
|
|
121
122
|
quote: InputTextQuote = None,
|
|
122
123
|
reply_to: InputMessageReplyTo = None,
|
|
123
124
|
reply_to_message_id: int = 0,
|
|
@@ -170,8 +171,8 @@ class Methods(TDLibFunctions):
|
|
|
170
171
|
allow_paid_broadcast (``bool``, *optional*):
|
|
171
172
|
Pass true to allow the message to ignore regular broadcast limits for a small fee; for bots only. Default is ``False``
|
|
172
173
|
|
|
173
|
-
|
|
174
|
-
|
|
174
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
175
|
+
Topic in which the message will be sent; pass null if none
|
|
175
176
|
|
|
176
177
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
177
178
|
Chosen quote from the replied message; may be null if none
|
|
@@ -216,7 +217,7 @@ class Methods(TDLibFunctions):
|
|
|
216
217
|
disable_notification=disable_notification,
|
|
217
218
|
protect_content=protect_content,
|
|
218
219
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
219
|
-
|
|
220
|
+
topic_id=topic_id,
|
|
220
221
|
quote=quote,
|
|
221
222
|
reply_to=reply_to,
|
|
222
223
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -239,7 +240,7 @@ class Methods(TDLibFunctions):
|
|
|
239
240
|
protect_content: bool = False,
|
|
240
241
|
allow_paid_broadcast: bool = False,
|
|
241
242
|
has_spoiler: bool = False,
|
|
242
|
-
|
|
243
|
+
topic_id: MessageTopic = None,
|
|
243
244
|
quote: InputTextQuote = None,
|
|
244
245
|
reply_to: InputMessageReplyTo = None,
|
|
245
246
|
reply_to_message_id: int = 0,
|
|
@@ -295,8 +296,8 @@ class Methods(TDLibFunctions):
|
|
|
295
296
|
has_spoiler (``bool``, *optional*):
|
|
296
297
|
True, if the photo preview must be covered by a spoiler animation; not supported in secret chats
|
|
297
298
|
|
|
298
|
-
|
|
299
|
-
|
|
299
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
300
|
+
Topic in which the message will be sent; pass null if none
|
|
300
301
|
|
|
301
302
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
302
303
|
Chosen quote from the replied message; may be null if none
|
|
@@ -344,7 +345,7 @@ class Methods(TDLibFunctions):
|
|
|
344
345
|
disable_notification=disable_notification,
|
|
345
346
|
protect_content=protect_content,
|
|
346
347
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
347
|
-
|
|
348
|
+
topic_id=topic_id,
|
|
348
349
|
quote=quote,
|
|
349
350
|
reply_to=reply_to,
|
|
350
351
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -365,7 +366,7 @@ class Methods(TDLibFunctions):
|
|
|
365
366
|
disable_notification: bool = False,
|
|
366
367
|
protect_content: bool = False,
|
|
367
368
|
allow_paid_broadcast: bool = False,
|
|
368
|
-
|
|
369
|
+
topic_id: MessageTopic = None,
|
|
369
370
|
quote: InputTextQuote = None,
|
|
370
371
|
reply_to: InputMessageReplyTo = None,
|
|
371
372
|
reply_to_message_id: int = 0,
|
|
@@ -415,8 +416,8 @@ class Methods(TDLibFunctions):
|
|
|
415
416
|
allow_paid_broadcast (``bool``, *optional*):
|
|
416
417
|
Pass true to allow the message to ignore regular broadcast limits for a small fee; for bots only. Default is ``False``
|
|
417
418
|
|
|
418
|
-
|
|
419
|
-
|
|
419
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
420
|
+
Topic in which the message will be sent; pass null if none
|
|
420
421
|
|
|
421
422
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
422
423
|
Chosen quote from the replied message; may be null if none
|
|
@@ -463,7 +464,7 @@ class Methods(TDLibFunctions):
|
|
|
463
464
|
disable_notification=disable_notification,
|
|
464
465
|
protect_content=protect_content,
|
|
465
466
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
466
|
-
|
|
467
|
+
topic_id=topic_id,
|
|
467
468
|
quote=quote,
|
|
468
469
|
reply_to=reply_to,
|
|
469
470
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -482,7 +483,7 @@ class Methods(TDLibFunctions):
|
|
|
482
483
|
disable_notification: bool = False,
|
|
483
484
|
protect_content: bool = False,
|
|
484
485
|
allow_paid_broadcast: bool = False,
|
|
485
|
-
|
|
486
|
+
topic_id: MessageTopic = None,
|
|
486
487
|
quote: InputTextQuote = None,
|
|
487
488
|
reply_to: InputMessageReplyTo = None,
|
|
488
489
|
reply_to_message_id: int = 0,
|
|
@@ -526,8 +527,8 @@ class Methods(TDLibFunctions):
|
|
|
526
527
|
allow_paid_broadcast (``bool``, *optional*):
|
|
527
528
|
Pass true to allow the message to ignore regular broadcast limits for a small fee; for bots only. Default is ``False``
|
|
528
529
|
|
|
529
|
-
|
|
530
|
-
|
|
530
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
531
|
+
Topic in which the message will be sent; pass null if none
|
|
531
532
|
|
|
532
533
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
533
534
|
Chosen quote from the replied message; may be null if none
|
|
@@ -571,7 +572,7 @@ class Methods(TDLibFunctions):
|
|
|
571
572
|
disable_notification=disable_notification,
|
|
572
573
|
protect_content=protect_content,
|
|
573
574
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
574
|
-
|
|
575
|
+
topic_id=topic_id,
|
|
575
576
|
quote=quote,
|
|
576
577
|
reply_to=reply_to,
|
|
577
578
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -594,7 +595,7 @@ class Methods(TDLibFunctions):
|
|
|
594
595
|
protect_content: bool = False,
|
|
595
596
|
allow_paid_broadcast: bool = False,
|
|
596
597
|
has_spoiler: bool = False,
|
|
597
|
-
|
|
598
|
+
topic_id: MessageTopic = None,
|
|
598
599
|
quote: InputTextQuote = None,
|
|
599
600
|
reply_to: InputMessageReplyTo = None,
|
|
600
601
|
reply_to_message_id: int = 0,
|
|
@@ -650,8 +651,8 @@ class Methods(TDLibFunctions):
|
|
|
650
651
|
has_spoiler (``bool``, *optional*):
|
|
651
652
|
True, if the photo preview must be covered by a spoiler animation; not supported in secret chats
|
|
652
653
|
|
|
653
|
-
|
|
654
|
-
|
|
654
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
655
|
+
Topic in which the message will be sent; pass null if none
|
|
655
656
|
|
|
656
657
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
657
658
|
Chosen quote from the replied message; may be null if none
|
|
@@ -699,7 +700,7 @@ class Methods(TDLibFunctions):
|
|
|
699
700
|
disable_notification=disable_notification,
|
|
700
701
|
protect_content=protect_content,
|
|
701
702
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
702
|
-
|
|
703
|
+
topic_id=topic_id,
|
|
703
704
|
quote=quote,
|
|
704
705
|
reply_to=reply_to,
|
|
705
706
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -724,7 +725,7 @@ class Methods(TDLibFunctions):
|
|
|
724
725
|
protect_content: bool = False,
|
|
725
726
|
allow_paid_broadcast: bool = False,
|
|
726
727
|
has_spoiler: bool = False,
|
|
727
|
-
|
|
728
|
+
topic_id: MessageTopic = None,
|
|
728
729
|
quote: InputTextQuote = None,
|
|
729
730
|
reply_to: InputMessageReplyTo = None,
|
|
730
731
|
reply_to_message_id: int = 0,
|
|
@@ -786,8 +787,8 @@ class Methods(TDLibFunctions):
|
|
|
786
787
|
has_spoiler (``bool``, *optional*):
|
|
787
788
|
True, if the photo preview must be covered by a spoiler animation; not supported in secret chats
|
|
788
789
|
|
|
789
|
-
|
|
790
|
-
|
|
790
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
791
|
+
Topic in which the message will be sent; pass null if none
|
|
791
792
|
|
|
792
793
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
793
794
|
Chosen quote from the replied message; may be null if none
|
|
@@ -837,7 +838,7 @@ class Methods(TDLibFunctions):
|
|
|
837
838
|
disable_notification=disable_notification,
|
|
838
839
|
protect_content=protect_content,
|
|
839
840
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
840
|
-
|
|
841
|
+
topic_id=topic_id,
|
|
841
842
|
quote=quote,
|
|
842
843
|
reply_to=reply_to,
|
|
843
844
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -854,7 +855,7 @@ class Methods(TDLibFunctions):
|
|
|
854
855
|
disable_notification: bool = False,
|
|
855
856
|
protect_content: bool = False,
|
|
856
857
|
allow_paid_broadcast: bool = False,
|
|
857
|
-
|
|
858
|
+
topic_id: MessageTopic = None,
|
|
858
859
|
quote: InputTextQuote = None,
|
|
859
860
|
reply_to: InputMessageReplyTo = None,
|
|
860
861
|
reply_to_message_id: int = 0,
|
|
@@ -892,8 +893,8 @@ class Methods(TDLibFunctions):
|
|
|
892
893
|
allow_paid_broadcast (``bool``, *optional*):
|
|
893
894
|
Pass true to allow the message to ignore regular broadcast limits for a small fee; for bots only. Default is ``False``
|
|
894
895
|
|
|
895
|
-
|
|
896
|
-
|
|
896
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
897
|
+
Topic in which the message will be sent; pass null if none
|
|
897
898
|
|
|
898
899
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
899
900
|
Chosen quote from the replied message; may be null if none
|
|
@@ -927,7 +928,7 @@ class Methods(TDLibFunctions):
|
|
|
927
928
|
disable_notification=disable_notification,
|
|
928
929
|
protect_content=protect_content,
|
|
929
930
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
930
|
-
|
|
931
|
+
topic_id=topic_id,
|
|
931
932
|
quote=quote,
|
|
932
933
|
reply_to=reply_to,
|
|
933
934
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -946,7 +947,7 @@ class Methods(TDLibFunctions):
|
|
|
946
947
|
disable_notification: bool = False,
|
|
947
948
|
protect_content: bool = False,
|
|
948
949
|
allow_paid_broadcast: bool = False,
|
|
949
|
-
|
|
950
|
+
topic_id: MessageTopic = None,
|
|
950
951
|
quote: InputTextQuote = None,
|
|
951
952
|
reply_to: InputMessageReplyTo = None,
|
|
952
953
|
reply_to_message_id: int = 0,
|
|
@@ -990,8 +991,8 @@ class Methods(TDLibFunctions):
|
|
|
990
991
|
allow_paid_broadcast (``bool``, *optional*):
|
|
991
992
|
Pass true to allow the message to ignore regular broadcast limits for a small fee; for bots only. Default is ``False``
|
|
992
993
|
|
|
993
|
-
|
|
994
|
-
|
|
994
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
995
|
+
Topic in which the message will be sent; pass null if none
|
|
995
996
|
|
|
996
997
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
997
998
|
Chosen quote from the replied message; may be null if none
|
|
@@ -1035,7 +1036,7 @@ class Methods(TDLibFunctions):
|
|
|
1035
1036
|
disable_notification=disable_notification,
|
|
1036
1037
|
protect_content=protect_content,
|
|
1037
1038
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
1038
|
-
|
|
1039
|
+
topic_id=topic_id,
|
|
1039
1040
|
quote=quote,
|
|
1040
1041
|
reply_to=reply_to,
|
|
1041
1042
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -1053,7 +1054,7 @@ class Methods(TDLibFunctions):
|
|
|
1053
1054
|
disable_notification: bool = False,
|
|
1054
1055
|
protect_content: bool = False,
|
|
1055
1056
|
allow_paid_broadcast: bool = False,
|
|
1056
|
-
|
|
1057
|
+
topic_id: MessageTopic = None,
|
|
1057
1058
|
quote: InputTextQuote = None,
|
|
1058
1059
|
reply_to: InputMessageReplyTo = None,
|
|
1059
1060
|
reply_to_message_id: int = 0,
|
|
@@ -1094,8 +1095,8 @@ class Methods(TDLibFunctions):
|
|
|
1094
1095
|
allow_paid_broadcast (``bool``, *optional*):
|
|
1095
1096
|
Pass true to allow the message to ignore regular broadcast limits for a small fee; for bots only. Default is ``False``
|
|
1096
1097
|
|
|
1097
|
-
|
|
1098
|
-
|
|
1098
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
1099
|
+
Topic in which the message will be sent; pass null if none
|
|
1099
1100
|
|
|
1100
1101
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
1101
1102
|
Chosen quote from the replied message; may be null if none
|
|
@@ -1129,7 +1130,7 @@ class Methods(TDLibFunctions):
|
|
|
1129
1130
|
disable_notification=disable_notification,
|
|
1130
1131
|
protect_content=protect_content,
|
|
1131
1132
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
1132
|
-
|
|
1133
|
+
topic_id=topic_id,
|
|
1133
1134
|
quote=quote,
|
|
1134
1135
|
reply_to=reply_to,
|
|
1135
1136
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -1149,7 +1150,7 @@ class Methods(TDLibFunctions):
|
|
|
1149
1150
|
disable_notification: bool = False,
|
|
1150
1151
|
protect_content: bool = False,
|
|
1151
1152
|
allow_paid_broadcast: bool = False,
|
|
1152
|
-
|
|
1153
|
+
topic_id: MessageTopic = None,
|
|
1153
1154
|
quote: InputTextQuote = None,
|
|
1154
1155
|
reply_to: InputMessageReplyTo = None,
|
|
1155
1156
|
reply_to_message_id: int = 0,
|
|
@@ -1190,8 +1191,8 @@ class Methods(TDLibFunctions):
|
|
|
1190
1191
|
allow_paid_broadcast (``bool``, *optional*):
|
|
1191
1192
|
Pass true to allow the message to ignore regular broadcast limits for a small fee; for bots only. Default is ``False``
|
|
1192
1193
|
|
|
1193
|
-
|
|
1194
|
-
|
|
1194
|
+
topic_id (:class:`~pytdbot.types.MessageTopic`, *optional*):
|
|
1195
|
+
Topic in which the message will be sent; pass null if none
|
|
1195
1196
|
|
|
1196
1197
|
quote (:class:`~pytdbot.types.InputTextQuote`, *optional*):
|
|
1197
1198
|
Chosen quote from the replied message; may be null if none
|
|
@@ -1231,7 +1232,7 @@ class Methods(TDLibFunctions):
|
|
|
1231
1232
|
disable_notification=disable_notification,
|
|
1232
1233
|
protect_content=protect_content,
|
|
1233
1234
|
allow_paid_broadcast=allow_paid_broadcast,
|
|
1234
|
-
|
|
1235
|
+
topic_id=topic_id,
|
|
1235
1236
|
quote=quote,
|
|
1236
1237
|
reply_to=reply_to,
|
|
1237
1238
|
reply_to_message_id=reply_to_message_id,
|
|
@@ -1373,7 +1374,7 @@ class Methods(TDLibFunctions):
|
|
|
1373
1374
|
disable_notification: bool = False,
|
|
1374
1375
|
protect_content: bool = False,
|
|
1375
1376
|
allow_paid_broadcast: bool = False,
|
|
1376
|
-
|
|
1377
|
+
topic_id: MessageTopic = None,
|
|
1377
1378
|
quote: InputTextQuote = None,
|
|
1378
1379
|
reply_to: InputMessageReplyTo = None,
|
|
1379
1380
|
reply_to_message_id: int = 0,
|
|
@@ -1396,7 +1397,7 @@ class Methods(TDLibFunctions):
|
|
|
1396
1397
|
|
|
1397
1398
|
res = await self.sendMessage(
|
|
1398
1399
|
chat_id=chat_id,
|
|
1399
|
-
|
|
1400
|
+
topic_id=topic_id,
|
|
1400
1401
|
reply_to=reply_to,
|
|
1401
1402
|
options=MessageSendOptions(
|
|
1402
1403
|
disable_notification=disable_notification,
|