Skip to content

Instantly share code, notes, and snippets.

View rajeshsaini2115's full-sized avatar
💭
Busy in hacking

Rajesh Saini rajeshsaini2115

💭
Busy in hacking
View GitHub Profile
@nuhmanpk
nuhmanpk / ForceSub.py
Last active September 7, 2023 04:09
Add Force Subscribe To Your Bot
import pyrogram
from pyrogram import Client, filters
from pyrogram.types import InlineKeyboardMarkup, InlineKeyboardButton
from pyrogram.types import User, Message
from pyrogram.errors import UserNotParticipant
UPDATE_CHANNEL= "channel name without '@'"
# Follow me on Github - Github.com/nuhmanpk
# Join @BugHunterBots for more
@nuhmanpk
nuhmanpk / broadcast.py
Last active March 17, 2022 13:44
Broadcasting in Bots Pyrogram
from userbase import present_in_userbase, add_to_userbase, get_users # userbase.py is Attached below
import time
@bughunter0.on_message(filters.private & filters.command('broadcast') & filters.user(OWNER) & filters.reply)
async def broadcast(client: bughunter0, message: Message):
broadcast_msg = message.reply_to_message
txt = await message.reply(text = 'Staring....')
user_ids = await get_users()
success = 0
deleted = 0