kkapil9112/Aestheticmodes9_botPublic · Bot Template
AIA Telegram-based digital goods store bot with a full admin panel for managing products, plans, stock, keys, categories, resellers, balances, and coupons. It uses TeleBotHost APIs like Bot, Api, User, Libs.ResourcesLib, and HTTP to run a shop interface, handle admin-only commands, track users, and send inventory/balance summaries. The implementation appears focused on selling game-related accounts and keys such as FreeFire items, with customer-facing store, balance, coupon, and back-to-menu flows.
Commerceshopadmin-panelbalanceresellercouponsstock-management
102 commands1 envUpdated 29d agoCreated Aug 9, 2026
commands/_cancel_topup.js
javascript · 61 lines
1/**#command2name: /cancel_topup3answer: 4keyboard: 5parse_mode: markdown6aliases: 7allow_only_group: false8need_reply: false9is_web: 010#command**/11 12try {13 var userId = user.telegramid;14 var callbackId = request ? request.id : (request.callback_query && request.callback_query.id);15 16 var qrMsgId = Bot.getProperty("qr_msg_id_" + userId) || User.getProperty("qr_msg_id_" + userId) || (request.message ? request.message.message_id : null);17 18 if (qrMsgId) {19 try { Api.deleteMessage({ chat_id: chat.chatid, message_id: qrMsgId }); } catch (e) {}20 }21 22 User.setProperty("pending_order_id", null);23 User.setProperty("deposit_amount", "0", "string");24 Bot.setProperty("qr_msg_id_" + userId, null, "string");25 User.setProperty("qr_msg_id_" + userId, null, "string");26 Bot.setProperty("qr_caption_" + userId, null, "string");27 User.setProperty("qr_caption_" + userId, null, "string");28 Bot.setProperty("qr_buttons_" + userId, null, "string");29 User.setProperty("qr_buttons_" + userId, null, "string");30 Bot.setProperty("qr_order_id_" + userId, null, "string");31 User.setProperty("qr_order_id_" + userId, null, "string");32 33 // ✅ Expiry-watcher ko disable karo taaki baad mein galat message edit na ho34 Bot.setProperty("qr_watch_order_" + userId, null, "string");35 User.setProperty("qr_watch_order_" + userId, null, "string");36 Bot.setProperty("verifying_lock_" + userId, false, "boolean");37 User.setProperty("verifying_lock_" + userId, false, "boolean");38 39 var cancelText = "<blockquote>" +40 "<tg-emoji emoji-id='6219547832169273793'>❌</tg-emoji> <b>Order Cancelled</b>\n" +41 "<tg-emoji emoji-id='6266994443262367483'>😊</tg-emoji> <i>Koi baat nahi, jab chaho phir se wallet me balance add kar sakte ho.</i>" +42 "</blockquote>";43 44 Api.sendMessage({45 chat_id: chat.chatid,46 text: cancelText,47 parse_mode: "HTML",48 reply_markup: JSON.stringify({49 inline_keyboard: [[50 { text: "Back to Menu", callback_data: "/back", style: "primary", icon_custom_emoji_id: "6057415823222379852" }51 ]]52 })53 });54 55 if (callbackId) {56 Api.answerCallbackQuery({ callback_query_id: String(callbackId) });57 }58 59} catch (err) {60 Bot.sendMessage("⚠️ System Error: " + err.message);61}