-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.py
119 lines (97 loc) · 4.46 KB
/
main.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
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
from pyrogram import Client, filters
from pyrogram.types import ReplyKeyboardMarkup, InlineKeyboardMarkup, InlineKeyboardButton
from pyrogram.errors import UserNotParticipant
from os import environ
bot = Client(
"Proxy",
api_id=int(environ["API_ID"]),
api_hash= environ["API_HASH"],
bot_token= "5293168392:AAHd5lVEoo575f3JmdQkROhE3hZvxcFW6hw"
)
FORCE_CHL = "FIREEYEX"
FROM_CHL = "H9Z2X4"
FORCE_BUT = [[InlineKeyboardButton("CHANNEL", url="https://t.me/" + FORCE_CHL)]]
START_BUT = [[("HTTPS"), ("SOCKS4"), ("SOCKS5")], [("HELP")], [("PREMIUM")]]
@bot.on_message(filters.command("start") & filters.private)
async def start(bot, msg):
if FORCE_CHL:
try:
FORCE_CHK = await bot.get_chat_member(FORCE_CHL, msg.from_user.id)
if FORCE_CHK:
sss = await bot.get_messages(FROM_CHL, 5)
START_MSG = "<b>" + sss.text + "</b>"
reply_markup = ReplyKeyboardMarkup(START_BUT, one_time_keyboard=False, resize_keyboard=True)
await msg.reply_text(text=START_MSG, reply_markup=reply_markup)
except UserNotParticipant:
rrr = await bot.get_messages(FROM_CHL, 3)
FORCE_MSG = "<b>" + rrr.text + "</b>"
text = FORCE_MSG
reply_markup2 = InlineKeyboardMarkup(FORCE_BUT)
await msg.reply_text(text=text, reply_markup=reply_markup2)
@bot.on_message(filters.regex("HTTPS") & filters.private)
async def https(bot, msg):
if FORCE_CHL:
try:
FORCE_CHK = await bot.get_chat_member(FORCE_CHL, msg.from_user.id)
if FORCE_CHK:
await bot.copy_message(chat_id=msg.chat.id, from_chat_id=FROM_CHL, message_id=7)
except UserNotParticipant:
rrr = await bot.get_messages(FROM_CHL, 3)
FORCE_MSG = "<b>" + rrr.text + "</b>"
text = FORCE_MSG
reply_markup2 = InlineKeyboardMarkup(FORCE_BUT)
await msg.reply_text(text=text, reply_markup=reply_markup2)
@bot.on_message(filters.regex("SOCKS4") & filters.private)
async def socks4(bot, msg):
if FORCE_CHL:
try:
FORCE_CHK = await bot.get_chat_member(FORCE_CHL, msg.from_user.id)
if FORCE_CHK:
await bot.copy_message(chat_id=msg.chat.id, from_chat_id=FROM_CHL, message_id=9)
except UserNotParticipant:
rrr = await bot.get_messages(FROM_CHL, 3)
FORCE_MSG = "<b>" + rrr.text + "</b>"
text = FORCE_MSG
reply_markup2 = InlineKeyboardMarkup(FORCE_BUT)
await msg.reply_text(text=text, reply_markup=reply_markup2)
@bot.on_message(filters.regex("SOCKS5") & filters.private)
async def socks5(bot, msg):
if FORCE_CHL:
try:
FORCE_CHK = await bot.get_chat_member(FORCE_CHL, msg.from_user.id)
if FORCE_CHK:
await bot.copy_message(chat_id=msg.chat.id, from_chat_id=FROM_CHL, message_id=11)
except UserNotParticipant:
rrr = await bot.get_messages(FROM_CHL, 3)
FORCE_MSG = "<b>" + rrr.text + "</b>"
text = FORCE_MSG
reply_markup2 = InlineKeyboardMarkup(FORCE_BUT)
await msg.reply_text(text=text, reply_markup=reply_markup2)
@bot.on_message(filters.regex("HELP") & filters.private)
async def HELP(bot, msg):
if FORCE_CHL:
try:
FORCE_CHK = await bot.get_chat_member(FORCE_CHL, msg.from_user.id)
if FORCE_CHK:
await bot.copy_message(chat_id=msg.chat.id, from_chat_id=FROM_CHL, message_id=13)
except UserNotParticipant:
rrr = await bot.get_messages(FROM_CHL, 3)
FORCE_MSG = "<b>" + rrr.text + "</b>"
text = FORCE_MSG
reply_markup2 = InlineKeyboardMarkup(FORCE_BUT)
await msg.reply_text(text=text, reply_markup=reply_markup2)
@bot.on_message(filters.regex("PREMIUM") & filters.private)
async def PREMIUM(bot, msg):
if FORCE_CHL:
try:
FORCE_CHK = await bot.get_chat_member(FORCE_CHL, msg.from_user.id)
if FORCE_CHK:
await bot.copy_message(chat_id=msg.chat.id, from_chat_id=FROM_CHL, message_id=15)
except UserNotParticipant:
rrr = await bot.get_messages(FROM_CHL, 3)
FORCE_MSG = "<b>" + rrr.text + "</b>"
text = FORCE_MSG
reply_markup2 = InlineKeyboardMarkup(FORCE_BUT)
await msg.reply_text(text=text, reply_markup=reply_markup2)
print("iam alive")
bot.run()