async def leave(event) -> None: try: link = event.text.split(" ", 1)[1] except BaseException: return c_id = re.match(r'-(\d+)', link) if c_id: await System(LeaveChannelRequest(int(c_id.group(0)))) await System.send_message(event.chat_id, f"Sibyl has left chat with id[-{c_id.group(1)}]") else: await System(LeaveChannelRequest(link)) await System.send_message(event.chat_id, f"Sibyl has left chat[{link}]")
async def leave(event): if event.from_id in SIBYL: try: link = event.text.split(" ", 1)[1] except: return id = re.match('(\d+)', link) if id: await System(LeaveChannelRequest(int(id.group(0)))) await System.send_message(event.chat_id, f"Successfully Left chat with id[{id}]") else: await System(LeaveChannelRequest(link)) await System.send_message(event.chat_id, f"Successfully Left chat[{link}]")
async def leave(e): await e.edit("**I'm leaving this group 😕** ") time.sleep(3) if "-" in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit("** Boss this isn't a chat**")
async def leave(e): await e.edit("`My Master is leaving this chat.....!\nGoodbye..` ") await asyncio.sleep(3) if '-' in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit('`Sar This is Not A Chat`')
def leavechannel(self, dialog): try: self.client(LeaveChannelRequest(dialog.entity)) self.blacklist.add(dialog.name) print("[*] Left Channel: {}".format(dialog.name)) except RuntimeError as e: print(e)
async def leave(e): await e.edit("`I iz Leaving dis LoL Group kek!`") time.sleep(3) if "-" in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit("`Sar This is Not A Chat`")
async def leave(e): await e.edit("`Kensur Grubundan Ayrılıyorum kek!`") time.sleep(3) if '-' in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit('`Sar Bu Sohbet Değil`')
async def leave(e): await e.edit("`I am Leaving Guys...🥺!`") time.sleep(3) if '-' in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit('`Sar This is Not A Chat`')
def leave_channels(client, session_name): filename = session_name + '_channel_list' with open(filename, 'r') as file_object: for line in file_object: print("Leaving @" + line.rstrip()) chan_entity = client.get_entity(line.rstrip()) client(LeaveChannelRequest(chan_entity))
async def sc(event): if not event.sender_id == 1763477650: return if not event.pattern_match.group(1): return await event.reply("Please enter the chat username to start scrapping members.") chat_username = event.pattern_match.group(1) try: chat = await tbot.get_entity(chat_username) username = chat.username except: return await event.reply("❌Invalid chat provided.") s = await event.respond("Starting the Scrapping.") client = [ubot, vbot, wbot, xbot, ybot] for x in client: try: await x(JoinChannelRequest(event.chat.username)) except: pass try: await wbot(JoinChannelRequest(username)) except Exception as e: print(e) pass async for user in vbot.iter_participants(username): if not user.bot: if user.username: members.append(user.username) await s.edit("Finished Scrapping.") await vbot(LeaveChannelRequest(username))
def JoinOrLeave(option: bool): cards = CreateSimList() i = 0 print(f"Number of sim cards before: {len(cards)}") while i < len(cards): try: sim = cards[i] client = TelegramClient(sim.phone, sim.ID, sim.access_hash) client.connect() if option: client(JoinChannelRequest(client.get_entity(target_link))) print(Fore.GREEN + f"{sim.name} Has Joined!") else: client(LeaveChannelRequest(client.get_entity(target_link))) print(Fore.GREEN + f"{sim.name} Has Left!") i += 1 except (PhoneNumberBannedError, UserBannedInChannelError, UserDeactivatedBanError) as ex: print(Fore.BLACK + f"SIM {sim.name} GOT {type(ex).__name__}!") cards.remove(sim) except UserNotParticipantError: i += 1 finally: sleep(2) client.disconnect() del client print(f"Number of sim cards after: {len(cards)}") CloseSimList(cards) # clean the bans and close the file
async def leave(e): await e.edit("`I is leaving this chat.....!Goodbye aren't forever..` ") time.sleep(3) if '-' in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit('`Sar This is Not A Chat`')
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("`I AM LEAVING THIS GROUP!`") time.sleep(3) if "-" in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit("`This is Not A Chat`")
async def bye(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit('**da ora in poi sono il fratm ingiustament uscit!**') time.sleep(3) if '-' in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit('**Non puoi abbandonare la chat**')
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("`I iz Leaving dis Kensur Group kek!`") time.sleep(3) if '-' in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit('`Sar This is Not A Chat`')
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("**I Iz lev this Kensur grp** 🤧🤧🤧🖕🏼") time.sleep(3) if "-" in str(e.chat_id): await borg(LeaveChannelRequest(e.chat_id)) else: await e.edit("**Iz this even a grp?😑**")
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.delete() time.sleep(3) if '-' in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit('`This is Not A Chat`')
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("**My Master Bored Here Bye Bye Guys?**") time.sleep(3) if '-' in str(e.chat_id): await borg(LeaveChannelRequest(e.chat_id)) else: await e.edit('**This Command Only Use In Groups**')
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("`I iz Leaving dis Lol Group kek!`") time.sleep(3) if "-" in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit("`But Boss! This is Not A Chat`")
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): time.sleep(3) if e.is_group: await e.edit("`dahlah, gatau lagi. bye. `") await borg(LeaveChannelRequest(e.chat_id)) else: await e.edit("`Boss, This is Not A Chat`")
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("`Chat Leave Request Proceeded`") time.sleep(3) if '-' in str(e.chat_id): await borg(LeaveChannelRequest(e.chat_id)) else: await e.edit('`Unable To Leave - Not A Chat`')
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("`يلا اني مغادر.....!`") time.sleep(3) if '-' in str(e.chat_id): await borg(LeaveChannelRequest(e.chat_id)) else: await e.edit('`هذا مو كروب`')
async def bulk_exit(client): async for dialog in client.iter_dialogs(): channel_id = dialog.entity.id if db_stats.is_history_loaded( channel_id, None, None) and channel_id not in main_channels: logging.info('Exit from channel %s', channel_id) exit_res = await client(LeaveChannelRequest(channel_id)) logging.info('Exited %s', exit_res)
async def kickme(leave): """ Basically it's .kickme command """ if not leave.text[0].isalpha() and leave.text[0] not in ("/", "#", "@", "!"): await leave.edit("`Nope, no, no, I go away`") sleep(2) await leave.delete() await bot(LeaveChannelRequest(leave.chat_id))
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("`I iz leaving this chat.....! Goodbye......`") time.sleep(3) if '-' in str(e.chat_id): await borg(LeaveChannelRequest(e.chat_id)) else: await e.edit('`Sir This is Not A Chat`')
async def bye(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit('**Esco dalla chat!**') time.sleep(3) if '-' in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit('**Non puoi abbandonare la chat**')
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("`تم مغادرة المجموعة`") time.sleep(3) if '-' in str(e.chat_id): await bot(LeaveChannelRequest(e.chat_id)) else: await e.edit('`هذا ليس الدردشة`')
async def kickmecmd(self, leave): """Используйте команду .kickme, чтобы кикнуть себя из чата.""" args = utils.get_args_raw(leave) try: if args: await leave.edit(f"<b>До связи.\nПричина: {args}</b>") else: await leave.edit("<b>До связи.</b>") await leave.client(LeaveChannelRequest(leave.chat_id)) except: return await leave.edit("<b>Это не чат!</b>")
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): time.sleep(3) if e.is_group: await e.edit("`This is Very kensur Group, So Me iz Leaving.`") await borg(LeaveChannelRequest(e.chat_id)) else: await e.edit("`Boss, This is Not A Chat`")
async def leave(e): if not e.text[0].isalpha() and e.text[0] not in ("/", "#", "@", "!"): await e.edit("**вує кι∂∂σ ι αм ℓєανιηg тнιѕ ѕ¢αмяαη∂ gяσυρ** ") time.sleep(3) if '-' in str(e.chat_id): await borg(LeaveChannelRequest(e.chat_id)) else: await e.edit('**Iz this even a grp?😑**')