File size: 2,346 Bytes
72d5093 e9f1b12 a5119b3 8b01779 72d5093 |
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 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 |
from config import PRIVATE_GROUP_ID
from pyrogram import Client, filters
from datetime import datetime as dt
from pyrogram.types import (
Message,
ReplyKeyboardMarkup,
ReplyKeyboardRemove,
KeyboardButton,
InlineKeyboardMarkup,
InlineKeyboardButton
)
force_reply = ReplyKeyboardMarkup(
[
[KeyboardButton("Create Detection", request_contact=True), KeyboardButton("Show Sessions")],
[KeyboardButton("Start Sessions"), KeyboardButton("My Delete All")],
[KeyboardButton("My Info")],
[KeyboardButton("Cancel")]
],
resize_keyboard=True,
one_time_keyboard=True
)
@Client.on_message(
filters.private
& filters.regex(r"^Cancel$")
)
async def robot(client: Client, message: Message):
await message.reply_text(
"β **Cancelled**\n\n"
"You can start over by sending your contact again.",
reply_markup=ReplyKeyboardRemove()
)
@Client.on_message(
filters.private
& filters.command("freedeploy")
)
async def show_menu(client, message):
await client.send_message(
message.chat.id,
text="You can deploy your own version of the Auto Detection Lite Bot for free!\n\n",
reply_markup=force_reply
)
@Client.on_message(filters.command("start") & filters.private)
async def start_command(client: Client, message: Message):
welcome_msg = (
"π **Welcome to Auto Detection Lite Bot**\n\n"
"π _Your personal guard for detecting silent bans and unbans on Telegram._\n\n"
"β¨ **Features:**\n"
"β’ π Real-time Ban & Unban Detection\n"
"β’ π₯ Multi-Account Session Support\n"
"β’ π© Instant Notifications Without Any Commands\n"
"β’ βΎοΈ Lifetime Free Access\n\n"
"π‘ Use `/freedeploy` to deploy your own version for free!"
)
await message.reply_text(
welcome_msg,
reply_markup=InlineKeyboardMarkup([
[InlineKeyboardButton("π’ Official Channel", url="https://t.me/RendyProjects")]
])
)
log_msg = (
f"π₯ **Detection: New User Started Bot**\n\n"
f"π€ User: {message.from_user.mention}\n"
f"π ID: `{message.from_user.id}`\n"
f"π Date: `{dt.now().strftime('%Y-%m-%d %H:%M')}`"
)
await client.send_message(PRIVATE_GROUP_ID, log_msg) |