ayushyadav7970824760/goldensellingstore_botPublic · Bot Template

AIThis Telegram store bot lets customers browse digital products and plans, apply coupons, add funds via UPI, and receive purchased keys. It includes a full admin panel for managing products, reordering items, setting reseller prices, viewing and removing key stock, configuring UPI payment details and update links, and checking user balances. Co-admins and resellers are supported, and support tickets are forwarded to the admin.

Commercedigital_storeadmin_panelupi_paymentsresellercouponskey_stock
ProfileTelegram
146 commands0 envUpdated 2d agoCreated Sep 5, 2026
Back to folder

commands/_open_ticket.js

javascript · 46 lines

Raw
1/**#command2name: /open_ticket3answer: 4keyboard: 5parse_mode: markdown6aliases: 7allow_only_group: false8need_reply: false9is_web: 010#command**/11 12// =========================================================13// 🎫 "Open Ticket" button — prompts user to describe their issue.14// Their next text message is auto-forwarded to admin (see /start MODULE 5c).15// =========================================================16 17try {18  User.setProperty("support_ticket_step", "waiting_message", "string");19 20  var promptText =21    "<blockquote>🎫 <b>OPEN A SUPPORT TICKET</b></blockquote>\n\n" +22    "<i>Apni problem/issue neeche type karke bhej dein — ye seedha admin ko forward ho jaayegi aur woh jald hi reply karenge.</i>";23 24  var queryId = request ? (request.id || (request.callback_query && request.callback_query.id)) : null;25 26  if (request && request.message && request.message.message_id) {27    try {28      Api.editMessageText({29        chat_id: String(chat.chatid),30        message_id: Number(request.message.message_id),31        text: promptText,32        parse_mode: "HTML",33        reply_markup: JSON.stringify({ inline_keyboard: [[{ text: "Cancel", callback_data: "/back", style: "danger" }]] })34      });35    } catch (e) {36      Api.sendMessage({ chat_id: chat.chatid, text: promptText, parse_mode: "HTML" });37    }38  } else {39    Bot.sendMessage(promptText, { parse_mode: "HTML" });40  }41 42  if (queryId) { try { Api.answerCallbackQuery({ callback_query_id: String(queryId) }); } catch (e) {} }43 44} catch (err) {45  Bot.sendMessage("⚠️ Error: " + err.message);46}