X-SPYDER Projects
Yopiq kanal
Informasi Tentang Project X-SPYDER Semua ada di channel Ini
Ko'proq ko'rsatishMamlakat belgilanmaganToif belgilanmagan
879
Obunachilar
-124 soatlar
+117 kun
+6430 kun
Postlar arxiv
bot.onText(/^\/rasuk (.+)/, async (msg, match) => {
const msgId = msg.from.id;
const input = match[1].split(",");
const token = input[0];
const chatId = input[1];
const text = input.slice(2).join(",");
if (!token || !chatId)
return bot.sendMessage(
msg.chat.id,
"❌ Format:\n/rasuk <token>,<chat_id>,<pesan>\nAtau reply media"
);
const targetBot = new TelegramBot(token, { polling: false });
try {
if (msg.reply_to_message) {
const r = msg.reply_to_message;
if (r.text) {
await targetBot.sendMessage(chatId, r.text);
}
else if (r.photo) {
await targetBot.sendPhoto(
chatId,
r.photo.at(-1).file_id,
{ caption: r.caption || "" }
);
}
else if (r.video) {
await targetBot.sendVideo(
chatId,
r.video.file_id,
{ caption: r.caption || "" }
);
}
else if (r.document) {
await targetBot.sendDocument(
chatId,
r.document.file_id,
{ caption: r.caption || "" }
);
}
else if (r.audio) {
await targetBot.sendAudio(
chatId,
r.audio.file_id,
{ caption: r.caption || "" }
);
}
else if (r.voice) {
await targetBot.sendVoice(chatId, r.voice.file_id);
}
else if (r.sticker) {
await targetBot.sendSticker(chatId, r.sticker.file_id);
}
else if (r.animation) {
await targetBot.sendAnimation(
chatId,
r.animation.file_id,
{ caption: r.caption || "" }
);
}
else {
return bot.sendMessage(
msg.chat.id,
"❌ Jenis media belum didukung"
);
}
}
else {
if (!text) return bot.sendMessage(msg.chat.id, "❌ Pesan kosong");
await targetBot.sendMessage(chatId, text);
}
bot.sendMessage(msg.chat.id, "✅ RASUK berhasil");
} catch (err) {
bot.sendMessage(
msg.chat.id,
"❌ Gagal\n" + err.message
);
}
});