bot.py
bot.py
import telebot
import requests
import random
import stripe
import braintree
import time
import json
from datetime import datetime, timedelta
from luhn import generate as luhn_generate # pip install luhn
# Bot token
BOT_TOKEN = os.environ.get('BOT_TOKEN') or '7849537941:AAEWfZDwUMKHnH-
scSEXnBRXw2xY99ZFKn0'
bot = telebot.TeleBot(BOT_TOKEN)
gateway = braintree.BraintreeGateway(
braintree.Configuration(
environment=braintree.Environment.Sandbox, # Use Production for live
environment
merchant_id=BRAINTREE_MERCHANT_ID,
public_key=BRAINTREE_PUBLIC_KEY,
private_key=BRAINTREE_PRIVATE_KEY
)
)
# Initialize data
data = load_data()
user_balances = data.get("user_balances", {})
vouchers = data.get("vouchers", {})
usage_stats = data.get("usage_stats", {})
# Admin details
ADMIN_USERNAME = "@bullseller2"
ADMIN_USER_ID = 7725802448
"𝗖𝗢𝗠𝗠𝗔𝗡𝗗 𝗠𝗘𝗡𝗨:",
welcome_msg = format_response("CC KILER BOT", [
@bot.message_handler(commands=['gen'])
def handle_gen(message):
try:
bin = message.text.split()[1]
card_number = generate_valid_card(bin)
if not card_number:
return bot.reply_to(message, "❌ Invalid BIN! Use 6-digit number")
@bot.message_handler(commands=['chk'])
def handle_chk(message):
try:
card_number, mm, yy, cvv = message.text.split()[1].split("|")
bin_data = fetch_bin_details(card_number)
if not bin_data:
return bot.reply_to(message, "❌ BIN lookup failed. Please try again.")
send_country_sticker(message.chat.id, bin_data["country"])
f"𝗕𝗜𝗡: {card_number[:6]}",
response = format_response("Card Analysis", [
except Exception as e:
bot.reply_to(message, f"🔥 ERROR: {str(e)}")
@bot.message_handler(commands=['kill'])
def handle_kill(message):
try:
user_id = message.from_user.id
if user_balances.get(user_id, 0) < 1:
return bot.reply_to(message, f"❌ You need 1 credit to use this command.
Use /buy to purchase credits or contact {ADMIN_USERNAME} (@GrayXhat).")
# Deduct 1 credit
user_balances[user_id] -= 1
save_data({"user_balances": user_balances, "vouchers": vouchers,
"usage_stats": usage_stats})
f"𝗖𝗮𝗿𝗱: {card_number[:6]}******{card_number[-4:]}",
response = format_response("Kill Results", [
except Exception as e:
bot.reply_to(message, f"🔥 ERROR: {str(e)}")
@bot.message_handler(commands=['buy'])
def handle_buy(message):
try:
user_id = message.from_user.id
f"𝗖𝗿𝗲𝗱𝗶𝘁𝘀 𝗣𝗮𝗰𝗸𝗮𝗴𝗲𝘀:",
response = format_response("Buy Credits", [
directly."
])
bot.reply_to(message, response)
except Exception as e:
bot.reply_to(message, f"🔥 ERROR: {str(e)}")
@bot.message_handler(commands=['redeem'])
def handle_redeem(message):
try:
user_id = message.from_user.id
if len(message.text.split()) < 2:
return bot.reply_to(message, "❌ Please provide a voucher code.
Usage: /redeem <voucher>")
voucher = message.text.split()[1]
if voucher not in vouchers:
return bot.reply_to(message, "❌ Invalid voucher code.")
@bot.message_handler(commands=['generate_voucher'])
def handle_generate_voucher(message):
try:
user_id = message.from_user.id
if user_id != ADMIN_USER_ID:
return bot.reply_to(message, "❌ Only the admin can generate vouchers.")
if len(message.text.split()) < 3:
return bot.reply_to(message, "❌ Usage: /generate_voucher <credits>
<expiry_days>")
credits = int(message.text.split()[1])
expiry_days = int(message.text.split()[2])
expiry_time = datetime.now() + timedelta(days=expiry_days)
voucher = f"VOUCHER-{random.randint(100000, 999999)}"
vouchers[voucher] = {"credits": credits, "expiry_time":
expiry_time.isoformat()}
save_data({"user_balances": user_balances, "vouchers": vouchers,
"usage_stats": usage_stats})
bot.reply_to(message, f"✅ Voucher generated: {voucher} (Credits: {credits},
Expiry: {expiry_time.strftime('%Y-%m-%d %H:%M:%S')})")
except Exception as e:
bot.reply_to(message, f"🔥 ERROR: {str(e)}")
@bot.message_handler(commands=['bal'])
def handle_bal(message):
try:
user_id = message.from_user.id
except Exception as e:
bot.reply_to(message, f"🔥 ERROR: {str(e)}")
@bot.message_handler(commands=['admin_stats'])
def handle_admin_stats(message):
try:
user_id = message.from_user.id
if user_id != ADMIN_USER_ID:
return bot.reply_to(message, "❌ Only the admin can access this
command.")