For developers
Closed channel
The channel is specialized in post Python file Without encryption and free Owner : @g_4_q
Show more2 425
Subscribers
No data24 hours
-187 days
-7030 days
Posts Archive
2 424
api check email aol
https://api-aol-3b869519bd93.herokuapp.com/?email=
api check email gmail
https://check-gmail-43cdb8e63350.herokuapp.com/?email=
2 424
Api get date instagram from id -
import requests
Id = input(" ID INSTA : ")
response = requests.get("https://mel7n.pythonanywhere.com/?id={}".format(Id)).json()
print(response)
print(response['date'])
-BY : @g_4_q2 424
+1
كود تفعيل وايقاف تفعيل بوت على المستخدمين عن طريق ايدي
اذا ما تفعل بوت له مايشتغل
2 424
+1
كود تفعيل وايقاف تفعيل بوت على المستخدمين عن طريق ايدي
اذا ما تفعل بوت له مايشتغل
2 424
import telebot
from telebot import types
token = "توكنك"
bot = telebot.TeleBot(token)
def admins(chat_id, user_id):
try:
admins = bot.get_chat_administrators(chat_id)
for admin in admins:
if admin.user.id == user_id:
return True
except telebot.apihelper.ApiTelegramException as L7:
bot.send_message(chat_id,"{}".format(L7))
return False
@bot.message_handler(content_types=['left_chat_member'])
def handle_member_removed(message):
if message.chat.type in ['channel','group', 'supergroup']:
if message.left_chat_member:
chat_id = message.chat.id
remover_user_id = message.from_user.id
if admins(chat_id, remover_user_id):
bot.promote_chat_member(chat_id, remover_user_id, can_change_info=False, can_post_messages=False,
can_edit_messages=False, can_delete_messages=False, can_invite_users=False,
can_restrict_members=False, can_pin_messages=False, can_promote_members=False)
bot.send_message(chat_id, f"تم إنزال المشرف @{message.from_user.username} بسبب حذف عضو.")
else:
bot.send_message(chat_id, "فقط المشرفين يمكنهم حذف الأعضاء.")
@bot.message_handler(commands=['add_admin'])
def add_admin(message):
if message.chat.type in ['channel','group', 'supergroup']:
chat_id = message.chat.id
args = message.text.split()
if len(args) == 2:
try:
new_admin_id = int(args[1])
if admins(chat_id, message.from_user.id):
# هنا صلاحيات المشرف الي تريد ترفعه
bot.promote_chat_member(chat_id, new_admin_id, can_change_info=True, can_post_messages=True,
can_edit_messages=True, can_delete_messages=True, can_invite_users=True,
can_restrict_members=True, can_pin_messages=True, can_promote_members=True)
bot.send_message(chat_id, "تم إضافة المستخدم ID {} كمشرف.".format(new_admin_id))
else:
bot.send_message(chat_id, "لا يمكنك اضافة مشرف لانك لا تمتلك صلاحيات كافية")
except ValueError:
bot.send_message(chat_id, "عذراً ارسل id صحيح ")
else:
bot.send_message(chat_id, " ارسل امر صحيح مثل : //add_admin + ايدي الشخص")
# BY L7N
bot.polling()