fix update
Browse files
akn/AllDownloaderBot/helpers/azrcallback.py
CHANGED
@@ -1,3 +1,4 @@
|
|
|
|
1 |
from pyrogram import filters, Client
|
2 |
from pyrogram.types import *
|
3 |
|
@@ -10,6 +11,17 @@ unmute_permissions = ChatPermissions(
|
|
10 |
can_pin_messages=False,
|
11 |
)
|
12 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
13 |
help_texts = {
|
14 |
"ban": "**Ban Commands:**\n"
|
15 |
"/ban - Ban a user\n"
|
@@ -55,7 +67,7 @@ help_texts = {
|
|
55 |
"/fbdl - Facebook Downloader\n"
|
56 |
"/ttdl - Tiktok Downloader\n"
|
57 |
"/twtdl - Twitter Downloader\n"
|
58 |
-
"alldl - All Downloader\n"
|
59 |
}
|
60 |
|
61 |
@Client.on_message(filters.regex("^arzunban_(\d+)"))
|
@@ -92,6 +104,10 @@ async def rxhelp_callback(client, callback):
|
|
92 |
|
93 |
@Client.on_callback_query(filters.regex("^rhelps_back"))
|
94 |
async def rhelp_back(client, callback):
|
|
|
|
|
|
|
|
|
95 |
keyboard = InlineKeyboardMarkup([
|
96 |
[
|
97 |
InlineKeyboardButton("π« Ban", callback_data="rhelp_ban"),
|
@@ -113,6 +129,6 @@ async def rhelp_back(client, callback):
|
|
113 |
]
|
114 |
])
|
115 |
await callback.edit_message_text(
|
116 |
-
|
117 |
reply_markup=keyboard
|
118 |
)
|
|
|
1 |
+
import time
|
2 |
from pyrogram import filters, Client
|
3 |
from pyrogram.types import *
|
4 |
|
|
|
11 |
can_pin_messages=False,
|
12 |
)
|
13 |
|
14 |
+
GROUP_TEXTS = """
|
15 |
+
Hi {name} i am a modular group management bot with some fun extras.
|
16 |
+
|
17 |
+
Resfresh Ping: `{ping}`
|
18 |
+
|
19 |
+
i can do Azrea Bot of things, and help u manage your group effortlessly!
|
20 |
+
|
21 |
+
All Command can be accessed by using: `/`
|
22 |
+
**Click on help to learn more!**
|
23 |
+
"""
|
24 |
+
|
25 |
help_texts = {
|
26 |
"ban": "**Ban Commands:**\n"
|
27 |
"/ban - Ban a user\n"
|
|
|
67 |
"/fbdl - Facebook Downloader\n"
|
68 |
"/ttdl - Tiktok Downloader\n"
|
69 |
"/twtdl - Twitter Downloader\n"
|
70 |
+
"/alldl - All Downloader\n"
|
71 |
}
|
72 |
|
73 |
@Client.on_message(filters.regex("^arzunban_(\d+)"))
|
|
|
104 |
|
105 |
@Client.on_callback_query(filters.regex("^rhelps_back"))
|
106 |
async def rhelp_back(client, callback):
|
107 |
+
start = time.time()
|
108 |
+
await client.get_me()
|
109 |
+
end = time.time()
|
110 |
+
latency = (end - start) * 1000
|
111 |
keyboard = InlineKeyboardMarkup([
|
112 |
[
|
113 |
InlineKeyboardButton("π« Ban", callback_data="rhelp_ban"),
|
|
|
129 |
]
|
130 |
])
|
131 |
await callback.edit_message_text(
|
132 |
+
GROUP_TEXTS.format(name=callback.from_user.mention, ping=f"{latency:.2f}ms"),
|
133 |
reply_markup=keyboard
|
134 |
)
|
akn/AllDownloaderBot/main.py
CHANGED
@@ -9,7 +9,6 @@ import httpx
|
|
9 |
import aiofiles
|
10 |
import hashlib
|
11 |
import urllib.parse
|
12 |
-
import asyncio
|
13 |
from pyrogram import *
|
14 |
from pyrogram.enums import *
|
15 |
from pyrogram import Client, filters
|
@@ -56,9 +55,9 @@ COMMAND = """
|
|
56 |
"""
|
57 |
|
58 |
GROUP_TEXTS = """
|
59 |
-
Hi {name}
|
60 |
|
61 |
-
Resfresh Ping: {ping}
|
62 |
|
63 |
i can do Azrea Bot of things, and help u manage your group effortlessly!
|
64 |
|
@@ -140,12 +139,11 @@ async def varzhelp_callbackz(c, callback):
|
|
140 |
InlineKeyboardButton("π₯ Downloader", callback_data="rhelp_downloader"),
|
141 |
],
|
142 |
[
|
143 |
-
InlineKeyboardButton("βͺ Back", callback_data="zvback"),
|
144 |
InlineKeyboardButton("β Close", callback_data="cclose"),
|
145 |
]
|
146 |
])
|
147 |
await callback.edit_message_text(
|
148 |
-
GROUP_TEXTS.format(name=callback.from_user.mention, ping=latency),
|
149 |
reply_markup=keyboard
|
150 |
)
|
151 |
|
@@ -163,6 +161,12 @@ async def startbot(c, m):
|
|
163 |
end = time.time()
|
164 |
latency = (end - start) * 1000
|
165 |
buttons = [
|
|
|
|
|
|
|
|
|
|
|
|
|
166 |
[
|
167 |
InlineKeyboardButton(
|
168 |
text="Developer",
|
@@ -179,7 +183,7 @@ async def startbot(c, m):
|
|
179 |
callback_data='author_cmd'
|
180 |
),
|
181 |
InlineKeyboardButton(
|
182 |
-
text="
|
183 |
callback_data='zvhelp'
|
184 |
)
|
185 |
]
|
@@ -197,7 +201,7 @@ async def startbot(c, m):
|
|
197 |
callback_data='author_cmd'
|
198 |
),
|
199 |
InlineKeyboardButton(
|
200 |
-
text="
|
201 |
callback_data='zvhelp'
|
202 |
)
|
203 |
]
|
@@ -210,11 +214,11 @@ async def startbot(c, m):
|
|
210 |
if is_pic and catbox_link:
|
211 |
return await m.reply_photo(
|
212 |
photo=catbox_link,
|
213 |
-
caption=GROUP_TEXTS.format(name=m.from_user.mention, ping=latency),
|
214 |
reply_markup=reply_markup
|
215 |
)
|
216 |
return await m.reply_text(
|
217 |
-
text=GROUP_TEXTS.format(name=m.from_user.mention, ping=latency),
|
218 |
disable_web_page_preview=True,
|
219 |
reply_markup=reply_markup
|
220 |
)
|
|
|
9 |
import aiofiles
|
10 |
import hashlib
|
11 |
import urllib.parse
|
|
|
12 |
from pyrogram import *
|
13 |
from pyrogram.enums import *
|
14 |
from pyrogram import Client, filters
|
|
|
55 |
"""
|
56 |
|
57 |
GROUP_TEXTS = """
|
58 |
+
Hi {name} i am a modular group management bot with some fun extras.
|
59 |
|
60 |
+
Resfresh Ping: `{ping}`
|
61 |
|
62 |
i can do Azrea Bot of things, and help u manage your group effortlessly!
|
63 |
|
|
|
139 |
InlineKeyboardButton("π₯ Downloader", callback_data="rhelp_downloader"),
|
140 |
],
|
141 |
[
|
|
|
142 |
InlineKeyboardButton("β Close", callback_data="cclose"),
|
143 |
]
|
144 |
])
|
145 |
await callback.edit_message_text(
|
146 |
+
GROUP_TEXTS.format(name=callback.from_user.mention, ping=f"{latency:.2f}ms"),
|
147 |
reply_markup=keyboard
|
148 |
)
|
149 |
|
|
|
161 |
end = time.time()
|
162 |
latency = (end - start) * 1000
|
163 |
buttons = [
|
164 |
+
[
|
165 |
+
InlineKeyboardButton(
|
166 |
+
text="Add to your group",
|
167 |
+
url=f"https://t.me/{c.me.username}?startgroup=true&admin=manage_chat+change_info+post_messages+edit_messages+delete_messages+invite_users+restrict_members+pin_messages+promote_members+manage_video_chats+anonymous=false"
|
168 |
+
)
|
169 |
+
],
|
170 |
[
|
171 |
InlineKeyboardButton(
|
172 |
text="Developer",
|
|
|
183 |
callback_data='author_cmd'
|
184 |
),
|
185 |
InlineKeyboardButton(
|
186 |
+
text="Modules",
|
187 |
callback_data='zvhelp'
|
188 |
)
|
189 |
]
|
|
|
201 |
callback_data='author_cmd'
|
202 |
),
|
203 |
InlineKeyboardButton(
|
204 |
+
text="Modules",
|
205 |
callback_data='zvhelp'
|
206 |
)
|
207 |
]
|
|
|
214 |
if is_pic and catbox_link:
|
215 |
return await m.reply_photo(
|
216 |
photo=catbox_link,
|
217 |
+
caption=GROUP_TEXTS.format(name=m.from_user.mention, ping=f"{latency:.2f}ms"),
|
218 |
reply_markup=reply_markup
|
219 |
)
|
220 |
return await m.reply_text(
|
221 |
+
text=GROUP_TEXTS.format(name=m.from_user.mention, ping=f"{latency:.2f}ms"),
|
222 |
disable_web_page_preview=True,
|
223 |
reply_markup=reply_markup
|
224 |
)
|