mahdiyar30301/ZorenixAI_botPublic · Bot Template

Not Bot Is Hacking You 🤣🤩

Utilityutility
ProfileTelegram
455 commands2 envUpdated 6h agoCreated Aug 26, 2026
Back to folder

commands/setupdate.js

javascript · 60 lines

Raw
1/**#command2name: setupdate3answer: 4keyboard: 5parse_mode: markdown6aliases: 7allow_only_group: false8need_reply: false9is_web: 010#command**/11 12/**#command13name: setupdate14answer: 15keyboard: 16parse_mode: markdown17aliases: 18allow_only_group: false19need_reply: false20is_web: 021#command**/22 23try {24try { Api.answerCallbackQuery({}); } catch (e0) {}25var uid = "";26if (typeof user !== "undefined" && user) {27  if (user.telegramid) uid = String(user.telegramid);28  else if (user.id) uid = String(user.id);29}30if (uid !== "5861439682") { Bot.sendMessage("فقط رئیس"); return; }31 32var ver = String((await db.global.get("bot_ver")) || "5.0");33var dt = String((await db.global.get("bot_update_date")) || "-");34var n = 0;35try {36  var lg = JSON.parse(String((await db.global.get("bot_update_log")) || "[]"));37  if (lg && typeof lg.length === "number") n = lg.length;38} catch (eL) {}39 40Api.sendMessage({41  text:42    "🚀 مدیریت آپدیت کاربری\n" +43    "نسخه فعلی: " + ver + "\n" +44    "تاریخ: " + dt + "\n" +45    "تعداد بند: " + n + "\n\n" +46    "این متن را کاربر با /update می‌بیند.\n" +47    "ادمین‌پنل داخلش ننویس.\n" +48    "افزودن = به قبلی می‌چسبد، پاک نمی‌شود.",49  reply_markup: {50    inline_keyboard: [51      [{ text: "🔢 زدن نسخه", callback_data: "updver" }],52      [{ text: "➕ افزودن بند جدید", callback_data: "updadd" }],53      [{ text: "👁 پیش‌نمایش کاربر", callback_data: "update" }],54      [{ text: "🛠 پنل", callback_data: "panel" }]55    ]56  }57});58} catch (e) {59  Bot.sendMessage("خطا setupdate");60}