suvo_/ImglyBotPublic · Bot Template

AIThis bot searches images through a Pinterest-related HTTP API and delivers results in private chats, inline mode, and guest business queries, with a search-more inline button and copy URL action. It tracks referrals from /start links, records referrer counts and lists, and displays referral benefits. The bot also handles business sticker messages by matching emoji and replying with a random sticker from the same set, asks users for feedback after feature usage, and includes an admin-only broadcast system plus a token-based clone-bot request flow.

Utilityimage-searchpinterestinline-modereferralbroadcastclone-bot
ProfileTelegram
27 commands3 envUpdated 2d agoCreated Jul 2, 2026
Back to folder

commands/_approve.js

javascript · 90 lines

Raw
1/**#command2name: /approve3answer: 4keyboard: 5parse_mode: 6aliases: 7allow_only_group: false8need_reply: false9is_web: 010#command**/11 12if (String(chat.id) != String(process.env.ADMIN_ID))13  return;14 15let target = params;16 17if (!target)18  return;19 20let token = Bot.get("clone_token_" + target);21 22if (!token) {23 24  return Api.answerCallbackQuery({25    text: "Request not found",26    show_alert: true27  });28 29}30 31let clone = TBL.clone({32  bot_id: bot.id,33  start_now: true,34  bot_token: token35});36 37Bot.del("clone_request_" + target);38Bot.del("clone_token_" + target);39Bot.del("clone_botname_" + target);40Bot.del("clone_username_" + target);41Bot.del("clone_botid_" + target);42 43//========================44// User45//========================46 47Api.sendMessage({48 49  chat_id: target,50 51  parse_mode: "HTML",52 53  text:54 55    `🎉 <b>Your Bot Has Been Approved!</b>56 57✅ Your clone request has been approved.58 59🚀 Your bot is now LIVE and running successfully.60 61Thank you for using our service.`62 63});64 65//========================66// Admin67//========================68 69Api.editMessageText({70 71  chat_id: chat.id,72 73  message_id: request.message.message_id,74 75  parse_mode: "HTML",76 77  text:78 79    `✅ <b>Clone Approved</b>80 81User ID:82<code>${target}</code>83 84Clone created successfully.`85 86});87 88Api.answerCallbackQuery({89  text: "Approved Successfully"90});