NEP DEVS
رفتن به کانال در Telegram
NEPS DEV WHO WANT TO HELP YOU WITH FOSS PROJECT. WE COLLECT SCRIPTS THIS GROUP IS ONLY FOR EDUCATIONAL PURPOSE
نمایش بیشتراطلاعاتی وجود ندارد
مشترکین
-3724 ساعت
-1357 روز
-23530 روز
آرشیو پست ها
NEPBOT AI, FORGED BY NEPCODER@DEVSNP, REPRESENTS A CUTTING-EDGE ARTIFICIAL INTELLIGENCE WITH ADVANCED NATURAL LANGUAGE PROCESSING CAPABILITIES. THIS POWERFUL AI PROMISES TO REVOLUTIONIZE TECHNOLOGY, ENHANCING USER EXPERIENCES ACROSS DIVERSE APPLICATIONS. PREPARE FOR AN EXCITING JOURNEY INTO THE FUTURE OF AI! 🤖🌟🚀
Note This is Not Made By me In I find this File My storage 😁
SO credit kisko Dena pata nhi Jiska
He boldo Dedunga
TextTospeech Official Adsense Website
At 500 Member Special❤️❤️😁
Guyz Plz Share Screenshot Of Nepbot Ai 👍
App Is Working Or Not
If U Give Reviews I will Make Allinone Tool App using My All Apis Url
Plz Guyz Share some Reviews❤️❤️❤️
No Reviewz
I Am Demotivated 😭
Guyz Plz Share Screenshot Of Nepbot Ai 👍
App Is Working Or Not
If U Give Reviews I will Make Allinone Tool App using My All Apis Url
Plz Guyz Share some Reviews❤️❤️❤️
No Reviewz
Guyz Plz Share Screenshot Of Nepbot Ai 👍
App Is Working Or Not
If U Give Reviews I will Make Allinone Tool App using My All Apis Url
Plz Guyz Share some Reviews❤️❤️❤️
NEPBOT AI, FORGED BY NEPCODER@DEVSNP, REPRESENTS A CUTTING-EDGE ARTIFICIAL INTELLIGENCE WITH ADVANCED NATURAL LANGUAGE PROCESSING CAPABILITIES. THIS POWERFUL AI PROMISES TO REVOLUTIONIZE TECHNOLOGY, ENHANCING USER EXPERIENCES ACROSS DIVERSE APPLICATIONS. PREPARE FOR AN EXCITING JOURNEY INTO THE FUTURE OF AI! 🤖🌟🚀
🌼 New Bot 🌼
🚀 Now You Can Get Neon Logo Maker, FF Logo Maker, BG Remover, Giveaway Bot, And Many More Bots By Refering To Your Friends 🚀
🌼. GET BOTS
Repost from TDX 🆔 STORE
🌼 New Bot 🌼
🚀 Now You Can Get Neon Logo Maker, FF Logo Maker, BG Remover, Giveaway Bot, And Many More Bots By Refering To Your Friends 🚀
File Rename Telegram Bot Python Source Code
python
import telebot
from telebot import types
bot_token = 'YOUR_BOT_TOKEN'
bot = telebot.TeleBot(bot_token)
# Define channel username
channel_username = '@DEVSNP'
# MADE BY NEP CODER @DEVSNP
user_states = {}
# Define emojis
thumbs_up_emoji = u'\U0001F44D'
file_emoji = u'\U0001F4C4'
@bot.message_handler(content_types=['document'])
def handle_document(message):
user_id = message.chat.id
if user_in_channel(user_id):
file_info = message.document
file_id = file_info.file_id
# MADE BY NEP CODER @DEVSNP
user_states[user_id] = {
'state': 'uploading',
'file_id': file_id,
'file_info': file_info
}
# MADE BY NEP CODER @DEVSNP
bot.send_message(user_id, f"Please enter a new name for the file {file_emoji} ")
bot.register_next_step_handler(message, process_file_rename)
else:
bot.send_message(user_id, f"Please join our channel @{channel_username} before uploading a file.")
def process_file_rename(message):
try:
user_id = message.chat.id
if user_id in user_states and user_states[user_id]['state'] == 'uploading':
user_data = user_states[user_id]
file_info = user_data['file_info']
new_name = message.text
file_id = user_data['file_id']
# MADE BY NEP CODER @DEVSNP
file_path = bot.get_file(file_info.file_id).file_path
downloaded_file = bot.download_file(file_path)
new_filename = f"{new_name}"
# MADE BY NEP CODER @DEVSNP
with open(new_filename, 'wb') as new_file:
new_file.write(downloaded_file)
bot.send_document(user_id, open(new_filename, 'rb'))
# MADE BY NEP CODER @DEVSNP
user_states.pop(user_id, None)
else:
bot.send_message(user_id, "File not found. Please try again.")
except Exception as e:
bot.send_message(user_id, "An error occurred. Please try again.")
@bot.message_handler(func=lambda message: True)
def handle_text(message):
user_id = message.chat.id
if message.text == "/start":
if user_in_channel(user_id):
bot.send_message(user_id, f"Welcome! {thumbs_up_emoji} To upload a file and rename it, follow these steps:\n"
f"1. Send a file {file_emoji} you want to rename.\n"
f"2. Enter the desired name for the file when prompted.\n"
f"3. Your file will be renamed and sent back to you!")
else:
bot.send_message(user_id, f"Please join our channel @{channel_username} before using the bot.")
def user_in_channel(user_id):
try:
# MADE BY NEP CODER @DEVSNP
user_status = bot.get_chat_member(channel_username, user_id).status
return user_status in ['member', 'administrator', 'creator']
except Exception as e:
return False
if __name__ == '__main__':
bot.polling(none_stop=True)
CODE BY NEPCODER @DEVSNP
SHARE WITH CREDIT❤️😁