-
Notifications
You must be signed in to change notification settings - Fork 5
/
button.py
33 lines (33 loc) · 1.39 KB
/
button.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# COPYRIGHT (C) 2021-2022 © BY LEGENDX22 AND PROBOYX 🔥
"""
(((((((((((((((((((((((@LEGENDX22)))))))))))))))))))))))))))
(((((((((((((((((((((((@LEGENDX22)))))))))))))))))))))))))))
(((((((((((((((((((((((@LEGENDX22)))))))))))))))))))))))))))
(((((((((((((((((((((((@LEGENDX22)))))))))))))))))))))))))))
MADE BY LEGENDX22 AND PROBOYX
CREDITS TEAMLEGEND
DONT REMOVE THIS LINES
"""
from ULTRA.utils import admin_cmd
from LEGENDX import xbot, NAME
from telethon import Button
@borg.on(admin_cmd(pattern="button (.*)"))
async def Buttons(event):
await event.edit("making your button")
LEGENDX = Var.TG_BOT_USER_NAME_BF_HER
pro = event.text[7:]
pro, boy = pro.split("|")
if "LEGENDX" == "PROBOYX":
await xbot.send_message(event.chat_id, "buttons")
else:
try:
async with bot.conversation(LEGENDX) as proboyx:
await proboyx.send_message("/start")
await proboyx.get_response()
await proboyx.send_message("my button 🥺")
await xbot.send_message(bot.me.id, f"{NAME}", buttons=[[Button.url(f"{pro}", f"{boy}")]])
pro = await proboyx.get_response()
await pro.forward_to(event.chat_id)
await event.delete()
except:
await event.edit("example:\n.button b<button name>|<link>\n`.button LEGENDX|https://t.me/LEGENDX22`\nmake sure your name and link no have Useless spece ", link_preview=False)