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
🎙 Oxapay Withdrawal Api Bjs Code

❤ Command:- /without

👍🏻 Wait for Answer: On ✅

📖 BJS Code :

let callbackUrl = Libs.Webhooks.getUrlFor({
command: "/on",
user_id: user.id
})
var wallet = User.getProperty("wallet")
var am = message
var api_key = "Payout_apikey"
var currency = "DGB"
HTTP.post({
  url: "https://api.oxapay.com/api/send",
  success: "/suc",
  body: {
    key: api_key,
    amount: am,
address: wallet,
    currency: currency,
callbackUrl: callbackUrl
},
  headers: {
'cache-control': 'no-cache',
"Content-type": "application/json",
"Accept": "application/json"
}
})

❤ Command:- /suc
📖 BJS Code :
if (content) {
var info = JSON.parse(content)
var st = info.status
if (info.result == 100) {
Api.sendMessage({
text:
"*🔁 Withdrawal " +
st +
"\n\n♻️ Wait For Confirm You Withdraw\n\n👇See Log In channel ✅*",
parse_mode: "Markdown",
disable_web_page_previwe: true,
reply_markup: {
inline_keyboard: [
[{ text: "📄 Channel", url: "https://t.me/Privates_Bots" }]
]
}
})
return
}
} else {
Api.sendMessage({
text: "*❌ Error 404*",
parse_mode: "Markdown",
disable_web_page_previwe: true,
reply_markup: {
inline_keyboard: [
[{ text: "📞 Contact Admin", url: "tg://user?id=1789993737" }]
]
}
})
}

❤ Command:- /on
📖 BJS Code :
if (content) {
var data = JSON.parse(content)
var st = data.status
var txid = data.txID
var add = data.address
var am = data.amount
if (data.status == "Confirming") {
var key = "You channel Username"
var but = [
[
{
text: "💵 Earn Now",
url: "https://t.me/" + bot.name + "?start=start"
}
]
]
var tt =
"<b>✅ New Withdrawal By " +
user.first_name +
"\n\n🎟️ Txid</> = <a href='https://digiexplorer.info/tx/" +
txid +
"'>" +
txid +
"</a>\n\n<b>ℹ️ Address = " +
add +
"\n\n🌀 Amount = " +
am +
" DGB\n\n📛 Status = " +
st +
"</>"

Api.sendPhoto({
chat_id: key,
photo: "t.me/" + user.username,
caption: tt,
parse_mode: "html",
disable_web_page_previwe: true,
reply_markup: { inline_keyboard: but }

⚠️ Give credit if you are posting on your channel.
👨‍💻 Created By:
Yᴀɢᴀᴍɪ Sᴛɪʟʟ Lᴇᴀʀɴɪɴɢ
© Credit: @botnations
👍11❤3🔥1
The image editing bot is on the way! 🚀😄
👍21❤4🎉3🔥1
📢 Admin Tagging Bot Code [Bots.Business]

💓 Command: *

🔍 BJS Code:

if (chat.chat_type != "private") {
// Check if the message contains "@admin" anywhere
// This ensures the bot responds if "@admin" is mentioned in the group chat
if (request.text && request.text.toLowerCase().indexOf("@admin") !== -1) {

// If options are not available, fetch the list of group administrators
if (!options) {
Api.getChatAdministrators({
chat_id: request.chat.id,
on_result: "*" // Callback to handle the result of getChatAdministrators
});
} else {
// List of admins obtained from the chat administrators response
let admins = options.result;
let adminList = ""; // Variable to store the formatted list of admins

// Loop through each admin to construct the admin list
for (var ind in admins) {
let admin = admins[ind];
let user = admin.user;

// Skip bot accounts as they are not actual group administrators
if (user.is_bot) continue;

// Add the admin's name as a clickable link to their profile
adminList += `👤 <a href="tg://user?id=${user.id}">${user.first_name || "Admin"}</a>\n`;
}

// If there are valid admins, proceed to send the admin list
if (adminList) {
// Send the admin list message to the group chat
Api.sendMessage({
chat_id: request.chat.id,
text: `👨‍💻 <b>This Group's Admins:</b>\n\n${adminList}`,
parse_mode: "HTML" // Parse the message as HTML for clickable links
});

// Generate a permanent link to the message in the group chat
let messageId = request.message_id;
let chatId = request.chat.id;
let chatLinkId = String(chatId).replace("-100", ""); // Format chat ID for the link
let messageLink = `https://t.me/c/${chatLinkId}/${messageId}`;

// Send the message to each admin in their private chat
for (var ind in admins) {
let admin = admins[ind];
let user = admin.user;

// Skip bot accounts again during private message notification
if (user.is_bot) continue;

// Forward the original message (containing "@admin") to the admin's private chat
Api.forwardMessage({
chat_id: user.id,
from_chat_id: request.chat.id,
message_id: request.message_id
});

// Notify the admin that they were tagged in the group chat
Api.sendMessage({
chat_id: user.id,
text: `📢 <b>You're tagged in a group chat!</b>\n\n👤 <b>User Information:</b>\n
🔹 <b>Name:</b> <a href="tg://user?id=${request.from.id}">${request.from.first_name || "Unknown"}</a>\n
🔹 <b>Username:</b> @${request.from.username || "Not Set"}\n
🔹 <b>User ID:</b> ${request.from.id}`,
parse_mode: "HTML", // Parse the message as HTML for clickable links
reply_markup: {
// Inline keyboard button with a link to the original group message
inline_keyboard: [
[
{
text: "🔗 Go to message",
url: messageLink // URL for the admin to directly open the message
}
]
]
}
});
}
} else {
// Notify the group chat if no valid admins were found
Api.sendMessage({
chat_id: request.chat.id,
text: "🤔 <b>No valid admins found (or only bot admins exist).</b>",
parse_mode: "HTML"
});
}
}
return; // Exit after handling the "@admin" mention
}
}

// Code created by @Privates_Bots
// This code handles tagging admins in group chats when "@admin" is mentioned.
// It notifies all admins with the message details and provides a direct link to the original message.
// © Created and maintained by @Privates_Bots

👨‍💻 Created By: @Swastik_Raj 
© Copyright: @botnations 
📢 Share and give credit if using on your channel!
👍9
📢 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