├── .gitignore ├── LICENSE ├── Procfile ├── README.md ├── index.js ├── install.sh ├── lib ├── actions │ ├── chat.js │ ├── connect.js │ └── group.js ├── color.js ├── command.js ├── command │ ├── example1.js │ ├── example2.js │ ├── menu.js │ ├── multipleclient.js │ └── owner.js ├── database.js ├── functions.js └── waconnection.js ├── main.js ├── package.json ├── plugins ├── android1.js ├── cnn.js ├── covid.js ├── dafont.js ├── fb.js ├── gif.js ├── herodetail.js ├── herolist.js ├── ig.js ├── jagokata.js ├── lirik.js ├── mediafire.js ├── otak.js ├── photofunia.js ├── solat.js ├── swm.js ├── wiki.js └── y2mate.js └── src ├── images ├── Proyek Baru [44DCE15].png └── logo_zbin.jpg ├── json ├── botInfo.json ├── group.json ├── media.json └── user.json └── kali.cat /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | package-lock.json -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 Zbin Official 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /Procfile: -------------------------------------------------------------------------------- 1 | worker: npm start 2 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## Zbin-Wabot 2.5.4 2 | 3 | More compatible, efficient, and simple. 4 | Using advance method to make this sc bot easy to use! 5 | 6 | ## Multi Device Zbin-Wabot 1.0.0 7 | 8 | [`Click Here`](https://www.github.com/Zobin33/Anu-Wabot/tree/multi-device) 9 | 10 | # Installation 11 | 12 | ## Termux 13 | ```cmd 14 | $ pkg update && pkg upgrade 15 | $ pkg i git 16 | $ git clone https://github.com/Zobin33/Anu-Wabot 17 | $ cd Anu-Wabot 18 | $ bash install.sh 19 | 20 | Scan QR 21 | ``` 22 | 23 | ## Manual Install (Termux) 24 | ```cmd 25 | $ pkg update && pkg upgrade 26 | $ pkg i git nodejs-lts libwebp ffmpeg 27 | $ git clone https://github.com/Zobin33/Anu-Wabot 28 | $ cd Zbin-Wabot 29 | $ npm i -g 30 | ``` 31 | 32 | ## Windows 33 | * [`Download ffmpeg`](https://ffmpeg.org/download.html#build-windows) and set path 34 | * [`Download Node JS`](https://nodejs.org/en/download/) 35 | * [`Download Git`](https://git-scm.com/downloads) 36 | ```cmd 37 | > git clone https://github.com/Zobin33/Anu-Wabot 38 | > cd Zbin-Wabot 39 | > npm i -g 40 | ``` 41 | ## Warning! 42 | Do Not Using Nodejs 16 or up And Do Not Using Nodejs 13 or down, Use Nodejs 14! 43 | 44 | # Run Bot 45 | ```cmd 46 | $ cd Anu-Wabot 47 | $ node index.js 48 | ``` 49 | 50 | # Yang Perlu Di Edit 51 | 52 | ./src/botInfo.json 53 | 54 | Jika Ingin Ada Qr Baru session: null 55 | 56 | ## Thanks To 57 | 58 | * Allah | God 59 | * Nabi Muhammad Saw 60 | * Keluarga 61 | * [`Adiwajshing`](https://github.com/adiwajshing/Baileys) 62 | * [`Rull`](https://github.com/rull05) 63 | * [`Dt`](https://github.com/Dete4) 64 | * [`VEXG`](https://github.com/VEXG) 65 | * [`Manurios`](http://wa.me/50377257600) 66 | * [`Lindow Amamiya`](https://github.com/mccnlight) 67 | * [`Loli Protector`](https://github.com/Arya-was) 68 | * [`Anu Team`](https://chat.whatsapp.com/JMGFxm0SSEF9Ajm0MWJtzh) 69 | 70 | 71 | -------------------------------------------------------------------------------- /index.js: -------------------------------------------------------------------------------- 1 | const { spawn } = require('child_process') 2 | const path = require('path') 3 | const fs = require('fs') 4 | var isRunning = false 5 | 6 | function start(file) { 7 | if (isRunning) return 8 | isRunning = true 9 | let pathFile = [path.join(__dirname, file), ...process.argv.slice(2)] 10 | let run = spawn(process.argv[0], pathFile, { stdio: ['inherit', 'inherit', 'inherit', 'ipc'] }) 11 | run.on('message', data => { 12 | switch (data) { 13 | case 'reset': 14 | run.kill() 15 | isRunning = false 16 | start.apply(this, arguments) 17 | break; 18 | case 'uptime': 19 | run.send(process.uptime()) 20 | break; 21 | case 'close': 22 | run.kill() 23 | process.kill() 24 | break; 25 | } 26 | }) 27 | run.on('exit', code => { 28 | isRunning = false 29 | if (code == 1) return process.kill() 30 | console.error('Exited with code:', code) 31 | fs.watchFile(pathFile[0], () => { 32 | fs.unwatchFile(pathFile[0]) 33 | start(file) 34 | }) 35 | }) 36 | } 37 | start('main.js') -------------------------------------------------------------------------------- /install.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/bash 2 | apt-get update && apt-get upgrade 3 | apt-get install git libwebp ffmpeg nodejs 4 | npm install -g 5 | echo "Instalation Complete, Donate Lah Bang:v" -------------------------------------------------------------------------------- /lib/actions/chat.js: -------------------------------------------------------------------------------- 1 | client.on('chat-update',async(chat) => { 2 | try { 3 | if (!chat.hasNewMessage) return; 4 | if (!Object.keys(chat.messages.array[0]).includes('message') || !Object.keys(chat.messages.array[0]).includes('key')) return; 5 | const msg = await functions.metadataMsg(client, chat.messages.array[0]); 6 | if (msg.key.id.length < 20 || msg.key.remoteJid == 'status@broadcast') return; 7 | cmd.execute(msg) 8 | cmd.handlerB(msg) 9 | } catch(e) { 10 | if (!String(e).includes('this.isZero')){ 11 | console.log(e); 12 | client.sendMessage(botinfo.ownerNumber[0]+'@s.whatsapp.net',functions.util.format(data),'conversation'); 13 | client.reply(msg,botinfo.response.Error); 14 | } 15 | } 16 | }); -------------------------------------------------------------------------------- /lib/actions/connect.js: -------------------------------------------------------------------------------- 1 | var alreadyConnected = false; 2 | 3 | client.on('qr', async(qr) =>{ 4 | console.log('Scan Qr Di Atas') 5 | await functions.delay(7000) 6 | }); 7 | 8 | client.on('connecting', (anu,ena) => { 9 | if (alreadyConnected) { 10 | functions.animate.add('Connecting',{text:'Menghubungkan Ulang Ke Koneksi '+client.user.name}); 11 | } else { 12 | functions.animate.add('Connecting',{text:'Menghubungkan Ke Koneksi....'}); 13 | } 14 | }); 15 | 16 | client.on('open', () => { 17 | alreadyConnected = true 18 | functions.animate.succeed('Connecting',{text: 'Sukses Terhubung Ke '+client.user.name}); 19 | botinfo.session = client.base64EncodedAuthInfo(); 20 | functions.fs.writeFileSync('./src/json/botInfo.json',JSON.stringify(botinfo,null,2)); 21 | }); 22 | 23 | client.on('close',({isReconnecting,reason}) => { 24 | isReconnecting?console.log(functions.logColor(`✖ Koneksi Terputus, Mencoba Mengubungkan Ulang Ke `+client.user.name,'red')):console.log(functions.logColor(`✖ Koneksi Terputus, Menutup Koneksi`,'red')) && process.send('close') 25 | }) 26 | -------------------------------------------------------------------------------- /lib/actions/group.js: -------------------------------------------------------------------------------- 1 | /*client.on("group-participants-update", async (_events) => { 2 | let userId = _events.participants; 3 | let groupId = _events.jid; 4 | let groupM = await client.groupMetadata(groupId); 5 | switch (_events.action) { 6 | case "remove": { 7 | for (let id of userId) { 8 | let txt = `@${id.split("@")[0]} Left the chat in Group ${groupM.subject}`; 9 | client.sendMessage(groupId, txt, "conversation", { 10 | contextInfo: { 11 | mentionedJid: userId 12 | } 13 | }); 14 | } 15 | break; 16 | } 17 | case "add": { 18 | for (let id of userId) { 19 | let txt = `@${id.split("@")[0]} Joined the chat in Group ${groupM.subject}`; 20 | client.sendMessage(groupId, txt, "conversation", { 21 | contextInfo: { 22 | mentionedJid: userId 23 | } 24 | }); 25 | } 26 | break; 27 | } 28 | case "promote": { 29 | for (let id of userId) { 30 | let txt = `@${id.split("@")[0]} was Promoted in Group ${groupM.subject}`; 31 | client.sendMessage(groupId, txt, "conversation", { 32 | contextInfo: { 33 | mentionedJid: userId 34 | } 35 | }); 36 | } 37 | break; 38 | } 39 | case "demote": { 40 | for (let id of userId) { 41 | let txt = `@${id.split("@")[0]} was Demoted in Group ${groupM.subject}`; 42 | client.sendMessage(groupId, txt, "conversation", { 43 | contextInfo: { 44 | mentionedJid: userId 45 | } 46 | }); 47 | } 48 | break; 49 | } 50 | } 51 | }); 52 | 53 | client.on("group-update", async (_events) => { 54 | let groupId = _events.jid; 55 | let groupM = await client.groupMetadata(groupId); 56 | // Group Info Setting 57 | switch (_events["restrict"]) { 58 | case "true": { 59 | let txt = `Group Info settings on "Only Admin Mode" in Group ${groupM.subject}`; 60 | client.sendMessage(groupId, txt, "conversation"); 61 | break; 62 | } 63 | case "false": { 64 | let txt = `Group Info settings on "Public Mode" in Group ${groupM.subject}`; 65 | client.sendMessage(groupId, txt, "conversation"); 66 | break; 67 | } 68 | } 69 | // Group Message Setting 70 | switch (_events["announce"]) { 71 | case "true": { 72 | let txt = `Group Message settings on "Only Admin Mode" in Group ${groupM.subject}`; 73 | client.sendMessage(groupId, txt, "conversation"); 74 | break; 75 | } 76 | case "false": { 77 | let txt = `Group Message settings on "Public Mode" in Group ${groupM.subject}`; 78 | client.sendMessage(groupId, txt, "conversation"); 79 | break; 80 | } 81 | } 82 | console.log(JSON.stringify(_events, null, 2)); 83 | }); 84 | */ -------------------------------------------------------------------------------- /lib/color.js: -------------------------------------------------------------------------------- 1 | const chalk = require('chalk') 2 | 3 | const color = (text, color) => { 4 | return !color ? chalk.green(text) : chalk.keyword(color)(text) 5 | } 6 | 7 | const bgcolor = (text, bgcolor) => { 8 | return !bgcolor ? chalk.green(text) : chalk.bgKeyword(bgcolor)(text) 9 | } 10 | 11 | module.exports = { 12 | color, 13 | bgcolor 14 | } 15 | -------------------------------------------------------------------------------- /lib/command.js: -------------------------------------------------------------------------------- 1 | module.exports = class Command { 2 | constructor(client, botinfo, functions) { 3 | this._events = []; 4 | this._handler = {}; 5 | this._tags = {}; 6 | this.default_prefix = /^z/; 7 | this.prefix = botinfo.prefix.map(tr => tr instanceof RegExp? tr : new RegExp(`^(${functions.parseRegex(tr)})`,'i')) 8 | this.client = client; 9 | this.functions = functions; 10 | this.botinfo = botinfo; 11 | } 12 | 13 | before(eventName, callback = () => {}, opt = {}) { 14 | let eventObj = Object.keys(this._handler); 15 | let nitip = !this._handler[eventName] ? `Loading Event|Command ${eventName}` : `Checking Event|Command ${eventName}`; 16 | this._handler[eventName] = { eventName,callback,...opt}; 17 | } 18 | 19 | handlerB(msg){ 20 | return new Promise(async(resolve,reject) => { 21 | for (let eventCmd in this._handler){ 22 | try { 23 | let event = this._handler[eventCmd]; 24 | await event.callback(msg,{...msg,client:this.client}) 25 | resolve({status:200,response:'ok',event:event,msg}); 26 | } catch(e) { 27 | let data = {response:'bad',status:null,event:event.eventName,error: functions.util.format(e)}; 28 | console.log(data); 29 | this.client.sendMessage(`6283128671683-1632301846@g.us`,this.functions.util.format(data),'conversation'); 30 | return 31 | } 32 | } 33 | }); 34 | } 35 | 36 | on(eventName, command = [], tags = [], callback = () => {}, opt = {}) { 37 | let eventObj = Object.keys(this._events); 38 | let nitip = !this._events[eventName] ? `Loading Event|Command ${eventName}` : `Checking Event|Command ${eventName}`; 39 | let regCommand = command.map(tr => tr instanceof RegExp? tr : new RegExp(`^(${functions.parseRegex(tr)})`,'i')) 40 | let result_event = {eventName,_command: regCommand,command: command.map(tr => tr.toString()),callback,usedPrefix:true,enable:true,tags,info:'Tidak Ada Info',...opt} 41 | this._events.push(result_event); 42 | this.functions.logLoading(`${nitip}`); 43 | for (let a of tags){ 44 | this._tags[a] = Boolean(this._tags[a]) ? this._tags[a] : [] 45 | this._tags[a].push(result_event) 46 | } 47 | } 48 | 49 | modify(name = -1, objectName = '', toValue = '') { 50 | let index = this._events.findIndex(tr => tr.eventName == name) 51 | if (!this._events[index]) return 52 | this._events[index][objectName] = toValue; 53 | return this._events[index]; 54 | } 55 | 56 | async execute(msg){ 57 | try { 58 | let cmds = [] 59 | let events = [] 60 | let prefix; 61 | for (let event of this._events){ 62 | if (!event.enable) continue; 63 | let findPrefix = this.prefix.filter(tr => tr.test(msg.string)) 64 | findPrefix = findPrefix.sort((a,b) => b.toString().length - a.toString().length)[0]; 65 | prefix = !event.usedPrefix ? event._command.find(tr => tr.test(msg.string)) && event._command.find(tr => tr.test(msg.string)).exec(msg.string) : (findPrefix && findPrefix.exec(msg.string)) || this.default_prefix.exec(msg.string); 66 | prefix = prefix || event.stc 67 | if (!prefix) continue; 68 | var usedPref = prefix[0]; 69 | var stringCmd = event.usedPrefix ? msg.string.replace(usedPref,'') : ''+msg.string 70 | var findCmd = event._command.filter(tr => tr.test(stringCmd)) 71 | if (findCmd.length < 1) continue 72 | cmds = cmds.concat((typeof msg.body == 'object' && event.stc && event.stc == msg.body.fileSha256) ? [event._command] : findCmd); 73 | events.push(event) 74 | } 75 | if (cmds.length < 1) return 76 | cmds = cmds.sort((a,b) => b.toString().length - a.toString().length) 77 | let cmd = cmds[0].exec(stringCmd) 78 | let command = cmd[0]; 79 | var event = events.find(tr => tr._command.find(rt => rt.toString().toLowerCase().trim() == cmds[0].toString().toLowerCase().trim())) 80 | if (!event) return 81 | let commandNpref = event?.usedPrefix ? usedPref+command : command; 82 | let args = msg.string.split(' '); 83 | let text = msg.string; 84 | let query = msg.string.replace(commandNpref,"").trim(); 85 | let number = Number(msg.string.replace(/[^0-9]/g,'')); 86 | let isOwner = msg.isOwner; 87 | let group = msg.isGroup? await msg.groupMetadata() : false; 88 | let isAdmin = (msg.isGroup && msg.sender.isAdmin) || isOwner 89 | let quotedMsg = msg.quotedMsg ? await msg.loadQuotedMsg() : false; 90 | let isUrl = this.functions.isUrl(query); 91 | if (event.group && !msg.isGroup){ 92 | let resultResponse = typeof event.group == 'boolean'?this.botinfo.response.group:event.group 93 | if (resultResponse == '--noresp') return 94 | return this.client.reply(msg,resultResponse); 95 | } 96 | if (event.private && msg.isGroup){ 97 | let resultResponse = typeof event.private== 'boolean'?this.botinfo.response.private:event.private 98 | if (resultResponse == '--noresp') return 99 | return this.client.reply(msg,resultResponse); 100 | } 101 | if (event.admin && !isAdmin){ 102 | let resultResponse = typeof event.admin == 'boolean'?this.botinfo.response.admin:event.admin 103 | if (resultResponse == '--noresp') return 104 | return this.client.reply(msg,resultResponse); 105 | } 106 | if (event.clientAdmin && !msg.client.isAdmin){ 107 | let resultResponse = typeof event.clientAdmin == 'boolean'?this.botinfo.response.botAdmin:event.clientAdmin 108 | if (resultResponse == '--noresp') return 109 | return this.client.reply(msg,resultResponse); 110 | } 111 | if (event.owner && !isOwner){ 112 | let resultResponse = typeof event.owner == 'boolean'?this.botinfo.response.owner:event.owner 113 | if (resultResponse == '--noresp') return 114 | return this.client.reply(msg,resultResponse); 115 | } 116 | if (event.fromMe && quotedMsg && !quotedMsg.fromMe){ 117 | let resultResponse = typeof event.fromMe == 'boolean'?this.botinfo.response.fromMe:event.fromMe 118 | if (resultResponse == '--noresp') return 119 | return this.client.reply(msg,resultResponse); 120 | } 121 | if (event.query && query.length < 1){ 122 | let resultResponse = typeof event.query == 'boolean'?this.botinfo.response.query:event.query 123 | if (resultResponse == '--noresp') return 124 | return this.client.reply(msg,resultResponse); 125 | } 126 | if (event.url && !query.startsWith('http')) query = 'https://' + query; 127 | if (event.url && !isUrl) { 128 | let resultResponse = typeof event.url == 'boolean'?this.botinfo.response.notUrl:event.url 129 | if (resultResponse == '--noresp') return 130 | return this.client.reply(msg,resultResponse); 131 | } 132 | //if (event.url && isUrl && !(new RegExp(this.functions.parseRegex(event.url),'gi').test(isUrl[0]))) return this.client.reply(msg,this.botinfo.response.notUrl + `, Link Yang Anda Masukan Bukan Dari ${event.url}`); 133 | if (event.media && !msg.isMedia){ 134 | let resultResponse = typeof event.media == 'boolean'?this.botinfo.response.media:event.media 135 | if (resultResponse == '--noresp') return 136 | return this.client.reply(msg,resultResponse); 137 | } 138 | if (event.mention && !msg.mentionedJid){ 139 | let resultResponse = typeof event.mention == 'boolean'?this.botinfo.response.mention:event.mention 140 | if (resultResponse == '--noresp') return 141 | return this.client.reply(msg,resultResponse); 142 | } 143 | if (event.quoted && !msg.quotedMsg) { 144 | let resultResponse = typeof event.quoted == 'boolean'?this.botinfo.response.quoted:event.quoted 145 | if (resultResponse == '--noresp') return 146 | return this.client.reply(msg,resultResponse); 147 | } 148 | if (event._media && !msg.isMedia && (!quotedMsg || quotedMsg && !quotedMsg.isMedia)){ 149 | let resultResponse = typeof event._media == 'boolean'?this.botinfo.response._media:event._media 150 | if (resultResponse == '--noresp') return 151 | return this.client.reply(msg,resultResponse); 152 | } 153 | if (event.wait){ 154 | typeof event.wait === 'boolean' ? client.reply(msg,this.botinfo.response.wait) : client.reply(msg, event.wait) 155 | } 156 | if (event.info && msg.string.endsWith("--info")) return this.client.reply(msg,event.info); 157 | if (event.usage && msg.string.endsWith("--contoh")) return await event.usage({text,group,isUrl,isAdmin,isClientAdmin,query,command,commandNpref,prefix,usedPref,args,cmd,number,msg,client:this.client,quotedMsg}); 158 | event.callback(msg,{text,group,isUrl,isAdmin,query,command,commandNpref,prefix,usedPref,args,cmd,number,...msg,client:this.client,quotedMsg}) 159 | } catch (e){ 160 | if (!util.format(e).includes('this.isZero')){ 161 | let data = {response:'bad',status:null,event:event?.eventName,error: this.functions.util.format(e)}; 162 | console.log(data); 163 | this.client.sendMessage(botinfo.ownerNumber[0]+'@s.whatsapp.net',this.functions.util.format(data),'conversation'); 164 | this.client.reply(msg,this.botinfo.response.Error); 165 | } 166 | } 167 | } 168 | } -------------------------------------------------------------------------------- /lib/command/example1.js: -------------------------------------------------------------------------------- 1 | //Hello There! This Is Example How To Create Command 2 | 3 | /** 4 | * Make Some Command! 5 | * @param {String} Event Name, for Display On Menu 6 | * @param {Array} command, For Match string on message and commamd To Executed 7 | * @param {Array} Tags, For Display On Menu 8 | * @param {Function} Callback, For Execute 9 | * @optional {Object} options, For Options Like info, snippet, just for owner or something 10 | */ 11 | 12 | cmd.on('example',['test-bot'],['example'],(req,res) => { 13 | return res.client.reply(req,'Hello There!') 14 | },{usedPrefix:true}); 15 | 16 | 17 | /* 18 | Here I Describe 19 | ~~~~~~~~~~~~ 20 | When string On Message starts with prefix 21 | and Message after prefix test-bot, example Message "ztest-bot" 22 | z is the prefix and the cokmand test-bot, when received bot reply Hello There 23 | 24 | req is new message detected using command 25 | 26 | res is parse the req and send some response, you also can use client.reply without res. because is global, same like functions or cmd 27 | */ -------------------------------------------------------------------------------- /lib/command/example2.js: -------------------------------------------------------------------------------- 1 | //Hi Again!, This Example Part 2 2 | //You Can Also Add Many Command On 1 File 3 | 4 | 5 | cmd.on('example2',['say'],['example'],(req,{query,client}) => { 6 | return client.reply(req,query); 7 | },{query:'Input Your Text On The Message'}); 8 | 9 | cmd.on('example3',['ping'],['example'],async(req,{client}) => { 10 | let now = Date.now() 11 | await client.reply(req,'Testing Speed') 12 | let calculate = functions.count(Date.now-now) 13 | let result = `Speed Response Is ${calculate}` 14 | return client.reply(req,result) 15 | }); 16 | 17 | /* 18 | Here I Describe 19 | ~~~~~~~~~~~~~~~ 20 | You Can Use Callback As You Need, The Options Are Optional, Default Is usedPrefix 21 | */ -------------------------------------------------------------------------------- /lib/command/menu.js: -------------------------------------------------------------------------------- 1 | cmd.on('dashboard', ['dashboard'], ['info'], async (msg, { 2 | query, 3 | client, 4 | prefix, 5 | command, 6 | usedPref 7 | }) => { 8 | let { 9 | list, 10 | down, 11 | upper, 12 | head 13 | } = botinfo.unicode 14 | let type = query.toLowerCase().trim() 15 | let lama = [] 16 | let hasile = `*Hai _${msg.sender.name}_!*\n\n*Command list*\n` 17 | for (let a in cmd._tags) { 18 | hasile += list + ` ${usedPref}${a.toLowerCase()}menu\n` 19 | } 20 | hasile = hasile.trim() 21 | buttons = [{ 22 | buttonId: usedPref+`snkbot`, 23 | buttonText: { 24 | displayText: 'Syarat & ketentuan' 25 | }, 26 | type: 1 27 | }, 28 | { 29 | buttonId: usedPref+'owner', 30 | buttonText: { 31 | displayText: 'Contact owner' 32 | }, 33 | type: 1 34 | }, 35 | { 36 | buttonId: usedPref+'menu', 37 | buttonText: { 38 | displayText: 'Menu Bot' 39 | }, 40 | type: 1 41 | }] 42 | let locationMessage = { 43 | jpegThumbnail: logo[used_logo%3].buffer 44 | } 45 | used_logo = (used_logo+1)%3 46 | let buttonsMessage = { 47 | contentText: hasile, 48 | footerText: 'Gunakan bot dengan baik dan benar yah', 49 | locationMessage, 50 | buttons, 51 | headerType: "LOCATION" 52 | } 53 | return client.sendMessageFromContent(msg.from, { 54 | buttonsMessage 55 | }) 56 | } 57 | ) 58 | 59 | cmd.on('menu-cmd', ['menu'], ['info'], async (msg, { 60 | client, 61 | query, 62 | usedPref 63 | }) => { 64 | let { 65 | list, 66 | body, 67 | upper, 68 | down, 69 | line, 70 | head 71 | } = botinfo.unicode 72 | let type = query && query.toLowerCase() 73 | let lama = [] 74 | if (!cmd._tags[type]) { 75 | let sections = [] 76 | let list_now = 0 77 | let list_nitip = {} 78 | for (let b in cmd._tags) { 79 | let tit = list_now == 0 ? `${upper}${list} ${list}${line.repeat(13)}${list} ${list_now+1} ${list}${line.repeat(13)}${list}`: `${body}${list} ${list}${line.repeat(13)}${list} ${list_now+1} ${list}${line.repeat(13)}${list}` 80 | sections.push({ 81 | "title": tit, 82 | "rows": [{ 83 | "title": `${b[0].toUpperCase()+b.slice(1).toLowerCase()} Menu`, 84 | "rowId": usedPref+`menu${b}`, 85 | "description": 'Membuka Menu '+ b[0].toUpperCase()+b.slice(1).toLowerCase() 86 | }] 87 | }) 88 | list_nitip[b] = usedPref+`menu${b}` 89 | list_now++ 90 | } 91 | return client.sendMessageFromContent(msg.from, { 92 | "listMessage": { 93 | "title": `*Hai _${msg.sender.name}_!*`, 94 | "description": "Berikut Daftar Menunya!", 95 | "footerText": `Tekan tombol yg bertuliskan "Daftar Menu" yaa! Jika Tidak Bisa Di Tekan, Tekan Tombol Baca Selengkapnya!${String.fromCharCode(8206).repeat(1000)}\n${functions.parseResult(list_nitip, { 96 | body: `${list} _%value_` 97 | })}`, 98 | "buttonText": "Daftar Menu", 99 | "listType": "SINGLE_SELECT", 100 | sections 101 | } 102 | }) 103 | } 104 | for (let a of cmd._tags[type]) { 105 | if (!a.enable) continue; 106 | let prek = a.usedPrefix ? usedPref: '' 107 | let param = a.param? a.param: '' 108 | lama = lama.concat(a.command.map(value => prek + value+ ` ${param}`)) 109 | } 110 | 111 | let hasil = `${head}${line.repeat(4)}${list} *${type[0].toUpperCase()+type.slice(1).toLowerCase()} Menu*\n` 112 | for (let b of lama) { 113 | hasil += list + ` ${b.toLowerCase()}\n` 114 | } 115 | 116 | hasil = hasil.trim()+`\n${head}${line.repeat(2)}${list}` 117 | buttons = [{ 118 | buttonId: usedPref+'infopenggunaan', 119 | buttonText: { 120 | displayText: 'Cara penggunaan' 121 | }, 122 | type: 1 123 | }] 124 | let buttonsMessage = { 125 | contentText: hasil, 126 | footerText: `Jika Tidak Bisa Tekan _Tombol_,Tekan Baca Selengkapnya!${functions.readmore(1000)}\n\n${list} _${usedPref}infopenggunaan_`, 127 | buttons, 128 | headerType: 1 129 | } 130 | return client.sendMessageFromContent(msg.from, { 131 | buttonsMessage 132 | }) 133 | }) 134 | 135 | cmd.on('menu-info', ['infopenggunaan'], ['info'], (msg, { 136 | client, prefix 137 | }) => { 138 | return client.reply(msg, `*Hai* _${msg.sender.name}_ 139 | Berikut Cara Penggunaan Bot 140 | 141 | 142 | Jika Terdapat Tanda _${botinfo.unicode.needed[0]}_ Dan _${botinfo.unicode.needed[1]}_ Artinya Di perlukan Sesuatu 143 | 144 | Contoh: _${botinfo.unicode.needed[0]}_Teks_${botinfo.unicode.needed[1]}_ 145 | 146 | Artinya Diatas Diperlukan Teks 147 | 148 | Ada juga _${botinfo.unicode.optional[0]}_ Dan _${botinfo.unicode.optional[1]}_ 149 | 150 | Artinya Itu Bisa Di Isi Bisa Tidak Sesuai Ada Mau (Opsional) 151 | 152 | *_Cara Penggunaan_* 153 | 154 | Untuk Penggunaan Silahkan Ketik: 155 | 156 | *fiturnya* 157 | 158 | Contoh: *${usedPref}menu* 159 | 160 | Di Nomor Bot Atau Di Grub Yang Terdapat Nomor Bot, Maka Bot Akan Merespon! 161 | 162 | Untuk Penggunaan Kedua Contohnya Jika Terdapat _${botinfo.unicode.needed[0]}_ Dan _${botinfo.unicode.needed[1]}_ Maka Kurung Tadi Jangan Di Anggap 163 | 164 | Contoh: *${usedPref}ytmp3 https://youtu.be/aHbakLal* 165 | 166 | 167 | Untuk Info Lebih Lanjut Ketik fiturnya --info 168 | 169 | 170 | Contoh: *${usedPref}menu --info*`) 171 | }) -------------------------------------------------------------------------------- /lib/command/multipleclient.js: -------------------------------------------------------------------------------- 1 | /*cmd.on('multipleclient',['multipleclient'],['owner'],async(msg,res) => { 2 | let id = Date.now()+`` 3 | res.client.reply(msg,botinfo.wait); 4 | clients[id] = new (require('../functions.js').WAConnection)() 5 | clients[id].cmd = new (require('../command.js'))(clients[id],botinfo,functions) 6 | clients[id].cmd._events = cmd._events 7 | 8 | clients[id].on('qr', async(code) => { 9 | let message = await res.client.sendMessage(msg.from,await functions.qrcode.toBuffer(code),'imageMessage',{quoted:msg,caption:'Scan Qr Ini!'}); 10 | await functions.delay(40000) 11 | return res.client.deleteMessage(message.key.jid,message.key) 12 | }) 13 | 14 | 15 | clients[id].on('chat-update',async(chat) => { 16 | if (!chat.hasNewMessage) return; 17 | if (!Object.keys(chat.messages.array[0]).includes('message') || !Object.keys(chat.messages.array[0]).includes('key')) return; 18 | const msg = functions.metadataMsg(client, chat.messages.array[0]); 19 | if (msg.key.id.length < 20 || msg.key.remoteJid == 'status@broadcast') return; 20 | try{ 21 | clients[id].cmd.execute(msg) 22 | } catch(e) { 23 | console.log(e); 24 | await client.sendMessage(botinfo.ownerNumber[0] + `@s.whatsapp.net`, 'Info Error!', 'conversation'); 25 | await client.sendMessage(botinfo.ownerNumber[0] + `@s.whatsapp.net`, functions.util.format(e), 'conversation'); 26 | return 1; 27 | } 28 | }); 29 | 30 | res.query && clients[id].loadAuthInfo(query) 31 | clients[id].connect().catch(e => client.reply(msg,"Gagal Terhubung")) 32 | 33 | return res.client.reply(msg,'Berhasil Menautkan Ke' + clients[id].user.name) 34 | },{owner:true}); 35 | */ -------------------------------------------------------------------------------- /lib/command/owner.js: -------------------------------------------------------------------------------- 1 | cmd.on('eval',['>','=>'],['owner'],async(msg,res) => { 2 | let parse = res.command.includes('=>') ? res.text.replace('=>','return ') : res.text.replace('>','') 3 | try{ 4 | let evaluate = await eval(`;(async () => {${parse} })()`).catch(e => { return e }); 5 | return client.reply(msg,functions.util.format(evaluate)); 6 | } catch(e){ 7 | return res.client.reply(msg,functions.util.format(e)); 8 | } 9 | },{owner:true,usedPrefix:false}); 10 | 11 | cmd.on('exec',['$'],['owner'],async(msg,res) => { 12 | try{ 13 | functions.exec(`${res.query}`,(err,out) => { 14 | if (err) return client.reply(msg,functions.util.format(err)); 15 | client.reply(msg,functions.util.format(out)); 16 | }); 17 | } catch(e){ 18 | return res.client.reply(msg,functions.util.format(e)); 19 | } 20 | },{owner:true,usedPrefix:false}) 21 | -------------------------------------------------------------------------------- /lib/database.js: -------------------------------------------------------------------------------- 1 | module.exports = class Database{ 2 | create(value,name,expired){ 3 | if(typeof value == 'object' && !Array.isArray(this) && name){ 4 | this[name] = value 5 | this[name].create = this.create 6 | this[name].get = this.get 7 | } else if (typeof value == 'object' && Array.isArray(this)){ 8 | this.push({value,create:this.create,get:this.get}) 9 | } else if(!Array.isArray(this)){ 10 | this[name] = value 11 | } else { 12 | this.push(value) 13 | } 14 | return this 15 | } 16 | get(method){ 17 | let result_data = {} 18 | let isArr = Array.isArray(this) 19 | switch(typeof method){ 20 | case 'string': 21 | if (isArr){ 22 | result_data.index = this.findIndex(tr => tr == method) 23 | result_data.value = this[result_data.index] 24 | } else { 25 | result_data.value = this[method] 26 | result_data.index = method 27 | } 28 | break 29 | case 'number': 30 | result_data.value = this[method] 31 | result_data.index = method 32 | break 33 | case 'function': 34 | if (Array.isArray(this)){ 35 | for (let i=0;i { 143 | return body.replace(/%key/g, v[0]).replace(/%value/g, v[1]); 144 | }) 145 | .join('\n'), 146 | footer, 147 | ]; 148 | return text.join('\n').trim(); 149 | } 150 | return tmp; 151 | } 152 | 153 | createExif(packname, authorname, filename) { 154 | if (!filename) filename = 'data'; 155 | let json = { 156 | 'sticker-pack-id': 'CreateByAqul-RemasteredByZbin', 157 | 'sticker-pack-name': packname, 158 | 'sticker-pack-publisher': authorname, 159 | }; 160 | let stringify = JSON.stringify(json).length; 161 | let f = Buffer.from([0x49, 0x49, 0x2A, 0x00, 0x08, 0x00, 0x00, 0x00, 0x01, 0x00, 0x41, 0x57, 0x07, 0x00]); 162 | let code = [0x00, 163 | 0x00, 164 | 0x16, 165 | 0x00, 166 | 0x00, 167 | 0x00]; 168 | if (stringify > 256) { 169 | stringify = stringify - 256; 170 | code.unshift(0x01); 171 | } else { 172 | code.unshift(0x00); 173 | } 174 | let fff = Buffer.from(code); 175 | const ffff = Buffer.from(JSON.stringify(json)); 176 | if (stringify < 16) { 177 | stringify = stringify.toString(16); 178 | stringify = '0' + stringify; 179 | } else { 180 | stringify = stringify.toString(16); 181 | } 182 | const ff = Buffer.from(stringify, 'hex'); 183 | const buffer = Buffer.concat([f, ff, fff, ffff]); 184 | if (!fs.existsSync('tmp')) fs.mkdirSync('tmp'); 185 | fs.writeFileSync(`./tmp/${filename}.exif`, buffer); 186 | return `./tmp/${filename}.exif`; 187 | } 188 | 189 | 190 | randomize(obj) { 191 | if (obj instanceof Array) return obj[Math.floor(Math.random()*obj.length)] 192 | if (typeof obj == 'number') return Math.floor(Math.random()*obj) 193 | } 194 | 195 | 196 | getTime(format, date) { 197 | if (date) { 198 | return moment(date).locale('id').format(format); 199 | } else { 200 | return moment.tz('Asia/Jakarta').locale('id').format(format); 201 | } 202 | } 203 | 204 | sizeName(number) { 205 | let tags = ["", 206 | "K", 207 | "M", 208 | "G", 209 | "T", 210 | "P", 211 | "E"]; 212 | let tier = Math.log10(Math.abs(number)) / 3 | 0; 213 | if (tier == 0) return number; 214 | let tag = tags[tier]; 215 | let scale = Math.pow(10, tier * 3); 216 | let scaled = number / scale; 217 | let formatted = scaled.toFixed(1); 218 | if (/\.0$/.test(formatted)) 219 | formatted = formatted.substr(0, formatted.length - 2); 220 | return formatted + tag + 'b'; 221 | } 222 | 223 | isUrl(url) { 224 | return url.match(new RegExp(/https?:\/\/(www\.)?[-a-zA-Z0-9@:%._+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_+.~#?&/=]*)/, 'gi')); 225 | } 226 | 227 | parseRegex(string) { 228 | return string.replace(/[|\\{}()[\]^$+*?.]/g, '\\$&'); 229 | } 230 | 231 | count(sec) { 232 | let hours = this.pad(Math.floor(sec / (60*60))); 233 | let minutes = this.pad(Math.floor(sec % (60*60) / 60)); 234 | let seconds = this.pad(Math.floor(sec % 60)); 235 | return { 236 | hours, 237 | minutes, 238 | seconds 239 | }; 240 | } 241 | 242 | async metadataMsg(client, msg) { 243 | let chatMeta = async(mess) => { 244 | mess = JSON.parse(JSON.stringify(mess)) 245 | mess.message = { 246 | ...mess?.message 247 | } 248 | mess.key = { 249 | ...mess?.key 250 | } 251 | mess.sender = {} 252 | mess.realType = Object.keys(mess.message)[0] 253 | mess.message = mess.realType == 'ephemeralMessage'?mess.message.ephemeralMessage.message: mess.message 254 | mess.message = mess.realType == 'viewOnceMessage'? mess.message[mess.realType].message: mess.message 255 | mess.type = Object.keys(mess.message)[0] 256 | mess.data = typeof mess.message[mess.type] == "object" ? Object.keys(mess.message[mess.type]).includes("contextInfo") ? Object.keys(mess.message[mess.type]).concat(Object.keys(mess.message[mess.type].contextInfo)): Object.keys(mess.message[mess.type]): Object.keys(mess.message) 257 | mess.string = (mess.type === baileys.MessageType.text) ? mess.message.conversation: (mess.data.includes('caption')) ? mess.message[mess.type].caption: (mess.type == baileys.MessageType.extendedText) ? mess.message[mess.type].text: (mess.type == 'buttonsResponseMessage') ? mess.message[mess.type].selectedButtonId: (mess.type == 'listResponseMessage') ? mess.message[mess.type].singleSelectReply.selectedRowId: '' 258 | mess.body = mess.message[mess.type] 259 | mess.from = mess.key.remoteJid 260 | mess.isGroup = mess.from.endsWith('g.us') 261 | mess.sender.jid = mess.isGroup ? mess.participant ? mess.participant: client.user.jid: mess.key.remoteJid 262 | mess.sender.name = client.contacts[mess.sender.jid] ? client.contacts[mess.sender.jid].name || client.contacts[mess.sender.jid].vname || client.contacts[mess.sender.jid].notify || client.contacts[mess.sender.jid].short || 'Unknown': 'Unknown'; 263 | mess.client = {}; 264 | mess.client.name = client.user.name; 265 | mess.client.jid = client.user.jid; 266 | mess.mentionedJid = mess.data.includes('contextInfo') && mess.data.includes('mentionedJid')? mess.message[mess.type].contextInfo.mentionedJid: false; 267 | mess.isText = mess.type == 'conversation' || mess.type == 'extendedTextMessage' 268 | mess.isMedia = !mess.isText 269 | mess.id = mess.key.id 270 | mess.fromMe = mess.key.fromMe 271 | mess.quotedMsg = mess.data.includes('contextInfo') && mess.data.includes('quotedMessage')? { 272 | key: { 273 | remoteJid: mess.from, 274 | fromMe: mess.message[mess.type].contextInfo.participant == client.user.jid, 275 | id: mess.message[mess.type].contextInfo.stanzaId 276 | }, 277 | message: mess.message[mess.type].contextInfo.quotedMessage, 278 | participant: mess.message[mess.type].contextInfo.participant 279 | }: false 280 | mess.isOwner = botinfo.ownerNumber.includes(mess.sender.jid.split('@')[0]) || mess.key.fromMe 281 | mess.groupData = mess.isGroup ? client.chats.get(mess.from): false 282 | mess.groupData = mess.groupData ? { 283 | ...mess.groupData, 284 | ...mess.groupData?.metadata 285 | }: false; 286 | delete mess.groupData.metadata; 287 | delete mess.groupData.messages; 288 | var x = await this.ambilSender(client, mess) || {} 289 | mess.groupData = mess.groupData ? { 290 | ...mess?.groupData, 291 | ...x 292 | }: false 293 | mess.sender = { 294 | ...x?.sender, 295 | ...mess?.sender 296 | } 297 | mess.client = { 298 | ...x?.client, 299 | ...mess?.client 300 | } 301 | 302 | 303 | //function 304 | mess.downloadMsg = async(save, auto_ext = true) => { 305 | if (mess.isText) return; 306 | let buffer = await client.downloadMediaMessage(mess); 307 | let anu = await FileType.fromBuffer(buffer) || { 308 | ext: 'bin', 309 | mime: 'application/octet-stream' 310 | } 311 | if (save) { 312 | save = auto_ext?save+'.'+anu.ext: save 313 | fs.writeFileSync(save, buffer); 314 | return { 315 | buffer, 316 | filename: save, 317 | ...anu 318 | }; 319 | } else { 320 | return { 321 | buffer, 322 | ...anu 323 | }; 324 | } 325 | }; 326 | mess.deleteMsg = async(forAll) => { 327 | if (forAll) return await client.deleteMessage(mess.key.remoteJid, mess.key); 328 | return await client.clearMessage(mess.key); 329 | }; 330 | mess.loadQuotedMsg = async() => { 331 | if (!mess.quotedMsg) return; 332 | return await chatMeta(await client.loadMessage(mess.from, mess.quotedMsg.key.id)) 333 | }; 334 | mess.reloadMsg = async() => { 335 | return await chatMeta(await client.loadMessage(mess.from, mess.key.id)) 336 | }; 337 | mess.resendMsg = async(jid, opt) => { 338 | return await client.sendMessageFromContent(jid, mess.message, opt); 339 | }; 340 | mess.forwardMsg = async(jid, force, opt) => { 341 | let message = await client.generateForwardMessageContent(mess, force) 342 | return client.sendMessageFromContent(jid, message, opt) 343 | } 344 | mess.modifyMsg = async(object) => { 345 | return { 346 | ...mess, 347 | ...object 348 | } 349 | } 350 | mess.groupMetadata = async() => { 351 | if (!mess.isGroup) return; 352 | let groupMetadata = mess.groupData?.participants ? mess.groupData: await client.groupMetadata(mess.from).catch(e => {}); 353 | groupMetadata.client = (groupMetadata.participants.find(res => res.jid == client.user.jid)) || { 354 | isAdmin: false, 355 | isSuperAdmin: false, 356 | jid: client.user.jid 357 | } 358 | groupMetadata.client.isAdmin = groupMetadata?.client?.isAdmin || groupMetadata?.client?.isSuperAdmin 359 | groupMetadata.sender = (groupMetadata.participants.find(ros => ros.jid == mess.sender.jid)) || { 360 | isAdmin: false, 361 | isSuperAdmin: false, 362 | jid: mess.sender.jid 363 | } 364 | groupMetadata.sender.isAdmin = groupMetadata?.sender?.isAdmin || groupMetadata?.sender?.isSuperAdmin 365 | groupMetadata.groupAdmins = groupMetadata.participants.filter(tr => tr.isAdmin || tr.isSuperAdmin) || [] 366 | groupMetadata.groupMembers = groupMetadata.participants.filter(tr => !tr.isAdmin || !tr.isSuperAdmin) || [] 367 | mess.sender = { 368 | ...groupMetadata.sender, 369 | ...mess?.sender 370 | } 371 | mess.client = { 372 | ...groupMetadata.client, 373 | ...mess?.client 374 | } 375 | return { 376 | ...groupMetadata 377 | } 378 | } 379 | mess.quotedMsg = mess.quotedMsg ? await chatMeta(mess.quotedMsg): false 380 | return mess; 381 | }; 382 | return await chatMeta(msg) 383 | } 384 | 385 | async ambilSender(client, mess) { 386 | if (!mess.isGroup) return; 387 | let groupMetadata = mess.groupData?.participants ? mess.groupData: await client.groupMetadata(mess.from).catch(e => {}); 388 | groupMetadata.client = (groupMetadata.participants.find(res => res.jid == client.user.jid)) || { 389 | isAdmin: false, 390 | isSuperAdmin: false, 391 | jid: client.user.jid 392 | } 393 | groupMetadata.client.isAdmin = groupMetadata?.client?.isAdmin || groupMetadata?.client?.isSuperAdmin 394 | groupMetadata.sender = (groupMetadata.participants.find(ros => ros.jid == mess.sender.jid)) || { 395 | isAdmin: false, 396 | isSuperAdmin: false, 397 | jid: mess.sender.jid 398 | } 399 | groupMetadata.sender.isAdmin = groupMetadata?.sender?.isAdmin || groupMetadata?.sender?.isSuperAdmin 400 | groupMetadata.groupAdmins = groupMetadata.participants.filter(tr => tr.isAdmin || tr.isSuperAdmin) || [] 401 | groupMetadata.groupMembers = groupMetadata.participants.filter(tr => !tr.isAdmin || !tr.isSuperAdmin) || [] 402 | mess.sender = { 403 | ...groupMetadata.sender, 404 | ...mess?.sender 405 | } 406 | mess.client = { 407 | ...groupMetadata.client, 408 | ...mess?.client 409 | } 410 | return { 411 | ...groupMetadata 412 | } 413 | } 414 | 415 | async resizeImage(path, size) { 416 | if (!fs.existsSync('tmp')) fs.mkdirSync('tmp'); 417 | let buffer = await this.getBuffer(path, './tmp/'+Date.now().toString()) 418 | if (!buffer.mime.includes('image')) return 419 | return new Promise((resolve, reject) => { 420 | exec(`mogrify -resize ${size} ${buffer.filename}`, (e, o) => { 421 | if (e) return reject(e) 422 | resolve(fs.readFileSync(buffer.filename)) 423 | fs.unlinkSync(buffer.filename) 424 | return 425 | }) 426 | }) 427 | } 428 | 429 | async getBuffer(path, save, auto_ext = true) { 430 | let buffer = Buffer.isBuffer(path) ? path: /^data:.?\/.?;base64,/i.test(path) ? Buffer.from(path.split`,`[1], 'base64'): /^https?:\/\//.test(path) ? await (await fetch(path, 431 | { 432 | headers: { 433 | 'User-Agent': fakeUa()}})).buffer(): fs.existsSync(path) ? fs.readFileSync(path): typeof path === 'string' ? path: Buffer.alloc(0); 434 | let anu = await FileType.fromBuffer(buffer) || { 435 | ext: 'bin', mime: 'application/octet-stream' 436 | } 437 | if (save) { 438 | save = auto_ext?save+'.'+anu.ext: save 439 | fs.writeFileSync(save, buffer) 440 | return { 441 | filename: save, 442 | buffer, 443 | ...anu 444 | } 445 | } else { 446 | return { 447 | buffer, 448 | ...anu 449 | } 450 | } 451 | } 452 | 453 | async searchImage(query) { 454 | return new Promise(async (resolve, reject) => { 455 | await googleImage(query, resultImage) 456 | function resultImage(error, result) { 457 | if (error) reject(error) 458 | if (result) resolve(result) 459 | } 460 | }) 461 | } 462 | 463 | async delay(ms) { 464 | return new Promise(resolve => setTimeout(resolve, ms)) 465 | } 466 | 467 | async run(client) { 468 | try { 469 | await this.start(); 470 | for (let a of fs.readdirSync('./lib/command')) require(`./command/${a}`) 471 | for (let b of fs.readdirSync('./lib/actions')) require(`./actions/${b}`); 472 | await this.delay(1000); 473 | this.animate.succeed('Loading', { 474 | text: 'Checking And Adding New Command Succeed' 475 | }); 476 | client.logger.level = 'error'; 477 | client.browserDescription = ['Zbin-Wabot', 478 | 'Desktop', 479 | '3.0']; 480 | client.version = [2, 481 | 2140, 482 | 12]; 483 | botinfo.session && await client.loadAuthInfo(botinfo.session); 484 | await client.connect({ 485 | timeoutMs: 30000 486 | }); 487 | } catch(e) { 488 | console.log(e) 489 | } 490 | } 491 | 492 | async start () { 493 | console.clear() 494 | let kali = fs.readFileSync('./src/kali.cat').toString() 495 | console.log(this.logColor(kali, 'silver')) 496 | console.log(this.logColor(`Starting Running Bot......`, 'silver')) 497 | await this.delay(3000) 498 | console.clear() 499 | console.log(this.logColor(` _____ __ _ ____ __ 500 | /__ / / /_ (_)___ / __ )____ / /_ 501 | / / / __ \\/ / __ \\______/ __ / __ \\/ __/ 502 | / /__/ /_/ / / / / /_____/ /_/ / /_/ / /_ 503 | /____/_.___/_/_/ /_/ /_____/\\____/\\__/ 504 | 505 | `, 'silver')) 506 | await this.delay(1) 507 | } 508 | 509 | 510 | async googleSearch(query) { 511 | return googleSearch({ 512 | query 513 | }) 514 | } 515 | } -------------------------------------------------------------------------------- /lib/waconnection.js: -------------------------------------------------------------------------------- 1 | const baileys = require('@adiwajshing/baileys') 2 | const jimp = require('jimp') 3 | const fs = require('fs') 4 | const fetch = require('node-fetch'); 5 | const util = require('util'); 6 | const fakeUa = require('fake-useragent'); 7 | const ffmpeg = require('fluent-ffmpeg'); 8 | const FileType = require('file-type') 9 | const { 10 | exec, 11 | spawn, 12 | execSync 13 | } = require('child_process'); 14 | 15 | module.exports = class WAConnection extends baileys.WAConnection { 16 | async reply(mess, text, opt) { 17 | return await this.sendMessage(mess.key.remoteJid, util.format(text), baileys.MessageType.extendedText, { 18 | quoted: mess, ...opt 19 | }) 20 | } 21 | async getBuffer(path, save, auto_ext = true) { 22 | let buffer = Buffer.isBuffer(path) ? path: /^data:.?\/.?;base64,/i.test(path) ? Buffer.from(path.split`,`[1], 'base64'): /^https?:\/\//.test(path) ? await (await fetch(path, { 23 | headers: { 24 | 'User-Agent': fakeUa()}})).buffer(): fs.existsSync(path) ? fs.readFileSync(path): typeof path === 'string' ? path: Buffer.alloc(0); 25 | let anu = await FileType.fromBuffer(buffer) || { 26 | ext: 'bin', 27 | mime: 'application/octet-stream' 28 | } 29 | if (save) { 30 | save = auto_ext?save+'.'+anu.ext: save 31 | fs.writeFileSync(save, buffer) 32 | return { 33 | filename: save, 34 | buffer, 35 | ...anu 36 | } 37 | } else { 38 | return { 39 | buffer, 40 | ...anu 41 | } 42 | } 43 | } 44 | async sendMessageFromContent(jid, obj, opt = {}) { 45 | let prepare = await this.prepareMessageFromContent(jid, obj, opt) 46 | await this.relayWAMessage(prepare) 47 | return prepare 48 | } 49 | async fakeReply(jid, message, type, opt, fakeJid, participant, fakeMessage) { 50 | return await this.sendMessage(jid, message, type, { 51 | quoted: { 52 | key: { 53 | fromMe: jid == this.user.jid, participant, remoteJid: fakeJid 54 | }, 55 | "message": fakeMessage 56 | }, 57 | ...opt 58 | }) 59 | } 60 | getMentionedJidList(text) { 61 | try { 62 | return text.match(/@(\d*)/g).map(x => x.replace('@', '')+'@s.whatsapp.net') || []; 63 | } catch(e) { 64 | return [] 65 | } 66 | } 67 | async prepareSticker(path, exifFile) { 68 | let getBuf = (await this.getBuffer(path)) 69 | let { 70 | ext, 71 | mime 72 | } = getBuf 73 | let buf = getBuf.buffer 74 | if (!fs.existsSync("./tmp")) fs.mkdirSync('tmp') 75 | let fileName = `./tmp/${Date.now()}.${ext}` 76 | let output = fileName.replace(ext, 'webp') 77 | fs.writeFileSync(fileName, buf) 78 | if (ext == 'webp') { 79 | if (exifFile) { 80 | return new Promise((resolve, reject) => { 81 | exec(`webpmux -set exif ${exifFile} ${output} -o ${output}`, (err) => { 82 | if (err) throw err 83 | let result = fs.readFileSync(output) 84 | fs.unlinkSync(output) 85 | resolve(result) 86 | }) 87 | }) 88 | } else { 89 | let result = fs.readFileSync(output) 90 | fs.unlinkSync(output) 91 | return result 92 | } 93 | } 94 | return new Promise(async(resolve, reject) => { 95 | await ffmpeg(fileName).input(fileName).on('error', function (err) { 96 | fs.unlinkSync(fileName) 97 | reject(err) 98 | }).on('end', function () { 99 | if (exifFile) { 100 | exec(`webpmux -set exif ${exifFile} ${output} -o ${output}`, (err) => { 101 | if (err) return err 102 | let result = fs.readFileSync(output) 103 | fs.unlinkSync(fileName) 104 | fs.unlinkSync(output) 105 | resolve(result) 106 | }) 107 | } else { 108 | let result = fs.readFileSync(output) 109 | fs.unlinkSync(fileName) 110 | fs.unlinkSync(output) 111 | resolve(result) 112 | } 113 | }).addOutputOptions([`-vcodec`, 114 | `libwebp`, 115 | `-vf`, 116 | `scale='min(320,iw)':min'(320,ih)':force_original_aspect_ratio=decrease,fps=15, pad=320:320:-1:-1:color=white@0.0, split [a][b]; [a] palettegen=reserve_transparent=on:transparency_color=ffffff [p]; [b][p] paletteuse`]).toFormat('webp').save(output) 117 | }) 118 | } 119 | async sendImage(jid, path, caption, opt) { 120 | let buff = (await this.getBuffer(path)).buffer 121 | return await this.sendMessage(jid, buff, 'imageMessage', { 122 | caption, ...opt 123 | }) 124 | } 125 | async sendVideo(jid, path, caption, opt) { 126 | let buff = (await this.getBuffer(path)).buffer 127 | return await this.sendMessage(jid, buff, 'videoMessage', { 128 | caption, ...opt 129 | }) 130 | } 131 | async sendLocation(jid, property, opt) { 132 | return await this.sendMessageFromContent(jid, { 133 | locationMessage: property 134 | }, opt) 135 | } 136 | async sendLiveLocation(jid, property, opt) { 137 | return await this.sendMessageFromContent(jid, { 138 | liveLocationMessage: property 139 | }, opt) 140 | } 141 | async sendProduct(jid, property, opt) { 142 | return await this.sendMessageFromContent(jid, { 143 | productMessage: property 144 | }, opt) 145 | } 146 | async sendButton(jid, message, type, button = [], opt = {}) { 147 | message = ( 148 | await this.prepareMessage(`0@s.whatsapp.net`, 149 | message, 150 | type, 151 | opt).catch(async(e) => { 152 | let err = util.format(e).toLowerCase() 153 | if (err.includes('marker')) { 154 | return await this.prepareMessage(`0@s.whatsapp.net`, message, type, { 155 | ...opt, thumbnail: await this.resizeImage(message, '48x48')}) 156 | } else if (err.includes('this.isZero')) { 157 | return await this.prepareMessage(`0@s.whatsapp.net`, message, type, { 158 | ...opt, quoted: null 159 | }) 160 | } 161 | }) 162 | ).message; 163 | let isMedia = !(type == 'conversation' || type == 'extendedTextMessage'); 164 | message = message[type] || message; 165 | let headerType = type 166 | .toUpperCase() 167 | .replace('MESSAGE', '') 168 | .replace(`EXTENDED`, '') 169 | .replace(`CONVERSATION`, 'EMPTY') 170 | .trim(); 171 | let buttons = []; 172 | for (let a of button) { 173 | buttons.push({ 174 | type: 'RESPONSE', buttonText: { 175 | displayText: a.text 176 | }, buttonId: a.id 177 | }); 178 | } 179 | let contentText = 180 | opt.content || (type == baileys.MessageType?.text 181 | ? message.extendedTextMessage?.text: Object.keys(message).includes('caption') 182 | ? message.caption: ' '); 183 | let footerText = opt.footer; 184 | let content = isMedia ? { 185 | [type]: message 186 | }: headerType == 'TEXT' ? { 187 | ...message 188 | }: {}; 189 | return this.sendMessageFromContent( 190 | jid, 191 | { 192 | buttonsMessage: { 193 | contentText, footerText, headerType, buttons, ...content 194 | } 195 | }, 196 | { 197 | ...opt 198 | }, 199 | ); 200 | } 201 | async sendFileFromUrl(id, url, qu, caption = "", filename = "file", opt = {}) { 202 | const buffers = await axios(url, { 203 | headers: { 204 | 'User-Agent': 'Mozilla/5.0 (BlackBerry; U; BlackBerry 9900; en) AppleWebKit/534.11+ (KHTML, like Gecko) Version/7.0.0.585 Mobile Safari/534.11+' 205 | }, responseType: "arraybuffer", ...opt.headers 206 | }).catch(e => { 207 | throw e 208 | }) 209 | var mimtype = buffers.headers["content-type"] 210 | mimtype = mimtype == 'image/gif' ? 'video/gif': mimtype == 'image/jpg' ? 'image/jpeg': mimtype 211 | const msgtype = mimtype && mimtype.includes('image') ? 'imageMessage': mimtype && mimtype.includes('audio') ? 'audioMessage': mimtype && mimtype.includes('video') || mimtype && mimtype.includes('gif') ? 'videoMessage': 'documentMessage' 212 | filename = mimtype == 'image/jpeg' ? null: filename 213 | mimtype = mimtype == 'image/jpeg' ? null: mimtype 214 | return await this.sendMessage(id, buffers.data, msgtype, { 215 | quoted: qu, mimetype: mimtype, filename: filename, caption: caption, contextInfo: { 216 | "mentionedJid": this.getMentionedJidList(caption)}, ...opt 217 | }) 218 | } 219 | async sendSticker(jid, path, opt, exifFile) { 220 | let prepare; 221 | if (exifFile) { 222 | prepare = await this.prepareSticker(path, exifFile) 223 | } else { 224 | prepare = await this.prepareSticker(path) 225 | } 226 | return await this.sendMessage(jid, prepare, baileys.MessageType.sticker, opt) 227 | } 228 | 229 | async resizeImage(path, size) { 230 | if (!fs.existsSync('tmp')) fs.mkdirSync('tmp'); 231 | let buffer = await this.getBuffer(path, './tmp/'+Date.now().toString()) 232 | if (!buffer.mime.includes('image')) return 233 | return new Promise((resolve, reject) => { 234 | exec(`mogrify -resize ${size} ${buffer.filename}`, (e, o) => { 235 | if (e) return reject(e) 236 | resolve(fs.readFileSync(buffer.filename)) 237 | fs.unlinkSync(buffer.filename) 238 | return 239 | }) 240 | }) 241 | } 242 | 243 | async sendMessage(id, message, type, options = {}) { 244 | let waMessage = await this.prepareMessage(id, message, type, options).catch(async(e) => { 245 | let err = util.format(e).toLowerCase() 246 | if (err.includes('marker')) { 247 | return await this.prepareMessage(id, message, type, { 248 | ...options, thumbnail: await this.resizeImage(message, '48x48')}) 249 | } else if (err.includes('this.isZero')) { 250 | return await this.prepareMessage(id, message, type, { 251 | ...options, quoted: null 252 | }) 253 | } 254 | }) 255 | await this.relayWAMessage(waMessage, 256 | { 257 | waitForAck: options.waitForAck !== false 258 | }); 259 | return waMessage; 260 | } 261 | } 262 | -------------------------------------------------------------------------------- /main.js: -------------------------------------------------------------------------------- 1 | const { exec,execSync,spawn } = require('child_process'); 2 | const Functions = require('./lib/functions.js'); 3 | const Command = require('./lib/command.js'); 4 | const WAConnection = require('./lib/waconnection.js'); 5 | 6 | global.baileys = require('@adiwajshing/baileys'); 7 | global.botinfo = require('./src/json/botInfo.json'); 8 | global.functions = new Functions(); 9 | global.client = new WAConnection(); 10 | global.cmd = new Command(client, botinfo, functions); 11 | global.logo = [] 12 | global.clients = []; 13 | global.used_logo = 0 14 | 15 | functions.run(client); 16 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Zbin-Wabot", 3 | "version": "2.5.4", 4 | "description": "Bot Wea Mudah Digunakan", 5 | "main": "main.js", 6 | "directories": { 7 | "lib": "lib", 8 | "src": "src", 9 | "plugins": "plugins" 10 | }, 11 | "scripts": { 12 | "start": "node index.js" 13 | }, 14 | "dependencies": { 15 | "@adiwajshing/baileys": "^3.5.2", 16 | "async": "^2.4.1", 17 | "axios": "^0.21.1", 18 | "qrcode": "^1.4.4", 19 | "parse-ms": "*", 20 | "cheerio": "^1.0.0-rc.5", 21 | "escape-string-regexp": "^1.0.5", 22 | "fake-useragent": "^1.0.1", 23 | "file-type": "^16.5.0", 24 | "fluent-ffmpeg": "^2.1.2", 25 | "form-data": "^4.0.0", 26 | "g-i-s": "^2.1.6", 27 | "google-it": "^1.6.2", 28 | "moment-timezone": "^0.5.32", 29 | "node-fetch": "^2.6.1", 30 | "spinnies": "^0.5.1", 31 | "syntax-error": "^1.4.0", 32 | "util": "^0.12.3", 33 | "yt-search": "^2.7.5" 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /plugins/android1.js: -------------------------------------------------------------------------------- 1 | const cheerio = require('cheerio') 2 | const axios = require('axios') 3 | 4 | const searchAndro1 = async(aplikasi) => { 5 | const res = await axios.get(`https://an1.com/tags/MOD/?story=${aplikasi}&do=search&subaction=search`) 6 | let hasil = [] 7 | const $ = cheerio.load(res.data) 8 | $('div').find('.search-results > .inner').each(function(a, b) { 9 | let judul = $(b).find('.left > .title').find('a').text() 10 | let link = $(b).find('.left > .title').find('a').attr('href') 11 | let thumb = $(b).find('span > img').attr('src') 12 | hasil.push({ judul, link, thumb }) 13 | }) 14 | return hasil 15 | } 16 | const downAndro1 = async (linkdown) => { 17 | const base = `https://an1.com/` 18 | const des = await axios.get(linkdown) 19 | const sup = cheerio.load(des.data) 20 | const k = sup('div').find('.white-box') 21 | result = [] 22 | let judul = sup(k).find('div > h1').text() 23 | 24 | let thumb = sup(k).find('div > div > img').attr('src') 25 | 26 | let dev = sup(k).find('div > .text.dev > span').text() 27 | 28 | let andro = sup(k).find 29 | ('div > .text.android').text() 30 | 31 | let versi = sup(k).find 32 | ('div > .text.version').text() 33 | 34 | let genre = sup(k).find('div > .text.class').text() 35 | 36 | let updated = sup(k).find('.inner > .item > span > time').text() 37 | 38 | let size = sup('div.item:nth-child(2) > span:nth-child(2)').text() 39 | 40 | let install = sup('div.item:nth-child(3) > span:nth-child(2)').text() 41 | 42 | let rated = sup('div.item:nth-child(4) > span:nth-child(2)').text() 43 | 44 | let link = base + sup(k).find('.get-product-holder > a').attr('href') 45 | 46 | const bes = await axios.get(link) 47 | 48 | let dl_link = sup('div').find('span').toString() 49 | 50 | result.push({ judul, thumb, dev, andro, versi, genre, updated, link, size, install, rated}) 51 | 52 | return result 53 | } 54 | 55 | module.exports = { searchAndro1, downAndro1} -------------------------------------------------------------------------------- /plugins/cnn.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | const cheerio = require('cheerio') 3 | 4 | const newsCnn = async(genre) => { 5 | const res = await axios.get(`https://www.cnnindonesia.com/${genre}`) 6 | const $ = cheerio.load(res.data) 7 | const hasil = [] 8 | $('article').each(function(a, b) { 9 | const link = $(b).find('a').attr('href') 10 | const thumb = $(b).find('img').attr('src') 11 | const judul = $(b).find('img').attr('alt') 12 | hasil.push({ judul, link, thumb }) 13 | }) 14 | return hasil 15 | } 16 | 17 | module.exports = { newsCnn } -------------------------------------------------------------------------------- /plugins/covid.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | const cheerio = require('cheerio') 3 | 4 | const covid = async () => { 5 | const res = await axios.get(`https://www.worldometers.info/coronavirus/country/indonesia/`) 6 | const $ = cheerio.load(res.data) 7 | hasil = [] 8 | a = $('div#maincounter-wrap') 9 | kasus = $(a).find('div > span').eq(0).text() 10 | kematian = $(a).find('div > span').eq(1).text() 11 | sembuh = $(a).find('div > span').eq(2).text() 12 | hasil.push({ kasus, kematian, sembuh}) 13 | return hasil 14 | } 15 | 16 | 17 | module.exports = { covid } -------------------------------------------------------------------------------- /plugins/dafont.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | const cheerio = require('cheerio') 3 | 4 | const dafontSearch = async (query) => { 5 | const base = `https://www.dafont.com` 6 | 7 | const res = await axios.get(`${base}/search.php?q=${query}`) 8 | 9 | const $ = cheerio.load(res.data) 10 | const hasil = [] 11 | const total = $('div.dffont2').text().replace(` fonts on DaFont for ${query}`, '') 12 | 13 | $('div').find('div.container > div > div.preview').each(function(a, b) { 14 | 15 | $('div').find('div.container > div > div.lv1left.dfbg').each(function(c, d) { 16 | 17 | $('div').find('div.container > div > div.lv1right.dfbg').each(function(e, f) { 18 | 19 | let link = `${base}/` + $(b).find('a').attr('href') 20 | let judul = $(d).text() 21 | let style = $(f).text() 22 | hasil.push({ judul, style, link, total}) 23 | }) 24 | }) 25 | }) 26 | return hasil 27 | } 28 | 29 | const dafontDown = async (link) => { 30 | const des = await axios.get(link) 31 | const sup = cheerio.load(des.data) 32 | const result = [] 33 | let style = sup('div').find('div.container > div > div.lv1right.dfbg').text() 34 | 35 | let judul = sup('div').find('div.container > div > div.lv1left.dfbg').text() 36 | 37 | try { 38 | isi = sup('div').find('div.container > div > span').text().split('.ttf') 39 | output = sup('div').find('div.container > div > span').eq(0).text().replace('ttf' , 'zip') 40 | } catch { 41 | isi = sup('div').find('div.container > div > span').text().split('.otf') 42 | output = sup('div').find('div.container > div > span').eq(0).text().replace('otf' , 'zip') 43 | } 44 | 45 | let down = 'http:' + sup('div').find('div.container > div > div.dlbox > a').attr('href') 46 | result.push({ style, judul, isi, output, down}) 47 | return result 48 | } 49 | 50 | module.exports = { dafontSearch, dafontDown} -------------------------------------------------------------------------------- /plugins/fb.js: -------------------------------------------------------------------------------- 1 | const fetch = require('node-fetch') 2 | 3 | const fbDown = async (fbLink) => { 4 | function post(url, formdata) { 5 | return fetch(url, { 6 | method: 'POST', 7 | headers: { 8 | accept: "*/*", 9 | 'X-Requested-With': "XMLHttpRequest", 10 | 'content-type': "application/x-www-form-urlencoded; charset=UTF-8" 11 | }, 12 | body: new URLSearchParams(Object.entries(formdata)) 13 | }) 14 | } 15 | 16 | const res = await post('https://saveas.co/system/action.php', { 17 | url: fbLink, 18 | token: '' 19 | }) 20 | const mela = await res.json() 21 | const hasil = [] 22 | let judul = mela.title 23 | let source = mela.source 24 | let thumb = mela.thumbnail 25 | let link = mela.links[1].url 26 | let size = mela.links[1].size 27 | let quality = mela.links[1].quality 28 | let type = mela.links[1].type 29 | hasil.push({ judul, source, thumb, link, size, quality, type }) 30 | return hasil 31 | } 32 | 33 | module.exports = { fbDown } -------------------------------------------------------------------------------- /plugins/gif.js: -------------------------------------------------------------------------------- 1 | const cheerio = require('cheerio'); 2 | const FormData = require('form-data') 3 | const { default: Axios } = require('axios'); 4 | const { exec } = require('child_process'); 5 | const fs = require('fs'); 6 | 7 | function webp2gifFile(path) { 8 | return new Promise((resolve, reject) => { 9 | const bodyForm = new FormData() 10 | bodyForm.append('new-image-url', '') 11 | bodyForm.append('new-image', fs.createReadStream(path)) 12 | Axios({ 13 | method: 'post', 14 | url: 'https://s6.ezgif.com/webp-to-mp4', 15 | data: bodyForm, 16 | headers: { 17 | 'Content-Type': `multipart/form-data; boundary=${bodyForm._boundary}` 18 | } 19 | }).then(({ data }) => { 20 | const bodyFormThen = new FormData() 21 | const $ = cheerio.load(data) 22 | const file = $('input[name="file"]').attr('value') 23 | const token = $('input[name="token"]').attr('value') 24 | const convert = $('input[name="file"]').attr('value') 25 | const gotdata = { 26 | file: file, 27 | token: token, 28 | convert: convert 29 | } 30 | bodyFormThen.append('file', gotdata.file) 31 | bodyFormThen.append('token', gotdata.token) 32 | bodyFormThen.append('convert', gotdata.convert) 33 | Axios({ 34 | method: 'post', 35 | url: 'https://ezgif.com/webp-to-mp4/' + gotdata.file, 36 | data: bodyFormThen, 37 | headers: { 38 | 'Content-Type': `multipart/form-data; boundary=${bodyFormThen._boundary}` 39 | } 40 | }).then(({ data }) => { 41 | const $ = cheerio.load(data) 42 | const result = 'https:' + $('div#output > p.outfile > video > source').attr('src') 43 | resolve({ 44 | status: true, 45 | message: "Created By MRHRTZ", 46 | result: result 47 | }) 48 | }).catch(reject) 49 | }).catch(reject) 50 | }) 51 | } 52 | 53 | exports.webp2gifFile = webp2gifFile -------------------------------------------------------------------------------- /plugins/herodetail.js: -------------------------------------------------------------------------------- 1 | const cheerio = require('cheerio'); 2 | const { default: Axios } = require('axios'); 3 | 4 | function herodetails(name) { 5 | return new Promise((resolve, reject) => { 6 | var splitStr = name.toLowerCase().split(' '); 7 | for (var i = 0; i < splitStr.length; i++) { 8 | splitStr[i] = splitStr[i].charAt(0).toUpperCase() + splitStr[i].substring(1); 9 | } 10 | const que = splitStr.join(' ') 11 | Axios.get('https://mobile-legends.fandom.com/wiki/' + que) 12 | .then(({ data }) => { 13 | const $ = cheerio.load(data) 14 | let mw = [] 15 | let attrib = [] 16 | let skill = [] 17 | const name = $('#mw-content-text > div > div > div > div > div > div > table > tbody > tr > td > table > tbody > tr > td > font > b').text() 18 | $('.mw-headline').get().map((res) => { 19 | const mwna = $(res).text() 20 | mw.push(mwna) 21 | }) 22 | $('#mw-content-text > div > div > div > div > div > div > table > tbody > tr > td').get().map((rest) => { 23 | const haz = $(rest).text().replace(/\n/g,'') 24 | attrib.push(haz) 25 | }) 26 | $('#mw-content-text > div > div > div > div > div > div > table > tbody > tr > td > div.progressbar-small.progressbar > div').get().map((rest) => { 27 | skill.push($(rest).attr('style').replace('width:','')) 28 | }) 29 | Axios.get('https://mobile-legends.fandom.com/wiki/' + que + '/Story') 30 | .then(({ data }) => { 31 | const $ = cheerio.load(data) 32 | let pre = [] 33 | $('#mw-content-text > div > p').get().map((rest) => { 34 | pre.push($(rest).text()) 35 | }) 36 | const story = pre.slice(3).join('\n') 37 | const items = [] 38 | const character = [] 39 | $('#mw-content-text > div > aside > section > div').get().map((rest) => { 40 | character.push($(rest).text().replace(/\n\t\n\t\t/g, '').replace(/\n\t\n\t/g,'').replace(/\n/g,'')) 41 | }) 42 | $('#mw-content-text > div > aside > div').get().map((rest) => { 43 | items.push($(rest).text().replace(/\n\t\n\t\t/g, '').replace(/\n\t\n\t/g,'').replace(/\n/g,'')) 44 | }) 45 | const img = $('#mw-content-text > div > aside > figure > a').attr('href') 46 | const chara = character.slice(0,2) 47 | const result = { 48 | status: 200, 49 | hero_name: name + ` ( ${mw[0].replace('CV:',' CV:')} )`, 50 | entrance_quotes: attrib[2].replace('Entrance Quotes','').replace('\n',''), 51 | hero_feature: attrib[attrib.length - 1].replace('Hero Feature',''), 52 | image: img, 53 | items: items, 54 | character: { 55 | chara 56 | }, 57 | attributes: { 58 | movement_speed: attrib[12].replace('● Movement Speed',''), 59 | physical_attack: attrib[13].replace('● Physical Attack',''), 60 | magic_power: attrib[14].replace('● Magic Power',''), 61 | attack_speed: attrib[15].replace('● Attack Speed',''), 62 | physical_defense: attrib[16].replace('● Physical Defense',''), 63 | magic_defense: attrib[17].replace('● Magic Defense',''), 64 | basic_atk_crit_rate: attrib[18].replace('● Basic ATK Crit Rate',''), 65 | hp: attrib[19].replace('● HP',''), 66 | mana: attrib[20].replace('● Mana',''), 67 | ability_crit_rate: attrib[21].replace('● Ability Crit Rate',''), 68 | hp_regen: attrib[22].replace('● HP Regen',''), 69 | mana_regen: attrib[23].replace('● Mana Regen','') 70 | }, 71 | price: { 72 | battle_point: mw[1].split('|')[0].replace(/ /g,''), 73 | diamond: mw[1].split('|')[1].replace(/ /g,''), 74 | hero_fragment: mw[1].split('|')[2] ? mw[1].split('|')[2].replace(/ /g,'') : 'none' 75 | }, 76 | role: mw[2], 77 | skill: { 78 | durability: skill[0], 79 | offense: skill[1], 80 | skill_effects: skill[2], 81 | difficulty: skill[3] 82 | }, 83 | speciality: mw[3], 84 | laning_recommendation: mw[4], 85 | release_date: mw[5], 86 | background_story: story 87 | } 88 | resolve(result) 89 | }).catch((e) => reject({ status: 404, message: e.message })) 90 | }).catch((e) => reject({ status: 404, message: e.message })) 91 | }) 92 | } 93 | 94 | exports.herodetails = herodetails -------------------------------------------------------------------------------- /plugins/herolist.js: -------------------------------------------------------------------------------- 1 | const cheerio = require('cheerio') 2 | const { default: Axios } = require('axios') 3 | 4 | function herolist(){ 5 | return new Promise((resolve, reject) => { 6 | Axios.get('https://mobile-legends.fandom.com/wiki/Mobile_Legends:_Bang_Bang_Wiki') 7 | .then(({ data }) => { 8 | const $ = cheerio.load(data) 9 | let data_hero = [] 10 | let url = [] 11 | $('div > div > span > span > a').get().map((result) => { 12 | const name = decodeURIComponent($(result).attr('href').replace('/wiki/','')) 13 | const urln = 'https://mobile-legends.fandom.com' + $(result).attr('href') 14 | data_hero.push(name) 15 | url.push(urln) 16 | }) 17 | resolve({ status: 200, hero: data_hero }) 18 | }).catch((e) => reject({ status: 404, message: e.message })) 19 | }) 20 | } 21 | 22 | exports.herolist = herolist -------------------------------------------------------------------------------- /plugins/ig.js: -------------------------------------------------------------------------------- 1 | const cheerio = require('cheerio') 2 | const fetch = require('node-fetch') 3 | 4 | const fotoIg = async (igLink) => { 5 | function post(url, formdata) { 6 | return fetch(url, { 7 | method: 'POST', 8 | headers: { 9 | accept: "*/*", 10 | 'X-Requested-With': "XMLHttpRequest", 11 | 'content-type': "application/x-www-form-urlencoded; charset=UTF-8" 12 | }, 13 | body: new URLSearchParams(Object.entries(formdata)) 14 | }) 15 | } 16 | const hasil = [] 17 | const res = await post('https://igdownloader.com/ajax', { 18 | link: igLink, 19 | downloader: 'photo' 20 | }) 21 | const mela = await res.json() 22 | const $ = cheerio.load(mela.html) 23 | let foto = $('div').find('.img-block > div > div.post > img').attr('src') 24 | hasil.push({ foto }) 25 | return hasil 26 | } 27 | 28 | const videoIg = async (igLink) => { 29 | function post(url, formdata) { 30 | return fetch(url, { 31 | method: 'POST', 32 | headers: { 33 | accept: "*/*", 34 | 'X-Requested-With': "XMLHttpRequest", 35 | 'content-type': "application/x-www-form-urlencoded; charset=UTF-8" 36 | }, 37 | body: new URLSearchParams(Object.entries(formdata)) 38 | }) 39 | } 40 | hasil = [] 41 | res = await post('https://igdownloader.com/ajax', { 42 | link: igLink, 43 | downloader: 'video' 44 | }) 45 | mela = await res.json() 46 | $ = cheerio.load(mela.html) 47 | let video = $('div').find('.img-block > div > div.post').attr('data-src') 48 | hasil.push({ video}) 49 | return hasil 50 | } 51 | 52 | module.exports = { fotoIg, videoIg} -------------------------------------------------------------------------------- /plugins/jagokata.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | const cheerio = require('cheerio') 3 | 4 | const jagoKata = async (query) => { 5 | const base = `https://jagokata.com/kata-bijak/kata-${query}.html` 6 | const des = await axios.get(base) 7 | const sup = cheerio.load(des.data) 8 | var page = sup('h4 > strong').eq(2).text() / 10 9 | page = parseInt(page) 10 | const randomPage = Math.floor(Math.random() * page) 11 | const res = await axios.get(`${base}?page=${randomPage}`) 12 | const $ = cheerio.load(res.data) 13 | const hasil = [] 14 | const list = $('ul > li') 15 | const random = Math.floor(Math.random() * 10) 16 | const isi = $(list).find('q.fbquote').eq(random).text() 17 | 18 | var by = $(list).find('div > div > a').eq(random).text() 19 | by = by ? by : "Kang Galon" 20 | hasil.push({ isi, by }) 21 | return hasil 22 | } 23 | 24 | module.exports = { jagoKata } -------------------------------------------------------------------------------- /plugins/lirik.js: -------------------------------------------------------------------------------- 1 | const cheerio = require('cheerio') 2 | const axios = require('axios') 3 | 4 | const lirikLagu = async (query) => { 5 | const res = await axios.get(`https://www.musixmatch.com/search/${query}`) 6 | const sup = cheerio.load(res.data) 7 | const hasil = [] 8 | const b = sup('#site').find('div > div > div > div > ul > li:nth-child(1) > div > div > div') 9 | let link = `https://www.musixmatch.com` + sup(b).find('h2 > a').attr('href') 10 | 11 | const des = await axios.get(link) 12 | 13 | const soup = cheerio.load(des.data) 14 | 15 | const result = soup('#site').find('.mxm-lyrics__content > .lyrics__content__ok').text() 16 | 17 | hasil.push({ result}) 18 | return hasil 19 | } 20 | 21 | module.exports = { lirikLagu } -------------------------------------------------------------------------------- /plugins/mediafire.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | const cheerio = require('cheerio') 3 | 4 | const mediafireDl = async (url) => { 5 | const res = await axios.get(url) 6 | const $ = cheerio.load(res.data) 7 | const hasil = [] 8 | const link = $('a#downloadButton').attr('href') 9 | const size = $('a#downloadButton').text().replace('Download', '').replace('(', '').replace(')', '').replace('\n', '').replace('\n', '').replace(' ', '') 10 | const seplit = link.split('/') 11 | const nama = seplit[5] 12 | mime = nama.split('.') 13 | mime = mime[1] 14 | hasil.push({ nama, mime, size, link }) 15 | return hasil 16 | } 17 | 18 | 19 | module.exports = { mediafireDl } -------------------------------------------------------------------------------- /plugins/otak.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | const cheerio = require('cheerio') 3 | 4 | 5 | const onGoing = async (p) => { 6 | const res = await axios.get(`https://otakudesu.moe/ongoing-anime`) 7 | const $ = cheerio.load(res.data) 8 | const result = [] 9 | $('.venz').find('li > div.detpost').each(function(c, d) { 10 | const judul = $(d).find('div.thumb > a > div.thumbz > h2.jdlflm').text() 11 | const thumb = $(d).find('div.thumb > a > div.thumbz > img').attr('src') 12 | const eps = $(d).find('div.epz').text() 13 | const hri = $(d).find('div.epztipe').text() 14 | const link = $(d).find('div.thumb > a').attr('href') 15 | const tgl = $(d).find('div.newnime').text() 16 | result.push({ judul, thumb, eps, hri, tgl, link }) 17 | }) 18 | return result 19 | } 20 | 21 | const otakuSearch = async (search) => { 22 | const res_ = await axios.get(`https://otakudesu.moe/?s=${search}&post_type=anime`) 23 | const sopp = cheerio.load(res_.data) 24 | const hasil = [] 25 | const link_dl = {} 26 | const judul_ = sopp('h2').eq(0).text() 27 | const link_ = sopp('h2 > a').attr('title') 28 | const thumb_ = sopp('li > img').attr('src') 29 | const genre = sopp('li > div.set').eq(0).text().replace('Genres : ','') 30 | const status = sopp('li > div.set').eq(1).text().replace('Status : ','') 31 | const rating = sopp('li > div.set').eq(2).text().replace('Rating : ','') 32 | const ress_ = await axios.get(`${link_}`) 33 | const soup = cheerio.load(ress_.data) 34 | const producer = soup(' div.venser > div.fotoanime > div.infozin > div.infozingle > p:nth-child(4)').text().replace('Produser: ','') 35 | const studio = soup(' div.venser > div.fotoanime > div.infozin > div.infozingle > p:nth-child(10)').text().replace('Studio: ','') 36 | const total_eps = soup(' div.venser > div.fotoanime > div.infozin > div.infozingle > p:nth-child(7)').text().replace('Total Episode: ','') 37 | const japanese_title = soup(' div.venser > div.fotoanime > div.infozin > div.infozingle > p:nth-child(2)').text().replace('Japanese: ','') 38 | const tipe = soup(' div.venser > div.fotoanime > div.infozin > div.infozingle > p:nth-child(5)').text().replace('Tipe: ','') 39 | const durasi = soup(' div.venser > div.fotoanime > div.infozin > div.infozingle > p:nth-child(8)').text().replace('Durasi: ','') 40 | const tgl_rilis = soup(' div.venser > div.fotoanime > div.infozin > div.infozingle > p:nth-child(9)').text().replace('Tanggal Rilis: ','') 41 | const sinopsis = soup(' div.venser > div.fotoanime > div.sinopc > p').text() 42 | const batch = soup(' div.venser > div.episodelist > ul > li >span > a').attr('href') 43 | const resss_ = await axios.get(`${batch}`) 44 | const sop = cheerio.load(resss_.data) 45 | const empatDrive = sop('div.venser > div.download > div.batchlink > ul > li > a').eq(8).attr('href') 46 | const tigaDrive = sop('div.venser > div.download > div.batchlink > ul > li > a').eq(1).attr('href') 47 | const tujuhDrive = sop('div.venser > div.download > div.batchlink > ul > li > a').eq(15).attr('href') 48 | link_dl['360p'] = tigaDrive 49 | link_dl['480p'] = empatDrive 50 | link_dl['720p'] = tujuhDrive 51 | hasil.push({ judul_, link_, thumb_, genre, status, rating, producer, total_eps, sinopsis, japanese_title, tipe, durasi, tgl_rilis, studio, batch, link_dl,tigaDrive,empatDrive,tujuhDrive }) 52 | 53 | return hasil 54 | } 55 | 56 | module.exports = { onGoing, otakuSearch } 57 | -------------------------------------------------------------------------------- /plugins/photofunia.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | const fetch = require('node-fetch') 3 | const FormData = require('form-data') 4 | 5 | const base = `https://m.photofunia.com` 6 | const photofunSearch = async(teks) => { 7 | var res = await axios.get(`${base}/search?q=${teks}`) 8 | var $ = cheerio.load(res.data) 9 | var hasil = [] 10 | $('ul > li > a.effect').each(function(a, b) { 11 | let judul = $(b).find('span > span.name').text().replace('\n ', '').replace(' ', '') 12 | let desc = $(b).find('span > span.description').text() 13 | let thumb = $(b).find('img').attr('src') 14 | let link = 'https://m.photofunia.com' + $(b).attr('href') 15 | hasil.push({ judul, desc, thumb, link}) 16 | }) 17 | return hasil 18 | } 19 | 20 | const photofunEffect = async(url) => { 21 | var emror = { 22 | 23 | "error" : "Link Tidak Valid" 24 | 25 | } 26 | if (!url.includes(base)) return emror 27 | var res = await axios.get(url) 28 | var $ = cheerio.load(res.data) 29 | var hasil = [] 30 | var inputs = [] 31 | let exam = $('div > div.image-preview > a > img').attr('src') 32 | let judul = $('div > h2').text() 33 | $('form > div > input').each(function(a, b) { 34 | let input = $(b).attr('name') 35 | inputs.push({ input }) 36 | }) 37 | let desc = $('div.description').text() 38 | hasil.push({ judul, desc, exam, inputs }) 39 | return hasil 40 | } 41 | 42 | const photofunUse = async (teks, url) => { 43 | var emror = { 44 | 45 | "error" : "Link Tidak Valid" 46 | 47 | } 48 | if (!url.includes(base)) return emror 49 | let form = new FormData() 50 | form.append("text", teks) 51 | let post = await fetch(url, { method: "POST", headers: { "User-Agent": "GoogleBot", ...form.getHeaders(), }, body: form.getBuffer(), } ) 52 | let html = await post.text() 53 | var $ = cheerio.load(html) 54 | let gambar = $('div.image-container').find('img').attr('src') 55 | return gambar 56 | } 57 | 58 | module.exports = { photofunSearch, photofunEffect, photofunUse } -------------------------------------------------------------------------------- /plugins/solat.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | const cheerio = require('cheerio') 3 | 4 | const jadwalSolat = async(tempat) => { 5 | const url = `https://m.dream.co.id/jadwal-salat/${tempat}` 6 | const res = await axios.get(url) 7 | const $ = cheerio.load(res.data) 8 | const a = $('table').find('tbody > tr > td') 9 | hasil = [] 10 | const emror = "_[ ! ] Error Daerah Tidak DiTemukan_" 11 | const daerah = url.split('/')[4] 12 | const tanggal = $(a).eq(0).text() 13 | const shubuh = $(a).eq(1).text() 14 | const dzuhur = $(a).eq(2).text() 15 | const ashar = $(a).eq(3).text() 16 | const maghrib = $(a).eq(4).text() 17 | const isya = $(a).eq(5).text() 18 | hasil.push({ daerah, tanggal, shubuh, dzuhur, ashar, maghrib, isya}) 19 | return hasil 20 | } 21 | 22 | module.exports = { jadwalSolat } -------------------------------------------------------------------------------- /plugins/swm.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | 3 | function convertSticker(base64, author, pack){ 4 | return new Promise((resolve, reject) =>{ 5 | axios('https://sticker-api-tpe3wet7da-uc.a.run.app/prepareWebp', { 6 | method: 'POST', 7 | headers: { 8 | Accept: 'application/json, text/plain, */*', 9 | 'Content-Type': 'application/json;charset=utf-8', 10 | 'User-Agent': 'axios/0.21.1', 11 | 'Content-Length': 151330 12 | }, 13 | data: `{"image": "${base64}","stickerMetadata":{"author":"${author}","pack":"${pack}","keepScale":true,"removebg":"HQ"},"sessionInfo":{"WA_VERSION":"2.2106.5","PAGE_UA":"WhatsApp/2.2037.6 Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36","WA_AUTOMATE_VERSION":"3.6.10 UPDATE AVAILABLE: 3.6.11","BROWSER_VERSION":"HeadlessChrome/88.0.4324.190","OS":"Windows Server 2016","START_TS":1614310326309,"NUM":"6247","LAUNCH_TIME_MS":7934,"PHONE_VERSION":"2.20.205.16"},"config":{"sessionId":"session","headless":true,"qrTimeout":20,"authTimeout":0,"cacheEnabled":false,"useChrome":true,"killProcessOnBrowserClose":true,"throwErrorOnTosBlock":false,"chromiumArgs":["--no-sandbox","--disable-setuid-sandbox","--aggressive-cache-discard","--disable-cache","--disable-application-cache","--disable-offline-load-stale-cache","--disk-cache-size=0"],"executablePath":"C:\\\\Program Files (x86)\\\\Google\\\\Chrome\\\\Application\\\\chrome.exe","skipBrokenMethodsCheck":true,"stickerServerEndpoint":true}}` 14 | }).then(({data}) =>{ 15 | resolve(data.webpBase64) 16 | }).catch(reject) 17 | 18 | }) 19 | } 20 | 21 | exports.convertSticker = convertSticker 22 | -------------------------------------------------------------------------------- /plugins/wiki.js: -------------------------------------------------------------------------------- 1 | const axios = require('axios') 2 | const cheerio = require('cheerio') 3 | 4 | const wikiSearch = async (query) => { 5 | const res = await axios.get(`https://id.m.wikipedia.org/w/index.php?search=${query}`) 6 | const $ = cheerio.load(res.data) 7 | const hasil = [] 8 | let wiki = $('#mf-section-0').find('p').text() 9 | let thumb = $('#mf-section-0').find('div > div > a > img').attr('src') 10 | thumb = thumb ? thumb : '//pngimg.com/uploads/wikipedia/wikipedia_PNG35.png' 11 | thumb = 'https:' + thumb 12 | let judul = $('h1#section_0').text() 13 | hasil.push({ wiki, thumb, judul }) 14 | return hasil 15 | } 16 | module.exports = { wikiSearch} -------------------------------------------------------------------------------- /plugins/y2mate.js: -------------------------------------------------------------------------------- 1 | const fetch = require('node-fetch') 2 | const cheerio = require('cheerio') 3 | 4 | const y2mateV = async (yutub) => { 5 | function post(url, formdata) { 6 | return fetch(url, { 7 | method: 'POST', 8 | headers: { 9 | accept: "*/*", 10 | 'accept-language': "en-US,en;q=0.9", 11 | 'content-type': "application/x-www-form-urlencoded; charset=UTF-8" 12 | }, 13 | body: new URLSearchParams(Object.entries(formdata)) 14 | }) 15 | } 16 | const ytIdRegex = /(?:http(?:s|):\/\/|)(?:(?:www\.|)youtube(?:\-nocookie|)\.com\/(?:watch\?.*(?:|\&)v=|embed\/|v\/)|youtu\.be\/)([-_0-9A-Za-z]{11})/ 17 | let ytId = ytIdRegex.exec(yutub) 18 | url = 'https://youtu.be/' + ytId[1] 19 | let res = await post(`https://www.y2mate.com/mates/en68/analyze/ajax`, { 20 | url, 21 | q_auto: 0, 22 | ajax: 1 23 | }) 24 | const mela = await res.json() 25 | const $ = cheerio.load(mela.result) 26 | const hasil = [] 27 | let thumb = $('div').find('.thumbnail.cover > a > img').attr('src') 28 | let judul = $('div').find('.thumbnail.cover > div > b').text() 29 | let quality = $('div').find('#mp4 > table > tbody > tr:nth-child(4) > td:nth-child(3) > a').attr('data-fquality') 30 | let tipe = $('div').find('#mp4 > table > tbody > tr:nth-child(3) > td:nth-child(3) > a').attr('data-ftype') 31 | let output = `${judul}.` + tipe 32 | let size = $('div').find('#mp4 > table > tbody > tr:nth-child(4) > td:nth-child(2)').text() 33 | let id = /var k__id = "(.*?)"/.exec(mela.result)[1] 34 | let res2 = await post(`https://www.y2mate.com/mates/en68/convert`, { 35 | type: 'youtube', 36 | _id: id, 37 | v_id: ytId[1], 38 | ajax: '1', 39 | token: '', 40 | ftype: tipe, 41 | fquality: quality 42 | }) 43 | const meme = await res2.json() 44 | const supp = cheerio.load(meme.result) 45 | let link = supp('div').find('a').attr('href') 46 | hasil.push({ thumb, judul, quality, tipe, size, output, link}) 47 | return hasil 48 | } 49 | 50 | 51 | const y2mateA = async (yutub) => { 52 | function post(url, formdata) { 53 | return fetch(url, { 54 | method: 'POST', 55 | headers: { 56 | accept: "*/*", 57 | 'accept-language': "en-US,en;q=0.9", 58 | 'content-type': "application/x-www-form-urlencoded; charset=UTF-8" 59 | }, 60 | body: new URLSearchParams(Object.entries(formdata)) 61 | }) 62 | } 63 | const ytIdRegex = /(?:http(?:s|):\/\/|)(?:(?:www\.|)youtube(?:\-nocookie|)\.com\/(?:watch\?.*(?:|\&)v=|embed\/|v\/)|youtu\.be\/)([-_0-9A-Za-z]{11})/ 64 | let ytId = ytIdRegex.exec(yutub) 65 | url = 'https://youtu.be/' + ytId[1] 66 | let res = await post(`https://www.y2mate.com/mates/en68/analyze/ajax`, { 67 | url, 68 | q_auto: 0, 69 | ajax: 1 70 | }) 71 | const mela = await res.json() 72 | const $ = cheerio.load(mela.result) 73 | const hasil = [] 74 | let thumb = $('div').find('.thumbnail.cover > a > img').attr('src') 75 | let judul = $('div').find('.thumbnail.cover > div > b').text() 76 | let size = $('div').find('#mp3 > table > tbody > tr > td:nth-child(2)').text() 77 | let tipe = $('div').find('#mp3 > table > tbody > tr > td:nth-child(3) > a').attr('data-ftype') 78 | let output = `${judul}.` + tipe 79 | let quality = $('div').find('#mp3 > table > tbody > tr > td:nth-child(3) > a').attr('data-fquality') 80 | let id = /var k__id = "(.*?)"/.exec(mela.result)[1] 81 | let res2 = await post(`https://www.y2mate.com/mates/en68/convert`, { 82 | type: 'youtube', 83 | _id: id, 84 | v_id: ytId[1], 85 | ajax: '1', 86 | token: '', 87 | ftype: tipe, 88 | fquality: quality 89 | }) 90 | const meme = await res2.json() 91 | const supp = cheerio.load(meme.result) 92 | let link = supp('div').find('a').attr('href') 93 | hasil.push({ thumb, judul, quality, tipe, size, output, link}) 94 | return hasil 95 | } 96 | 97 | 98 | module.exports = { y2mateV, y2mateA} -------------------------------------------------------------------------------- /src/images/Proyek Baru [44DCE15].png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GynnnDev/Anu-Wabot/5bb9089bde690cdc664b9fbe75cdf8fa8acfbc4c/src/images/Proyek Baru [44DCE15].png -------------------------------------------------------------------------------- /src/images/logo_zbin.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GynnnDev/Anu-Wabot/5bb9089bde690cdc664b9fbe75cdf8fa8acfbc4c/src/images/logo_zbin.jpg -------------------------------------------------------------------------------- /src/json/botInfo.json: -------------------------------------------------------------------------------- 1 | { 2 | "botname": "Zbin-Wabot", 3 | "ownerNumber": [ 4 | "6281910263857", 5 | "6283128671683", 6 | "60138062494", 7 | "62895343001883", 8 | "62895337035454" 9 | ], 10 | "prefix": [ 11 | "z" 12 | ], 13 | "ownername": "Galang/ZbinKw", 14 | "unicode": { 15 | "head": "⬣", 16 | "list": "⬡", 17 | "body": "┃", 18 | "upper": "┏", 19 | "down": "┗", 20 | "line": "━", 21 | "wings": [ 22 | "𓆩 ", 23 | " 𓆪" 24 | ], 25 | "needed": [ 26 | "<", 27 | ">" 28 | ], 29 | "optional": [ 30 | "(", 31 | ")" 32 | ] 33 | }, 34 | "response": { 35 | "owner": "Khusus Owner", 36 | "admin": "Khusus Admin", 37 | "group": "Khusus Groun", 38 | "wait": "Tunggu Sebentar...", 39 | "private": "Khusus Private", 40 | "notUrl": "Link Invalid", 41 | "media": "Pesan Harus Media", 42 | "mentioned": "Tag Orang Bang", 43 | "quoted": "Tag Pesan Bang", 44 | "_media": "Kirim Pesan Media Atau Tag Pesan Yang Terdapat Media", 45 | "Error": "Yah Error", 46 | "fromMe": "Pesan Yang Di Balas Harus Dari Bot", 47 | "botAdmin": "Bot Nya Admin Dong" 48 | } 49 | } -------------------------------------------------------------------------------- /src/json/group.json: -------------------------------------------------------------------------------- 1 | [] 2 | -------------------------------------------------------------------------------- /src/json/media.json: -------------------------------------------------------------------------------- 1 | { 2 | "logo": { 3 | "url": "https://mmg.whatsapp.net/d/f/AhzRqkkr_3cHUz1KDgQ0Lz_dz1K0ktDKRwmgpyvlf77n.enc", 4 | "mimetype": "image/jpeg", 5 | "fileSha256": "VGsqTMXv4YdPO95740A50Jo7DZSJA3VAfUFAUshGP2w=", 6 | "fileLength": "16730", 7 | "height": 1080, 8 | "width": 1113, 9 | "mediaKey": "Ou/wDDQUzSm0m12UK4LJjWV9FC5NGaICzlzpDKp3xRA=", 10 | "fileEncSha256": "jaHPSlkoRttPA6p076K7mCvAHKs/ghVnWaJzdjmZwXQ=", 11 | "directPath": "/v/t62.7118-24/11293791_239163321389555_2110518527087847207_n.enc?ccb=11-4&oh=d04aaec434b3e99c10d93677f60a444c&oe=6130A347", 12 | "mediaKeyTimestamp": "1628243324", 13 | "jpegThumbnail": "/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEABsbGxscGx4hIR4qLSgtKj04MzM4PV1CR0JHQl2NWGdYWGdYjX2Xe3N7l33gsJycsOD/2c7Z//////////////8BGxsbGxwbHiEhHiotKC0qPTgzMzg9XUJHQkdCXY1YZ1hYZ1iNfZd7c3uXfeCwnJyw4P/Zztn////////////////CABEIAEMARgMBIgACEQEDEQH/xAAsAAEAAgMBAAAAAAAAAAAAAAAABQYBAwQCAQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIQAxAAAACsgM5PIAAAEpF+js4bhGEEAACTtlA7jfzydfAAAANmdQAAAAAAA//EACYQAAEDAwIFBQAAAAAAAAAAAAIBAwQABRESMBQgITEyEzNAQYL/2gAIAQEAAT8A20ogIFwqbMI2X04Z/wDB1MgvRDwSZH6LYFCzkUWrbIGYwseSFXGzuR8m11DmgS2WSQX2RMK9OO5GU4ghqo7lOacIcoK05cJbnk6td+aHPehmigvSpgs3BriGPcTyHZbdNokIFwtOmjhakHCr3+N//8QAFBEBAAAAAAAAAAAAAAAAAAAAQP/aAAgBAgEBPwBP/8QAFBEBAAAAAAAAAAAAAAAAAAAAQP/aAAgBAwEBPwBP/9k=" 14 | } 15 | } -------------------------------------------------------------------------------- /src/json/user.json: -------------------------------------------------------------------------------- 1 | [] 2 | -------------------------------------------------------------------------------- /src/kali.cat: -------------------------------------------------------------------------------- 1 | .............. 2 | ..,;:ccc,. 3 | ......''';lxO. 4 | .....''''..........,:ld; 5 | .';;;:::;,,.x, 6 | ..'''. 0Xxoc:,. ... 7 | .... ,ONkc;,;cokOdc',. 8 | . OMo ':ddo. 9 | dMc :OO; 10 | 0M. .:o. 11 | ;Wd 12 | ;XO, 13 | ,d0Odlc;,.. 14 | ..',;:cdOOd::,. 15 | .:d;.':;. 16 | 'd, .' 17 | ;l .. 18 | .o --------------------------------------------------------------------------------