devbro468/Dev_x_store_botPublic · Bot Template
AIThis bot operates a digital storefront (DEV X STORE) selling subscription-based products — likely game hacks, accounts, or access keys — categorized by platform (Android Root, Non-Root, iPhone). It features a reseller program with discounted pricing, a dual-currency wallet (INR balance + Telegram Stars/XTR), and a full admin/co-admin panel for managing products, plans, per-plan pricing, stock (keys/accounts), coupons, and API endpoints. Purchases flow through a plan selection screen offering wallet payment, Stars invoices (sendInvoice with XTR currency), and coupon application. Successful Stars payments are handled via successful_payment webhook, crediting wallet or delivering keys directly. Admin tools include user listing with chunked messaging, stock viewing/deletion with inline keyboards, co-admin management, and API registry updates. The bot registers users on first interaction and
commands/_broadcast.js
javascript · 26 lines
1/**#command2name: /broadcast3answer: 4keyboard: 5parse_mode: markdown6aliases: 7allow_only_group: false8need_reply: false9is_web: 010#command**/11 12try {13 var adminId = Bot.getProperty("owner_id") || "8875810358";14 var isCoAdmin0 = Bot.getProperty("co_admin_" + String(chat.chatid));15 if (String(chat.chatid) !== adminId && !isCoAdmin0) {16 Bot.sendMessage("❌ Restricted command!");17 return;18 }19 20 // Admin ki state active karna21 User.setProperty("awaiting_broadcast_data", true, "boolean");22 Bot.sendMessage("📢 <b>BROADCAST SYSTEM ACTIVATED</b>\n\nAb aap jo bhi message (Text, Photo, Video, Voice, Animation) bhejenge, wo sabhi users ko chala jayega.\n\n<i>Kripya apna message ab send karein...</i>", { parse_mode: "HTML" });23 24} catch (err) {25 Bot.sendMessage("Error: " + err.message);26}