Example #1
0
async def _(event):
    if event.fwd_from:
        return
    if not event.reply_to_msg_id:
        await event.reply("```Reply to any user message.```")
        return
    reply_message = await event.get_reply_message()
    chat = "@QuotLyBot"
    reply_message.sender
    if reply_message.sender.bot:
        await event.reply("```Reply to actual users message.```")
        return
    await event.reply("```Making a Quote```")
    async with ubot.conversation(chat) as conv:
        try:
            response = conv.wait_event(
                events.NewMessage(incoming=True, from_users=1031952739)
            )
            await ubot.forward_messages(chat, reply_message)
            response = await response
        except YouBlockedUserError:
            await event.reply("```Please unblock @QuotLyBot and try again```")
            return
        if response.text.startswith("Hi!"):
            await event.reply(
                "```Can you kindly disable your forward privacy settings for good?```"
            )
        else:
            await ubot.forward_messages(event.chat_id, response.message)
Example #2
0
async def alive(event):
    if event.is_group and not await is_register_admin(event.input_chat,
                                                      event.message.sender_id):
        return
    sender = await event.get_sender()
    fname = sender.first_name
    m = await event.reply("Generating CC...Pls Weit.")
    ok = event.pattern_match.group(1)
    async with ubot.conversation("@ccgen_robot") as bot_conv:
        await bot_conv.send_message("/generate")
        await bot_conv.send_message("💳Credit Card Generator💳")
        await asyncio.sleep(2)
        await bot_conv.send_message(ok)
        await asyncio.sleep(1)
        response = await bot_conv.get_response()
        await asyncio.sleep(1)
        await response.click(text="✅Generate✅")
        await asyncio.sleep(2)
        text = "****Generated Cards:****\n"
        gen = await bot_conv.get_response()
        card = gen.text
        text = f"{card.splitlines()[0]}\n"
        text += f"{card.splitlines()[1]}\n"
        text += f"{card.splitlines()[2]}\n"
        text += f"{card.splitlines()[3]}\n"
        text += f"{card.splitlines()[4]}\n"
        text += f"{card.splitlines()[5]}\n"
        text += f"\nGenerated By: **{fname}**"
        await m.edit(text)
Example #3
0
async def alive(event):
    if event.is_group and not await is_register_admin(event.input_chat,
                                                      event.message.sender_id):
        return
    sender = await event.get_sender()
    fname = sender.first_name
    k = await event.reply("**Wait for Result.**")
    ok = event.pattern_match.group(1)
    async with ubot.conversation("@Carol5_bot") as bot_conv:
        await bot_conv.send_message(f"/bin {ok}")
        await asyncio.sleep(5)
        response = await bot_conv.get_response()
        res = response.text
        if "❌" in res:
            text = "🤬❌ INVALID BIN ❌🤬\n"
        else:
            text = f"{res.splitlines()[0]}\n"
            text += f"{res.splitlines()[1]}\n"
            text += f"{res.splitlines()[2]}\n"
            text += f"{res.splitlines()[3]}\n"
            text += f"{res.splitlines()[4]}\n"
            text += f"{res.splitlines()[5]}\n"
            text += f"{res.splitlines()[6]}\n"

        text += f"Checked By **{fname}**"
        await k.edit(text)
Example #4
0
async def alive(event):
    if event.is_group and not await is_register_admin(event.input_chat,
                                                      event.message.sender_id):
        return
    sender = await event.get_sender()
    fname = sender.first_name
    ok = event.pattern_match.group(1)
    async with ubot.conversation("@Carol5_bot") as bot_conv:
        await bot_conv.send_message(f"/au {ok}")
        k = await event.reply("**Wait for Result.**")
        await asyncio.sleep(18)
        response = await bot_conv.get_response()
        if "Try again after" in response.text:
            await event.reply(response)
            return
        if "Your date is invalid" in response.text:
            await event.reply("Format Wrong or invalid cc.")
            return
        res = response.text
        text = f"{res.splitlines()[0]}\n"
        text += f"{res.splitlines()[1]}\n"
        text += f"{res.splitlines()[2]}\n"
        text += f"{res.splitlines()[3]}\n"
        text += f"{res.splitlines()[4]}\n"
        text += f"{res.splitlines()[5]}\n"
        text += f"{res.splitlines()[6]}\n"
        text += f"Checked By **{fname}**"
        await k.edit(text)
Example #5
0
async def _(event):

    if event.fwd_from:

        return

    if event.is_group:
        if await is_register_admin(event.input_chat, event.message.sender_id):
            pass
        else:
            return
    if not event.reply_to_msg_id:

        await event.reply("```Reply to any user message.```")

        return

    reply_message = await event.get_reply_message()

    if not reply_message.text:

        await event.reply("```reply to text message```")

        return

    chat = "@DetectiveInfoBot"
    uid = reply_message.sender_id
    reply_message.sender

    if reply_message.sender.bot:

        await event.edit("```Reply to actual users message.```")

        return

    lol = await event.reply("```Processing```")

    async with ubot.conversation(chat) as conv:

        try:

            # response = conv.wait_event(
            #   events.NewMessage(incoming=True, from_users=1706537835)
            # )

            await silently_send_message(conv, f"/detect_id {uid}")

            # response = await response
            responses = await silently_send_message(conv, f"/detect_id {uid}")
        except YouBlockedUserError:

            await event.reply(
                "```Please unblock @DetectiveInfoBot and try again```")

            return
        await lol.edit(f"{responses.text}")
Example #6
0
async def alive(event):
    if event.is_group and not await is_register_admin(event.input_chat,
                                                      event.message.sender_id):
        return
    sender = await event.get_sender()
    fname = sender.first_name
    ok = event.pattern_match.group(1)
    k = await event.reply("**Wait for Result.**")
    start_time = datetime.datetime.now()
    async with ubot.conversation("@Carol5_bot") as bot_conv:
        await bot_conv.send_message(f"/key {ok}")
        await asyncio.sleep(6)
        response = await bot_conv.get_response()
        await event.delete()
        end_time = datetime.datetime.now()
        pingtime = end_time - start_time
        time = str(round(pingtime.total_seconds(), 2)) + "s"
        if "Invalid" in response.text:
            reply = f"SK Key : {ok}\n"
            reply += "Result: Invalid API Key\n"
            reply += "RESPONSE: ❌Invalid Key❌\n"
            reply += f"Time: {time}\n"
            reply += f"Checked By **{fname}**"
        elif "Test" in response.text:
            reply = 'SK Key : sk_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n'
            reply += "Result: Test mode Key\n"
            reply += "RESPONSE: ❌Test Mode Key❌\n"
            reply += f"Time: {time}\n"
            reply += f"Checked By **{fname}**"
        elif "Valid" in response.text:
            reply = 'SK Key : sk_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n'
            reply += "Result: LIVE\n"
            reply += "RESPONSE: ✅Valid Key\n"
            reply += f"Time: {time}\n"
            reply += f"Checked By **{fname}**"
        else:
            reply = "Error, Report @LunaBotSupport"
        await k.edit(reply)
Example #7
0
async def _(event):
    try:
        if not event.is_reply:
            await event.reply(
                "Reply to a sticker to remove it from your personal sticker pack."
            )
            return
        reply_message = await event.get_reply_message()
        kanga = await event.reply("`Deleting .`")

        if not is_message_image(reply_message):
            await kanga.edit("Please reply to a sticker.")
            return

        rmsticker = await ubot.get_messages(event.chat_id,
                                            ids=reply_message.id)

        stickerset_attr_s = reply_message.document.attributes
        stickerset_attr = find_instance(stickerset_attr_s,
                                        DocumentAttributeSticker)
        if not stickerset_attr.stickerset:
            await event.reply("Sticker does not belong to a pack.")
            return

        get_stickerset = await tbot(
            GetStickerSetRequest(
                InputStickerSetID(
                    id=stickerset_attr.stickerset.id,
                    access_hash=stickerset_attr.stickerset.access_hash,
                )))

        packname = get_stickerset.set.short_name

        sresult = (await ubot(
            functions.messages.GetStickerSetRequest(
                InputStickerSetShortName(packname)))).documents
        for c in sresult:
            if int(c.id) != int(stickerset_attr.stickerset.id):
                await kanga.edit(
                    "This sticker is already removed from your personal sticker pack."
                )
                return

        await kanga.edit("`Deleting ..`")

        async with ubot.conversation("@Stickers") as bot_conv:

            await silently_send_message(bot_conv, "/cancel")
            response = await silently_send_message(bot_conv, "/delsticker")
            if "Choose" not in response.text:
                await tbot.edit_message(
                    kanga, f"**FAILED**! @Stickers replied: {response.text}")
                return
            response = await silently_send_message(bot_conv, packname)
            if not response.text.startswith("Please"):
                await tbot.edit_message(
                    kanga, f"**FAILED**! @Stickers replied: {response.text}")
                return
            try:
                await rmsticker.forward_to("@Stickers")
            except Exception as e:
                print(e)
            if response.text.startswith("This pack has only"):
                await silently_send_message(bot_conv, "Delete anyway")

            await kanga.edit("`Deleting ...`")
            response = await bot_conv.get_response()
            if "I have deleted" not in response.text:
                await tbot.edit_message(
                    kanga, f"**FAILED**! @Stickers replied: {response.text}")
                return

            await kanga.edit(
                "Successfully deleted that sticker from your personal pack.")
    except Exception as e:
        os.remove("sticker.webp")
        print(e)
Example #8
0
async def _(event):
    if not event.is_reply:
        await event.reply(
            "PLease, Reply To A Sticker / Image To Add It Your Pack")
        return
    reply_message = await event.get_reply_message()
    sticker_emoji = await get_sticker_emoji(event)
    input_str = event.pattern_match.group(1)
    if input_str:
        sticker_emoji = input_str
    user = await event.get_sender()
    if not user.first_name:
        user.first_name = user.id
    pack = 1
    userid = event.sender_id
    first_name = user.first_name
    packname = f"{first_name}'s Sticker Vol.{pack}"
    packshortname = f"DaisyX_stickers_{userid}"
    kanga = await event.reply(
        "Hello, This Sticker Looks Noice. Mind if Daisy steal it")
    is_a_s = is_it_animated_sticker(reply_message)
    file_ext_ns_ion = "Stickers.png"
    file = await event.client.download_file(reply_message.media)
    uploaded_sticker = None
    if is_a_s:
        file_ext_ns_ion = "AnimatedSticker.tgs"
        uploaded_sticker = await ubot.upload_file(file,
                                                  file_name=file_ext_ns_ion)
        packname = f"{first_name}'s Animated Sticker Vol.{pack}"
        packshortname = f"DaisyX_animated_{userid}"
    elif not is_message_image(reply_message):
        await kanga.edit("Oh no.. This Message type is invalid")
        return
    else:
        with BytesIO(file) as mem_file, BytesIO() as sticker:
            resize_image(mem_file, sticker)
            sticker.seek(0)
            uploaded_sticker = await ubot.upload_file(
                sticker, file_name=file_ext_ns_ion)

    await kanga.edit("This Sticker is Gonna Get Stolen.....")

    async with ubot.conversation("@Stickers") as d_conv:
        now = datetime.datetime.now()
        dt = now + datetime.timedelta(minutes=1)
        if not await stickerset_exists(d_conv, packshortname):

            await silently_send_message(d_conv, "/cancel")
            if is_a_s:
                response = await silently_send_message(d_conv, "/newanimated")
            else:
                response = await silently_send_message(d_conv, "/newpack")
            if "Yay!" not in response.text:
                await tbot.edit_message(
                    kanga, f"**Error**! @Stickers replied: {response.text}")
                return
            response = await silently_send_message(d_conv, packname)
            if not response.text.startswith("Alright!"):
                await tbot.edit_message(
                    kanga, f"**Error**! @Stickers replied: {response.text}")
                return
            w = await d_conv.send_file(file=uploaded_sticker,
                                       allow_cache=False,
                                       force_document=True)
            response = await d_conv.get_response()
            if "Sorry" in response.text:
                await tbot.edit_message(
                    kanga, f"**Error**! @Stickers replied: {response.text}")
                return
            await silently_send_message(d_conv, sticker_emoji)
            await silently_send_message(d_conv, "/publish")
            response = await silently_send_message(d_conv, f"<{packname}>")
            await silently_send_message(d_conv, "/skip")
            response = await silently_send_message(d_conv, packshortname)
            if response.text == "Sorry, this short name is already taken.":
                await tbot.edit_message(
                    kanga, f"**Error**! @Stickers replied: {response.text}")
                return
        else:
            await silently_send_message(d_conv, "/cancel")
            await silently_send_message(d_conv, "/addsticker")
            await silently_send_message(d_conv, packshortname)
            await d_conv.send_file(file=uploaded_sticker,
                                   allow_cache=False,
                                   force_document=True)
            response = await d_conv.get_response()
            if response.text == FILLED_UP_DADDY:
                while response.text == FILLED_UP_DADDY:
                    pack += 1
                    prevv = int(pack) - 1
                    packname = f"{first_name}'s Sticker Vol.{pack}"
                    packshortname = f"Vol_{pack}_with_{userid}"

                    if not await stickerset_exists(d_conv, packshortname):
                        await tbot.edit_message(
                            kanga,
                            "**Pack No. **" + str(prevv) +
                            "** is full! Making a new Pack, Vol. **" +
                            str(pack),
                        )
                        if is_a_s:
                            response = await silently_send_message(
                                d_conv, "/newanimated")
                        else:
                            response = await silently_send_message(
                                d_conv, "/newpack")
                        if "Yay!" not in response.text:
                            await tbot.edit_message(
                                kanga,
                                f"**Error**! @Stickers replied: {response.text}"
                            )
                            return
                        response = await silently_send_message(
                            d_conv, packname)
                        if not response.text.startswith("Alright!"):
                            await tbot.edit_message(
                                kanga,
                                f"**Error**! @Stickers replied: {response.text}"
                            )
                            return
                        w = await d_conv.send_file(
                            file=uploaded_sticker,
                            allow_cache=False,
                            force_document=True,
                        )
                        response = await d_conv.get_response()
                        if "Sorry" in response.text:
                            await tbot.edit_message(
                                kanga,
                                f"**Error**! @Stickers replied: {response.text}"
                            )
                            return
                        await silently_send_message(d_conv, sticker_emoji)
                        await silently_send_message(d_conv, "/publish")
                        response = await silently_send_message(
                            bot_conv, f"<{packname}>")
                        await silently_send_message(d_conv, "/skip")
                        response = await silently_send_message(
                            d_conv, packshortname)
                        if response.text == "Sorry, this short name is already taken.":
                            await tbot.edit_message(
                                kanga,
                                f"**Error**! @Stickers replied: {response.text}"
                            )
                            return
                    else:
                        await tbot.edit_message(
                            kanga,
                            "**Pack No. **" + str(prevv) +
                            "** is full! Switching to Vol. **" + str(pack),
                        )
                        await silently_send_message(d_conv, "/addsticker")
                        await silently_send_message(d_conv, packshortname)
                        await d_conv.send_file(
                            file=uploaded_sticker,
                            allow_cache=False,
                            force_document=True,
                        )
                        response = await d_conv.get_response()
                        if "Sorry" in response.text:
                            await tbot.edit_message(
                                kanga,
                                f"**Error**! @Stickers replied: {response.text}"
                            )
                            return
                        await silently_send_message(d_conv, sticker_emoji)
                        await silently_send_message(d_conv, "/done")
            else:
                if "Sorry" in response.text:
                    await tbot.edit_message(
                        kanga,
                        f"**Error**! @Stickers replied: {response.text}")
                    return
                await silently_send_message(d_conv, response)
                await silently_send_message(d_conv, sticker_emoji)
                await silently_send_message(d_conv, "/done")
    await kanga.edit("Inviting This Sticker To Your Pack 🚶")
    await kanga.edit(
        f"This Sticker Has Came To Your Pack.` \n**Check It Out** [Here](t.me/addstickers/{packshortname})"
    )
    os.system("rm -rf  Stickers.png")
    os.system("rm -rf  AnimatedSticker.tgs")
    os.system("rm -rf *.webp")