RubigramClient 1.5.4__tar.gz → 1.5.5__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.
Potentially problematic release.
This version of RubigramClient might be problematic. Click here for more details.
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/PKG-INFO +1 -1
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/RubigramClient.egg-info/PKG-INFO +1 -1
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/pyproject.toml +1 -1
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/rubigram/method.py +14 -14
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/rubigram/models.py +15 -16
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/LICENSE +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/README.md +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/RubigramClient.egg-info/SOURCES.txt +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/RubigramClient.egg-info/dependency_links.txt +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/RubigramClient.egg-info/requires.txt +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/RubigramClient.egg-info/top_level.txt +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/rubigram/__init__.py +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/rubigram/client.py +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/rubigram/filters.py +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/rubigram/network.py +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/rubigram/state.py +0 -0
- {rubigramclient-1.5.4 → rubigramclient-1.5.5}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: RubigramClient
|
|
3
|
-
Version: 1.5.
|
|
3
|
+
Version: 1.5.5
|
|
4
4
|
Summary: A simple and flexible Python library for building advanced Rubika bots with powerful message handling, inline buttons, and custom filters.
|
|
5
5
|
Author-email: Javad RZ <Javad.Py1385@gmail.com>
|
|
6
6
|
Classifier: Programming Language :: Python :: 3
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: RubigramClient
|
|
3
|
-
Version: 1.5.
|
|
3
|
+
Version: 1.5.5
|
|
4
4
|
Summary: A simple and flexible Python library for building advanced Rubika bots with powerful message handling, inline buttons, and custom filters.
|
|
5
5
|
Author-email: Javad RZ <Javad.Py1385@gmail.com>
|
|
6
6
|
Classifier: Programming Language :: Python :: 3
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "RubigramClient"
|
|
3
|
-
version = "1.5.
|
|
3
|
+
version = "1.5.5"
|
|
4
4
|
description = "A simple and flexible Python library for building advanced Rubika bots with powerful message handling, inline buttons, and custom filters."
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
requires-python = ">=3.7"
|
|
@@ -195,7 +195,7 @@ class Method(Network):
|
|
|
195
195
|
chat_id: str,
|
|
196
196
|
file: str,
|
|
197
197
|
file_name: str,
|
|
198
|
-
|
|
198
|
+
caption: str = None,
|
|
199
199
|
type: Literal["File", "Image", "Voice", "Music", "Gif", "Video"] = "File",
|
|
200
200
|
chat_keypad: Keypad = None,
|
|
201
201
|
inline_keypad: Keypad = None,
|
|
@@ -207,7 +207,7 @@ class Method(Network):
|
|
|
207
207
|
data = {
|
|
208
208
|
"chat_id": chat_id,
|
|
209
209
|
"file_id": file_id,
|
|
210
|
-
"text":
|
|
210
|
+
"text": caption,
|
|
211
211
|
"chat_keypad": chat_keypad.to_dict() if chat_keypad else None,
|
|
212
212
|
"inline_keypad": inline_keypad.to_dict() if inline_keypad else None,
|
|
213
213
|
"disable_notification": disable_notification,
|
|
@@ -218,20 +218,20 @@ class Method(Network):
|
|
|
218
218
|
response = await self.request("sendFile", data)
|
|
219
219
|
return MessageId.from_dict(response)
|
|
220
220
|
|
|
221
|
-
async def send_document(self, chat_id: str, document: str, name: str, **kwargs):
|
|
222
|
-
return await self.send_file(chat_id, document, name, "File", **kwargs)
|
|
221
|
+
async def send_document(self, chat_id: str, document: str, name: str, caption: str = None, **kwargs):
|
|
222
|
+
return await self.send_file(chat_id, document, name, caption, "File", **kwargs)
|
|
223
223
|
|
|
224
|
-
async def send_photo(self, chat_id: str, photo: str, name: str, **kwargs):
|
|
225
|
-
return await self.send_file(chat_id, photo, name, "Image", **kwargs)
|
|
224
|
+
async def send_photo(self, chat_id: str, photo: str, name: str, caption: str = None, **kwargs):
|
|
225
|
+
return await self.send_file(chat_id, photo, name, caption, "Image", **kwargs)
|
|
226
226
|
|
|
227
|
-
async def send_video(self, chat_id: str, video: str, name: str, **kwargs):
|
|
228
|
-
return await self.send_file(chat_id, video, name, "Video", **kwargs)
|
|
227
|
+
async def send_video(self, chat_id: str, video: str, name: str, caption: str = None, **kwargs):
|
|
228
|
+
return await self.send_file(chat_id, video, name, caption, "Video", **kwargs)
|
|
229
229
|
|
|
230
|
-
async def send_gif(self, chat_id: str, gif: str, name: str, **kwargs):
|
|
231
|
-
return await self.send_file(chat_id, gif, name, "Gif", **kwargs)
|
|
230
|
+
async def send_gif(self, chat_id: str, gif: str, name: str, caption: str = None, **kwargs):
|
|
231
|
+
return await self.send_file(chat_id, gif, name, caption, "Gif", **kwargs)
|
|
232
232
|
|
|
233
|
-
async def send_music(self, chat_id: str, music: str, name: str, **kwargs):
|
|
234
|
-
return await self.send_file(chat_id, music, name, "Music", **kwargs)
|
|
233
|
+
async def send_music(self, chat_id: str, music: str, name: str, caption: str = None, **kwargs):
|
|
234
|
+
return await self.send_file(chat_id, music, name, caption, "Music", **kwargs)
|
|
235
235
|
|
|
236
|
-
async def send_voice(self, chat_id: str, voice: str, name: str, **kwargs):
|
|
237
|
-
return await self.send_file(chat_id, voice, name, "Voice", **kwargs)
|
|
236
|
+
async def send_voice(self, chat_id: str, voice: str, name: str, caption: str = None, **kwargs):
|
|
237
|
+
return await self.send_file(chat_id, voice, name, caption, "Voice", **kwargs)
|
|
@@ -386,8 +386,7 @@ class MessageId(Dict):
|
|
|
386
386
|
@dataclass
|
|
387
387
|
class Update(Dict):
|
|
388
388
|
client: Optional["rubigram.Client"] = None
|
|
389
|
-
type: Optional[Literal["NewMessage", "UpdatedMessage", "RemovedMessage",
|
|
390
|
-
"StartedBot", "StoppedBot", "UpdatedPayment"]] = None
|
|
389
|
+
type: Optional[Literal["NewMessage", "UpdatedMessage", "RemovedMessage", "StartedBot", "StoppedBot", "UpdatedPayment"]] = None
|
|
391
390
|
chat_id: Optional[str] = None
|
|
392
391
|
removed_message_id: Optional[str] = None
|
|
393
392
|
new_message: Optional[Message] = None
|
|
@@ -417,32 +416,32 @@ class Update(Dict):
|
|
|
417
416
|
self,
|
|
418
417
|
file: str,
|
|
419
418
|
file_name: str,
|
|
420
|
-
|
|
419
|
+
caption: str = None,
|
|
421
420
|
type: Literal["File", "Image", "Voice", "Music", "Gif", "Video"] = "File",
|
|
422
421
|
chat_keypad: Keypad = None,
|
|
423
422
|
inline_keypad: Keypad = None,
|
|
424
423
|
chat_keypad_type: Literal["New", "Remove"] = None,
|
|
425
424
|
disable_notification: bool = False,
|
|
426
425
|
) -> "MessageId":
|
|
427
|
-
return await self.client.send_file(self.chat_id, file, file_name,
|
|
426
|
+
return await self.client.send_file(self.chat_id, file, file_name, caption, type, chat_keypad, inline_keypad, chat_keypad_type, disable_notification, self.new_message.message_id)
|
|
428
427
|
|
|
429
|
-
async def reply_document(self, document: str, name: str, **kwargs) -> "MessageId":
|
|
430
|
-
return await self.reply_file(document, name, "File", **kwargs)
|
|
428
|
+
async def reply_document(self, document: str, name: str, caption: Optional[str] = None, **kwargs) -> "MessageId":
|
|
429
|
+
return await self.reply_file(document, name, caption, "File", **kwargs)
|
|
431
430
|
|
|
432
|
-
async def reply_photo(self, photo: str, name: str, **kwargs) -> "MessageId":
|
|
433
|
-
return await self.reply_file(photo, name, "Image", **kwargs)
|
|
431
|
+
async def reply_photo(self, photo: str, name: str, caption: Optional[str] = None, **kwargs) -> "MessageId":
|
|
432
|
+
return await self.reply_file(photo, name, caption, "Image", **kwargs)
|
|
434
433
|
|
|
435
|
-
async def reply_video(self, video: str, name: str, **kwargs) -> "MessageId":
|
|
436
|
-
return await self.reply_file(video, name, "Video", **kwargs)
|
|
434
|
+
async def reply_video(self, video: str, name: str, caption: Optional[str] = None, **kwargs) -> "MessageId":
|
|
435
|
+
return await self.reply_file(video, name, caption, "Video", **kwargs)
|
|
437
436
|
|
|
438
|
-
async def reply_gif(self, gif: str, name: str, **kwargs) -> "MessageId":
|
|
439
|
-
return await self.reply_file(gif, name, "Gif", **kwargs)
|
|
437
|
+
async def reply_gif(self, gif: str, name: str, caption: Optional[str] = None, **kwargs) -> "MessageId":
|
|
438
|
+
return await self.reply_file(gif, name, caption, "Gif", **kwargs)
|
|
440
439
|
|
|
441
|
-
async def reply_music(self, music: str, name: str, **kwargs) -> "MessageId":
|
|
442
|
-
return await self.reply_file(music, name, "Music", **kwargs)
|
|
440
|
+
async def reply_music(self, music: str, name: str, caption: Optional[str] = None, **kwargs) -> "MessageId":
|
|
441
|
+
return await self.reply_file(music, name, caption, "Music", **kwargs)
|
|
443
442
|
|
|
444
|
-
async def reply_voice(self, voice: str, name: str, **kwargs) -> "MessageId":
|
|
445
|
-
return await self.reply_file(voice, name, "Voice", **kwargs)
|
|
443
|
+
async def reply_voice(self, voice: str, name: str, caption: Optional[str] = None, **kwargs) -> "MessageId":
|
|
444
|
+
return await self.reply_file(voice, name, caption, "Voice", **kwargs)
|
|
446
445
|
|
|
447
446
|
|
|
448
447
|
@dataclass
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|