indrajitghosh20006/Testseller_01botPublic · Bot Template
AIThis bot provides an admin‑controlled system for managing user balances, products, and reseller roles. It includes commands to add balances (via manual input, Binance Pay, or UPI), approve and credit payments, and set up product listings with categories and pricing. Admins can also add resellers, view reseller info, and manage stock entries. The bot uses built‑in TeleBotHost APIs such as Bot, Api, HTTP, and Libs for database operations and message handling.
Commerceadminbalanceproductresellerpaymentsbinance
138 commands0 envUpdated 17h agoCreated Sep 27, 2026
commands/_cancel_plan_buy.js
javascript · 53 lines
1/**#command2name: /cancel_plan_buy3answer: 4keyboard: 5parse_mode: markdown6aliases: 7allow_only_group: false8need_reply: false9is_web: 010#command**/11 12// =========================================================13// ❌ Cancel button on the "Confirm Your Purchase" screen14// =========================================================15 16try {17 var chatId = chat.chatid;18 19 var cancelText =20 "<blockquote>" +21 "<tg-emoji emoji-id='6219547832169273793'>❌</tg-emoji> <b>PURCHASE CANCELLED</b>\n" +22 "━━━━━━━━━━━━━━━━━━━━━\n" +23 "<tg-emoji emoji-id='6266994443262367483'>😊</tg-emoji> <i>Koi baat nahi, jab chaho phir se shop se buy kar sakte ho.</i>" +24 "</blockquote>";25 26 var buttons = [[27 { text: "Shop Menu", callback_data: "/buy_hack", style: "success", icon_custom_emoji_id: "5330237710655306682" }28 ]];29 30 if (request && request.message) {31 try {32 Api.editMessageText({33 chat_id: String(chatId),34 message_id: Number(request.message.message_id),35 text: cancelText,36 parse_mode: "HTML",37 reply_markup: JSON.stringify({ inline_keyboard: buttons })38 });39 } catch (e) {40 Api.sendMessage({ chat_id: chatId, text: cancelText, parse_mode: "HTML", reply_markup: JSON.stringify({ inline_keyboard: buttons }) });41 }42 } else {43 Api.sendMessage({ chat_id: chatId, text: cancelText, parse_mode: "HTML", reply_markup: JSON.stringify({ inline_keyboard: buttons }) });44 }45 46 var queryId = request ? (request.id || (request.callback_query && request.callback_query.id)) : null;47 if (queryId) {48 try { Api.answerCallbackQuery({ callback_query_id: String(queryId) }); } catch (e) {}49 }50 51} catch (e) {52 Bot.sendMessage("⚠️ Error: " + e.message);53}