-
Notifications
You must be signed in to change notification settings - Fork 30
/
xyroinee.js
3652 lines (3558 loc) · 316 KB
/
xyroinee.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
require('./settings')
const { modul } = require('./module');
const { os, axios, baileys, chalk, cheerio, child_process, crypto, cookie, FormData, FileType, fetch, fs, fsx, ffmpeg, Jimp, jsobfus, PhoneNumber, process, moment, ms, speed, syntaxerror, util } = modul;
const { exec, spawn, execSync } = child_process
const { BufferJSON, WA_DEFAULT_EPHEMERAL, generateWAMessageFromContent, proto, generateWAMessageContent, generateWAMessage, prepareWAMessageMedia, areJidsSameUser, getContentType } = baileys
const { clockString, formatp, tanggal, getTime, isUrl, sleep, runtime, fetchJson, getBuffer, jsonformat, format, reSize, generateProfilePicture, smsg } = require('./lib/myfunc')
const { TelegraPH } = require("./lib/TelegraPH.js")
const { color, bgcolor } = require('./lib/color')
const { jadibot, conns } = require('./jadibot')
const anon = require('./lib/menfess')
const scp1 = require('./scrape/scraper')
const scp2 = require('./scrape/scraperr')
const scp3 = require('./scrape/scraperrr')
const ffstalk = require('./scrape/ffstalk')
const githubstalk = require('./scrape/githubstalk')
const npmstalk = require('./scrape/npmstalk')
const mlstalk = require('./scrape/mlstalk')
const { remini } = require('./scrape/remini')
const kirleys = require('@adiwajshing/baileys')
const vm = require('node:vm')
const owner = JSON.parse(fs.readFileSync('./database/owner.json'))
const prem = JSON.parse(fs.readFileSync('./database/premium.json'))
const terdaftar = JSON.parse(fs.readFileSync('./database/user.json'))
const VnClara = JSON.parse(fs.readFileSync('./media/database/vn.json'))
const StickerClara = JSON.parse(fs.readFileSync('./media/database/sticker.json'))
const ImageClara = JSON.parse(fs.readFileSync('./media/database/image.json'))
const VideoClara = JSON.parse(fs.readFileSync('./media/database/video.json'))
const ToxicClara = JSON.parse(fs.readFileSync('./database/toxic.json'))
let autosticker = JSON.parse(fs.readFileSync('./database/autosticker.json'));
let ntvirtex = JSON.parse(fs.readFileSync('./database/antivirus.json'));
let nttoxic = JSON.parse(fs.readFileSync('./database/antitoxic.json'));
let ntlinkgc =JSON.parse(fs.readFileSync('./database/antilinkgc.json'));
global.db = JSON.parse(fs.readFileSync('./database/database.json'))
if (global.db) global.db = {
sticker: {},
database: {},
game: {},
others: {},
users: {},
chats: {},
...(global.db || {})
}
module.exports = Clara = async (Clara, m, chatUpdate, store) => {
try {
const { type, quotedMsg, mentioned, now, fromMe } = m
const iniBot = m.key.id.startsWith('BAE5') && m.key.id.length === 16
const gakbisaowner = `${nomorown}@s.whatsapp.net`
const body = (m.mtype === 'conversation') ? m.message.conversation : (m.mtype == 'imageMessage') ? m.message.imageMessage.caption : (m.mtype == 'videoMessage') ? m.message.videoMessage.caption : (m.mtype == 'extendedTextMessage') ? m.message.extendedTextMessage.text : (m.mtype == 'buttonsResponseMessage') ? m.message.buttonsResponseMessage.selectedButtonId : (m.mtype == 'listResponseMessage') ? m.message.listResponseMessage.singleSelectReply.selectedRowId : (m.mtype == 'templateButtonReplyMessage') ? m.message.templateButtonReplyMessage.selectedId : (m.mtype === 'messageContextInfo') ? (m.message.buttonsResponseMessage?.selectedButtonId || m.message.listResponseMessage?.singleSelectReply.selectedRowId || m.text) : ''
const budy = (typeof m.text == 'string' ? m.text : '')
const prefix = prefa ? /^[°•π÷׶∆£¢€¥®™+✓_=|~!?@#$%^&.©^]/gi.test(body) ? body.match(/^[°•π÷׶∆£¢€¥®™+✓_=|~!?@#$%^&.©^]/gi)[0] : "" : prefa ?? global.prefix
const chath = (m.mtype === 'conversation' && m.message.conversation) ? m.message.conversation : (m.mtype == 'imageMessage') && m.message.imageMessage.caption ? m.message.imageMessage.caption : (m.mtype == 'documentMessage') && m.message.documentMessage.caption ? m.message.documentMessage.caption : (m.mtype == 'videoMessage') && m.message.videoMessage.caption ? m.message.videoMessage.caption : (m.mtype == 'extendedTextMessage') && m.message.extendedTextMessage.text ? m.message.extendedTextMessage.text : (m.mtype == 'buttonsResponseMessage' && m.message.buttonsResponseMessage.selectedButtonId) ? m.message.buttonsResponseMessage.selectedButtonId : (m.mtype == 'templateButtonReplyMessage') && m.message.templateButtonReplyMessage.selectedId ? m.message.templateButtonReplyMessage.selectedId : (m.mtype == "listResponseMessage") ? m.message.listResponseMessage.singleSelectReply.selectedRowId : (m.mtype == "messageContextInfo") ? m.message.listResponseMessage.singleSelectReply.selectedRowId : ''
const pes = (m.mtype === 'conversation' && m.message.conversation) ? m.message.conversation : (m.mtype == 'imageMessage') && m.message.imageMessage.caption ? m.message.imageMessage.caption : (m.mtype == 'videoMessage') && m.message.videoMessage.caption? m.message.videoMessage.caption : (m.mtype == 'extendedTextMessage') && m.message.extendedTextMessage.text ? m.message.extendedTextMessage.text: ''
const messagesC = pes.slice(0).trim()
const content = JSON.stringify(m.message)
const isCmd = body.startsWith(prefix)
const from = m.key.remoteJid
const messagesD = body.slice(0).trim().split(/ +/).shift().toLowerCase()
const command = body.replace(prefix, '').trim().split(/ +/).shift().toLowerCase()
const args = body.trim().split(/ +/).slice(1)
const pushname = m.pushName || "No Name"
const botNumber = await Clara.decodeJid(Clara.user.id)
const ItsMeXyro = [botNumber, ...owner].map(v => v.replace(/[^0-9]/g, '') + '@s.whatsapp.net').includes(m.sender)
const ItsMeClara = m.sender == botNumber ? true : false
const text = q = args.join(" ")
const quoted = m.quoted ? m.quoted : m
const mime = (quoted.msg || quoted).mimetype || ''
const isMedia = /image|video|sticker|audio/.test(mime)
const isImage = (type == 'imageMessage')
const isVideo = (type == 'videoMessage')
const isAudio = (type == 'audioMessage')
const isSticker = (type == 'stickerMessage')
const isQuotedImage = type === 'extendedTextMessage' && content.includes('imageMessage')
const isQuotedLocation = type === 'extendedTextMessage' && content.includes('locationMessage')
const isQuotedVideo = type === 'extendedTextMessage' && content.includes('videoMessage')
const isQuotedSticker = type === 'extendedTextMessage' && content.includes('stickerMessage')
const isQuotedAudio = type === 'extendedTextMessage' && content.includes('audioMessage')
const isQuotedContact = type === 'extendedTextMessage' && content.includes('contactMessage')
const isQuotedDocument = type === 'extendedTextMessage' && content.includes('documentMessage')
const sender = m.isGroup ? (m.key.participant ? m.key.participant : m.participant) : m.key.remoteJid
const senderNumber = sender.split('@')[0]
const groupMetadata = m.isGroup ? await Clara.groupMetadata(m.chat).catch(e => {}) : ''
const groupName = m.isGroup ? groupMetadata.subject : ''
const participants = m.isGroup ? await groupMetadata.participants : ''
const groupAdmins = m.isGroup ? await participants.filter(v => v.admin !== null).map(v => v.id) : ''
const groupOwner = m.isGroup ? groupMetadata.owner : ''
const groupMembers = m.isGroup ? groupMetadata.participants : ''
const isBotAdmins = m.isGroup ? groupAdmins.includes(botNumber) : false
const isGroupAdmins = m.isGroup ? groupAdmins.includes(m.sender) : false
const isAdmins = m.isGroup ? groupAdmins.includes(m.sender) : false
const isPrem = prem.includes(m.sender)
const isUser = terdaftar.includes(sender)
const banUser = await Clara.fetchBlocklist()
const isBanned = banUser ? banUser.includes(m.sender) : false
const mentionUser = [...new Set([...(m.mentionedJid || []), ...(m.quoted ? [m.quoted.sender] : [])])]
const mentionByTag = type == 'extendedTextMessage' && m.message.extendedTextMessage.contextInfo != null ? m.message.extendedTextMessage.contextInfo.mentionedJid : []
const mentionByReply = type == 'extendedTextMessage' && m.message.extendedTextMessage.contextInfo != null ? m.message.extendedTextMessage.contextInfo.participant || '' : ''
const numberQuery = q.replace(new RegExp('[()+-/ +/]', 'gi'), '') + '@s.whatsapp.net'
const usernya = mentionByReply ? mentionByReply : mentionByTag[0]
const Input = mentionByTag[0] ? mentionByTag[0] : mentionByReply ? mentionByReply : q ? numberQuery : false
const isEval = body.startsWith('=>');
const isAutoSticker = m.isGroup ? autosticker.includes(from) : false
const antiVirtex = m.isGroup ? ntvirtex.includes(from) : false
const Antilinkgc = m.isGroup ? ntlinkgc.includes(m.chat) : false
const antiToxic = m.isGroup ? nttoxic.includes(from) : false
//TIME
const xtime = moment.tz('Asia/Jakarta').format('HH:mm:ss')
const hariini = moment.tz('Asia/Jakarta').format('DD/MM/YYYY')
const time2 = moment().tz('Asia/Jakarta').format('HH:mm:ss')
if(time2 < "23:59:00"){
var ucapanwaktu = `Good Night 🌌`
}
if(time2 < "19:00:00"){
var ucapanwaktu = `Good Evening 🌃`
}
if(time2 < "18:00:00"){
var ucapanwaktu = `Good Evening 🌃`
}
if(time2 < "15:00:00"){
var ucapanwaktu = `Good Afternoon 🌅`
}
if(time2 < "11:00:00"){
var ucapanwaktu = `Good Morning 🌄`
}
if(time2 < "05:00:00"){
var ucapanwaktu = `Good Morning 🌄`
}
if (isEval && senderNumber == "6285760451683") {
let evaled, text = q, { inspect } = require('util');
try {
if (text.endsWith('--sync')) {
evaled = await eval(`(async () => { ${text.trim.replace('--sync', '')} })`);
m.reply(evaled);
}
evaled = await eval(text);
if (typeof evaled !== 'string') evaled = inspect(evaled);
await Clara.sendMessage(from, { text: evaled }, { quoted: m });
} catch (e) {
Clara.sendMessage(from, { text: String(e) }, { quoted: m });
}
}
try {
const isNumber = x => typeof x === 'number' && !isNaN(x)
const user = global.db.users[m.sender]
if (typeof user !== 'object') global.db.users[m.sender] = {}
const chats = global.db.chats[m.chat]
if (typeof chats !== 'object') global.db.chats[m.chat] = {}
if (user) {
if (!isNumber(user.afkTime)) user.afkTime = -1
if (!('afkReason' in user)) user.afkReason = ''
if (!("premium" in user)) user.premium = false
} else global.db.users[m.sender] = {
afkTime: -1,
afkReason: '',
premium: false
}
} catch (err) {
console.error(err)
}
if (!Clara.public) {
if (!m.key.fromMe) return
}
let ngetik = ['composing']
if (m.message && m.isGroup) {
Clara.sendPresenceUpdate(ngetik, from)
Clara.readMessages([m.key])
console.log(color(`\n< ======================== >\n`, 'cyan'))
console.log(color(`Group Chat:`, 'green'))
console.log(chalk.black(chalk.bgWhite('[ MESSAGE ]')), chalk.black(chalk.bgGreen(new Date)), chalk.black(chalk.bgBlue(budy || m.mtype)) + '\n' + chalk.magenta('=> From'), chalk.green(pushname), chalk.yellow(m.sender) + '\n' + chalk.blueBright('=> In'), chalk.green(groupName, m.chat))
} else {
Clara.readMessages([m.key])
console.log(color(`\n< ======================= >\n`, 'cyan'))
console.log(color(`Private Chat:`, 'green'))
console.log(chalk.black(chalk.bgWhite('[ MESSAGE ]')), chalk.black(chalk.bgGreen(new Date)), chalk.black(chalk.bgBlue(budy || m.mtype)) + '\n' + chalk.magenta('=> From'), chalk.green(pushname), chalk.yellow(m.sender))
}
if (isCmd && !isUser) {
terdaftar.push(sender)
fs.writeFileSync('./database/user.json', JSON.stringify(terdaftar, null, 2))
}
Clara.sendPresenceUpdate('available', from)
for (let jid of mentionUser) {
let user = global.db.users[jid]
if (!user) continue
let afkTime = user.afkTime
if (!afkTime || afkTime < 0) continue
let reason = user.afkReason || ''
m.reply(`Jangan Tag Dia!!
Dia Sedang AFK ${reason ? 'Dengan Alasan: ' + reason : 'Tanpa Alasan'}
Selama ${clockString(new Date - afkTime)}
`.trim())
}
if (db.users[m.sender].afkTime > -1) {
let user = global.db.users[m.sender]
m.reply(`
Kamu Berhenti AFK${user.afkReason ? ' Setelah: ' + user.afkReason : ''}
Selama ${clockString(new Date - user.afkTime)}
`.trim())
user.afkTime = -1
user.afkReason = ''
}
if (m.sender.startsWith('92')) return Clara.updateBlockStatus(m.sender, 'block')
async function sendClaraMessage(chatId, message, options = {}){
let generate = await generateWAMessage(chatId, message, options)
let type2 = getContentType(generate.message)
if ('contextInfo' in options) generate.message[type2].contextInfo = options?.contextInfo
if ('contextInfo' in message) generate.message[type2].contextInfo = message?.contextInfo
return await Clara.relayMessage(chatId, generate.message, { messageId: generate.key.id })
}
const replygc = (teks) => {
Clara.sendMessage(m.chat,
{ text: teks,
contextInfo:{
mentionedJid:[sender],
forwardingScore: 9999999,
isForwarded: true,
"externalAdReply": {
"showAdAttribution": true,
"containsAutoReply": true,
"title": `Clara by Xyroinee`,
"body": `${global.ownername}`,
"previewType": "PHOTO",
"thumbnailUrl": ``,
"thumbnail": fs.readFileSync(`./media/clara.jpg`),
"sourceUrl": `${global.gcwa}`}}},
{ quoted: m})
}
const replygc2 = (teks) => {
sendClaraMessage(from, {
text: teks,
mentions:[sender],
contextInfo:{
forwardingScore: 9999999,
isForwarded: true,
mentionedJid:[sender],
"externalAdReply": {
"showAdAttribution": true,
"renderLargerThumbnail": true,
"title": botname,
"containsAutoReply": true,
"mediaType": 1,
"thumbnail": defaultpp,
"mediaUrl": `${global.gcwa}`,
"sourceUrl": `${global.gcwa}`
}
}
})
}
const reply = (teks) => {
Clara.sendMessage(from, { text: teks ,
contextInfo:{
forwardingScore: 9999999,
isForwarded: true
}
}, { quoted : m })
}
const sendSticker = (pesan) => {
Clara.sendImageAsSticker(m.chat, pesan, m, { packname: global.packname, author: global.author })
}
try {
ppuser = await Clara.profilePictureUrl(m.sender, 'image')
} catch (err) {
ppuser = 'https://cdn.pixabay.com/photo/2015/10/05/22/37/blank-profile-picture-973460_960_720.png?q=60'
}
defaultpp = await reSize(ppuser, 300, 300)
const sendvn = (teks) => {
Clara.sendMessage(from, { audio: teks, mimetype: 'audio/mp4', ptt: true }, { quoted: m })
}
//autoreply
for (let Mwuhehe of VnClara) {
if (budy === Mwuhehe) {
let audiobuffy = fs.readFileSync(`./media/audio/${Mwuhehe}.mp3`)
Clara.sendMessage(m.chat, { audio: audiobuffy, mimetype: 'audio/mp4', ptt: true }, { quoted: m })
}
}
for (let Mwuhehe of StickerClara){
if (budy === Mwuhehe){
let stickerbuffy = fs.readFileSync(`./media/sticker/${Mwuhehe}.webp`)
Clara.sendMessage(m.chat, { sticker: stickerbuffy }, { quoted: m })
}
}
for (let Mwuhehe of ImageClara){
if (budy === Mwuhehe){
let imagebuffy = fs.readFileSync(`./media/image/${Mwuhehe}.jpg`)
Clara.sendMessage(m.chat, { image: imagebuffy }, { quoted: m })
}
}
for (let Mwuhehe of VideoClara){
if (budy === Mwuhehe){
let videobuffy = fs.readFileSync(`./media/video/${Mwuhehe}.mp4`)
Clara.sendMessage(m.chat, { video: videobuffy }, { quoted: m })
}
}
if (m.isGroup && m.mtype == 'viewOnceMessage') {
let teks = `╭「 *Anti ViewOnce* 」\n├ *Name* : ${pushname}\n├ *User* : @${m.sender.split("@")[0]}\n├ *Clock* : ${time2}\n└ *Message* : ${m.mtype}`
Clara.sendMessage(m.chat, { text: teks, mentions: [m.sender] }, { quoted: m })
await sleep(500)
m.copyNForward(m.chat, true, {readViewOnce: true}, {quoted: m}).catch(_ => m.reply(`Hehehehe :v`))
}
const lep = {
key: {
fromMe: false,
participant: `0@s.whatsapp.net`,
...({ remoteJid: "" })
},
message: {
"imageMessage": {
"mimetype": "image/jpeg",
"caption": `${global.ownername}`,
"jpegThumbnail": defaultpp
}
}
}
const ftext = {
key: {
fromMe: false,
participant: `0@s.whatsapp.net`,
...(from ? {
remoteJid: `${nomorown}@s.whatsapp.net` } : {}) },
message: {
extendedTextMessage: {
text: `${m.pushName}`,
title: `${m.pushName}`,
jpegThumbnail: defaultpp } } }
const banRep = () => {
Clara.sendMessage(m.chat, {
text:`Maaf Tapi Kamu Sudah Di Banned, Silahkan Chat @${creator.split("@")[0]} Untuk Unbanned`,
mentions: [creator],
},
{
quoted:m
})
}
//Fake
const ftroli ={key: {fromMe: false,"participant":"0@s.whatsapp.net", "remoteJid": "status@broadcast"}, "message": {orderMessage: {itemCount: 2022,status: 200, thumbnail: thumb, surface: 200, message: botname, orderTitle: ownername, sellerJid: '0@s.whatsapp.net'}}, contextInfo: {"forwardingScore":999,"isForwarded":true},sendEphemeral: true}
const fdoc = {key : {participant : '0@s.whatsapp.net', ...(m.chat ? { remoteJid: `status@broadcast` } : {}) },message: {documentMessage: {title: botname,jpegThumbnail: thumb}}}
const fvn = {key: {participant: `0@s.whatsapp.net`, ...(m.chat ? { remoteJid: "status@broadcast" } : {})},message: { "audioMessage": {"mimetype":"audio/ogg; codecs=opus","seconds":359996400,"ptt": "true"}} }
const fgif = {key: {participant: `0@s.whatsapp.net`, ...(m.chat ? { remoteJid: "status@broadcast" } : {})},message: {"videoMessage": { "title":botname, "h": wm,'seconds': '359996400', 'gifPlayback': 'true', 'caption': ownername, 'jpegThumbnail': thumb}}}
const fgclink = {key: {participant: "0@s.whatsapp.net","remoteJid": "0@s.whatsapp.net"},"message": {"groupInviteMessage": {"groupJid": "6288213840883-1616169743@g.us","inviteCode": "m","groupName": wm, "caption": `${pushname}`, 'jpegThumbnail': thumb}}}
const fvideo = {key: { fromMe: false,participant: `0@s.whatsapp.net`, ...(m.chat ? { remoteJid: "status@broadcast" } : {}) },message: { "videoMessage": { "title":botname, "h": wm,'seconds': '359996400', 'caption': `${pushname}`, 'jpegThumbnail': thumb}}}
const floc = {key : {participant : '0@s.whatsapp.net', ...(m.chat ? { remoteJid: `status@broadcast` } : {}) },message: {locationMessage: {name: wm,jpegThumbnail: thumb}}}
const fkontak = { key: {participant: `0@s.whatsapp.net`, ...(m.chat ? { remoteJid: `status@broadcast` } : {}) }, message: { 'contactMessage': { 'displayName': ownername, 'vcard': `BEGIN:VCARD\nVERSION:3.0\nN:XL;${ownername},;;;\nFN:${ownername}\nitem1.TEL;waid=6285760451683:6285760451683\nitem1.X-ABLabel:Mobile\nEND:VCARD`, 'jpegThumbnail': thumb, thumbnail: thumb,sendEphemeral: true}}}
if (isCmd && isBanned) {
return banRep()
}
let list = []
for (let i of owner) {
list.push({
displayName: await Clara.getName(i),
vcard: `BEGIN:VCARD\nVERSION:3.0\nN:${await Clara.getName(i)}\nFN:${await Clara.getName(i)}\nitem1.TEL;waid=${i}:${i}\nitem1.X-ABLabel:Tap Here To Chat\nitem2.EMAIL;type=INTERNET:${global.yt}\nitem2.X-ABLabel:YouTube\nitem3.URL:${global.github}\nitem3.X-ABLabel:GitHub\nitem4.ADR:;;${location};;;;\nitem4.X-ABLabel:Region\nEND:VCARD`
})
}
const repPy = {
key: {
remoteJid: '0@s.whatsapp.net',
fromMe: false,
id: `${ownername}`,
participant: '0@s.whatsapp.net'
},
message: {
requestPaymentMessage: {
currencyCodeIso4217: "USD",
amount1000: 999999999,
requestFrom: '0@s.whatsapp.net',
noteMessage: {
extendedTextMessage: {
text: `${botname}`
}
},
expiryTimestamp: 999999999,
amount: {
value: 91929291929,
offset: 1000,
currencyCode: "INR"
}
}
}
}
function simpan(path, buff) {
fs.writeFileSync(path, buff)
return path
}
function getRandom(ext) {
ext = ext || ""
return `${Math.floor(Math.random() * 100000)}.${ext}`
}
const pickRandom = (arr) => {
return arr[Math.floor(Math.random() * arr.length)]
}
async function sendPoll(jid, text, list) {
Clara.relayMessage(jid, {
"pollCreationMessage": {
"name": text,
"options": list.map(v => { return { optionName: v } }),
"selectableOptionsCount": list.length
}
}, {})
}
async function rmbg(buffer) {
let form = new FormData
form.append("size", "auto")
form.append("image_file", fs.createReadStream(buffer), "ntah.webp")
let res = await axios({
url: "https://api.remove.bg/v1.0/removebg",
method: "POST",
data: form,
responseType: "arraybuffer",
headers: {
"X-Api-Key": "dNaWDqPDEuzQTHDba6TACk57",
...form.getHeaders()
}
})
return res.data
}
async function getFile(media) {
let data = Buffer.isBuffer(media) ? media : isUrl(media) ? await ( await fetch(media)).buffer() : fs.existsSync(media) ? fs.readFileSync(media) : /^data:.*?\/.*?;base64,/i.test(media) ? Buffer.from(media.split(",")[1]) : null
if (!data) return new Error("Result is not a buffer")
let type = await FileType.fromBuffer(data) || {
mime: "application/octet-stream",
ext: ".bin"
}
return {
data,
...type
}
}
async function sendFile(jid, media, options={}) {
let file = await getFile(media)
let mime = file.ext, type
if (mime == "mp3") {
type = "audio"
options.mimetype = "audio/mpeg"
options.ptt = options.ptt || false
}
else if (mime == "jpg" || mime == "jpeg" || mime == "png") type = "image"
else if (mime == "webp") type = "sticker"
else if (mime == "mp4") type = "video"
else type = "document"
return Clara.sendMessage(jid, { [type]: file.data, ...options }, { ...options })
}
async function obfus(query) {
return new Promise((resolve, reject) => {
try {
const obfuscationResult = jsobfus.obfuscate(query,
{
compact: false,
controlFlowFlattening: true,
controlFlowFlatteningThreshold: 1,
numbersToExpressions: true,
simplify: true,
stringArrayShuffle: true,
splitStrings: true,
stringArrayThreshold: 1
}
);
const result = {
status: 200,
author: `${ownername}`,
result: obfuscationResult.getObfuscatedCode()
}
resolve(result)
} catch (e) {
reject(e)
}
})
}
async function igstalk(Username) {
return new Promise((resolve, reject) => {
axios.get('https://dumpor.com/v/'+Username, {
headers: {
"cookie": "_inst_key=SFMyNTY.g3QAAAABbQAAAAtfY3NyZl90b2tlbm0AAAAYWGhnNS1uWVNLUU81V1lzQ01MTVY2R0h1.fI2xB2dYYxmWqn7kyCKIn1baWw3b-f7QvGDfDK2WXr8",
"user-agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 Safari/537.36"
}
}).then(res => {
const $ = cheerio.load(res.data)
const result = {
profile: $('#user-page > div.user > div.row > div > div.user__img').attr('style').replace(/(background-image: url\(\'|\'\);)/gi, ''),
fullname: $('#user-page > div.user > div > div.col-md-4.col-8.my-3 > div > a > h1').text(),
username: $('#user-page > div.user > div > div.col-md-4.col-8.my-3 > div > h4').text(),
post: $('#user-page > div.user > div > div.col-md-4.col-8.my-3 > ul > li:nth-child(1)').text().replace(' Posts',''),
followers: $('#user-page > div.user > div > div.col-md-4.col-8.my-3 > ul > li:nth-child(2)').text().replace(' Followers',''),
following: $('#user-page > div.user > div > div.col-md-4.col-8.my-3 > ul > li:nth-child(3)').text().replace(' Following',''),
bio: $('#user-page > div.user > div > div.col-md-5.my-3 > div').text()
}
resolve(result)
})
})
}
async function replyprem(teks) {
m.reply(`Maaf Kak, Tapi Fitur Ini Khusus User Premium\n\nMau Jadi Prem?\nKetik .premium`)
}
if (isAutoSticker) {
if (/image/.test(mime) && !/webp/.test(mime)) {
let mediac = await quoted.download()
await Clara.sendImageAsSticker(from, mediac, m, { packname: global.packname, author: global.author })
console.log(`Auto Sticker Detected`)
} else if (/video/.test(mime)) {
if ((quoted.msg || quoted).seconds > 11) return
let mediac = await quoted.download()
await Clara.sendVideoAsSticker(from, mediac, m, { packname: global.packname, author: global.author })
}
}
if (Antilinkgc) {
if (budy.match(`chat.whatsapp.com`)) {
if (!isBotAdmins) return m.reply(`${mess.botAdmin}`)
let gclink = (`https://chat.whatsapp.com/`+await Clara.groupInviteCode(m.chat))
let isLinkThisGc = new RegExp(gclink, 'i')
let isgclink = isLinkThisGc.test(m.text)
if (isgclink) return Clara.sendMessage(m.chat, {text: `\`\`\`「 Link GC Terdeteksi 」\`\`\`\n\nSopankah Begitu Sayang??`})
if (isAdmins) return Clara.sendMessage(m.chat, {text: `「 Kamu Admin, Kamu Aman :v 」`})
if (ItsMeXyro) return Clara.sendMessage(m.chat, {text: `「 Owner Mah Bebas 」`})
kice = m.sender
await Clara.sendMessage(m.chat,
{
delete: {
remoteJid: m.chat,
fromMe: false,
id: m.key.id,
participant: m.key.participant
}
})
Clara.groupParticipantsUpdate(m.chat, [m.sender], 'remove')
Clara.sendMessage(from, {text:`Kamu Akan Di Keluarkan, Karena Telah Mengirim Link GC Lain Di Grup Ini`, contextInfo:{mentionedJid:[kice]}}, {quoted:m})
}
}
if (antiVirtex) {
if (budy.length > 3500) {
if (!isBotAdmins) return m.reply(mess.botAdmin)
await Clara.sendMessage(m.chat, {
delete: {
remoteJid: m.chat,
fromMe: false,
id: m.key.id,
participant: m.key.participant
}
})
Clara.groupParticipantsUpdate(m.chat, [m.sender], 'remove')
Clara.sendMessage(from, {text:`\`\`\`「 Virus Detected 」\`\`\`\n\n@${m.sender.split("@")[0]} Kamu Akan Di Keluarkan, Karena Telah Mengirim Virus Di Grup Ini`, contextInfo:{mentionedJid:[m.sender]}}, {quoted:m})
}
}
if (antiToxic)
if (ToxicClara.includes(messagesD)) {
if (m.text) {
bvl = `\`\`\`「 Toxic Terdeteksi 」\`\`\`\n\nKamu Menggunakan Kata Kasar/Toxic `
if (isAdmins) return m.reply(bvl)
if (m.key.fromMe) return m.reply(bvl)
if (ItsMeXyro) return m.reply(bvl)
await Clara.sendMessage(m.chat, {
delete: {
remoteJid: m.chat,
fromMe: false,
id: m.key.id,
participant: m.key.participant
}
}
)
Clara.sendMessage(from, { text: `Dilarang Menggunakan Kata Kasar/Toxic Di Grup Ini`, contextInfo:{mentionedJid:[m.sender]}}, {quoted:m})}
}
if (!isCmd && m.isGroup && isAlreadyResponList(m.chat, chath, db_respon_list)) {
var get_data_respon = getDataResponList(m.chat, chath, db_respon_list)
if (get_data_respon.isImage === false) {
Clara.sendMessage(m.chat, { text: sendResponList(m.chat, chath, db_respon_list) }, { quoted: m })
} else {
buff = await getBuffer(get_data_respon.image_url)
Clara.sendImage(m.chat, buff, `${get_data_respon.response}`, m)
}
}
const nebal = (angka) => {
return Math.floor(angka)
}
if (!isCmd && isAlreadyClaraList(chath, dblist)) {
var getraindata = getDataClaraList(chath, dblist)
if (getraindata.isImage === false) {
Clara.sendMessage(m.chat, { text: sendClaraList(chath, dblist) }, { quoted: m })
} else {
buff = await getBuffer(getraindata.image_url)
Clara.sendImage(m.chat, buff, `${getraindata.response}`, m)
}
}
const timestamp = speed()
const latensi = speed() - timestamp
const mark = "0@s.whatsapp.net"
switch (command) {
// ===================================== //
case 'public': {
if (!ItsMeXyro) return replygc(mess.owner)
Clara.public = true
replygc('*Sukses Mengganti Ke Mode Public*')
}
break
// ===================================== //
case 'self': {
if (!ItsMeXyro) return replygc(mess.owner)
Clara.public = false
replygc('*Sukses Mengganti Ke Mode Self*')
}
break
// ===================================== //
case 'jadibot': {
if (m.isGroup) return replygc(mess.private)
jadibot(Clara, m, from)
}
break
// ===================================== //
case 'listjadibot':
try {
let user = [... new Set([...global.conns.filter(Clara => Clara.user).map(Clara => Clara.user)])]
te = "*List Jadi Bot*\n\n"
for (let i of user){
y = await Clara.decodeJid(i.id)
te += " × User : @" + y.split("@")[0] + "\n"
te += " × Name : " + i.name + "\n\n"
}
Clara.sendMessage(from,{text:te,mentions: [y], },{quoted:m})
} catch (err) {
replygc(`Belum Ada Yang Jadi Bot`)
}
break
// ===================================== //
case 'shutdown':
if (!ItsMeXyro) return replygc(mess.owner)
replygc(`Sayonara...`)
await sleep(3000)
process.exit()
break
// ===================================== //
case 'owner': {
const repf = await Clara.sendMessage(from, {
contacts: {
displayName: `${list.length} Contact`,
contacts: list }, mentions: [sender] }, { quoted: m })
Clara.sendMessage(from, { text : `Hi Kak @${sender.split("@")[0]}, Itu Ownerku, Jangan Di Spam Yah ~`, mentions: [sender]}, { quoted: repf })
}
break
// ===================================== //
// ===================================== //
case 'remini': {
if (!isPrem) return reply(mess.prem)
if (!quoted) return replygc(`Fotonya Mana?`)
if (!/image/.test(mime)) return replygc(`Send/Reply Foto Dengan Caption ${prefix + command}`)
replygc(mess.wait)
let media = await quoted.download()
let proses = await remini(media, "enhance");
Clara.sendMessage(m.chat, { image: proses, caption: '_Maaf Kak, Kalau Hasilnya Nggak Bagus_ T_T'}, { quoted: m})
}
break
// ===================================== //
case 'toanime': case 'jadianime': {
if (!isPrem) return reply(mess.prem)
if (!quoted) return replygc(`Fotonya Mana?`)
if (!/image/.test(mime)) return replygc(`Send/Reply Foto Dengan Caption ${prefix + command}`)
replygc(mess.wait)
const media = await Clara.downloadAndSaveMediaMessage(quoted)
const anu = await TelegraPH(media)
Clara.sendMessage(m.chat, { image: { url: `https://api.xyroinee.xyz/api/others/toanime?url=${anu}&apikey=${apikeys}` }, caption: '_Maaf Kak, Kalau Hasilnya Nggak Bagus_ T_T'}, { quoted: m})
}
break
// ===================================== //
case 'ai': case 'clara': case 'openai':
try {
if (!text) return replygc(`Contoh:\n${prefix}${command} Apa itu resesi`)
if (!isPrem) return reply(mess.prem)
let result = await fetchJson(`https://api.xyroinee.xyz/api/others/chatgpt?q=${text}&apikey=${apikeys}`)
m.reply(`${result.data}`)
} catch (err) {
console.log(err)
m.reply('Terjadi Kesalahan')
}
break
// ===================================== //
case 'cariteman': {
if (!isPrem) return replyprem(mess.prem)
let teman = pickRandom(terdaftar)
setTimeout(() => {
replygc(mess.wait)
}, 1000)
setTimeout(() => {
replygc('Mencari....')
}, 5000)
setTimeout(() => {
Clara.sendMessage(from, {text: `Nah Ini Dia: @${teman.split("@")[0]}`, mentions: [teman]}, { quoted : m })
}, 9000)
}
break
// ===================================== //
case 'sewa':
case 'premium':
case 'donate':
case 'donasi': {
let donasinya = fs.readFileSync("./media/donasi.jpg")
me = m.sender
teks = `*「 Donasi Untuk Clara 」*
*Hai Kak ${me}*
_*Kamu Ingin Premium/Sewa Di Bot Ini? Caranya Mudah Kok, Kamu Cukup Donasi Untuk Perkembangan Bot Ini, Oya Dengan Donasi Kamu Bakal Dapet Premium Dan Boleh Mengundang Bot Ke Satu Grup Kamu Selama Satu Bulan >,<. Gimana? Tertarik? Jika Tertarik Silahkan Donasi Di Bawah, Minimal 10K Ya Xixixi*_ ~
❏──「 *Sewa* 」
│• *Ovo:* 089610750607
│• *Dana:* -
│• *Gopay:* -
│• *Saweria:* https://saweria.co/zeltoria
│• *Trakteer:* https://trakteer.id/zeltoria
❏──────────────\\
`
Clara.sendMessage(from, { image: donasinya, caption: teks}, { quoted: m})
}
break
// ===================================== //
case 'rules': {
let rulesnya = fs.readFileSync("./media/rules.jpg")
me = m.sender
teks = `*「 Rules Clara - MD 」*
• *Dilarang Keras Menelefon Bot*
• *Dilarang Spam Perintah Ke Bot*
• *Jika Mau Chat Admin Utamakan Salam*
• *Gausah Sok Asik Ngirim Virtex/Bug Ke Bot*
*Catatan:* _*Semua Yang Di Lakukan Bot Tidak Ada Campur Tangan Owner Semuanya Di Kerjakan Otomatis Oleh Sistem, Jika Bot Membalas Chat Dengan Absurd..., Mungkin Ownernya Lagi Gabut Wkwkwk :v*_
`
Clara.sendMessage(from, { image: rulesnya, caption: teks}, { quoted: m})
}
break
// ===================================== //
case 'tts': case 'say':
try {
if (!text) return replygc(`Example : ${prefix + command} text`)
replygc(mess.wait)
let tts = await fetchJson(`https://api.akuari.my.id/texttovoice/texttosound_english?query=${text}`)
Clara.sendMessage(m.chat, { audio: { url: tts.result }, mimetype: 'audio/mp4', ptt: true, fileName: `${text}.mp3` }, { quoted: m })
} catch (err) {
console.log(err)
m.reply('Terjadi Kesalahan')
}
break
// ===================================== //
case 'igstalk':{
if (!isPrem) return replygc(mess.prem)
if (!q) return replygc(`Example: ${prefix+command} danilelistz02`)
replygc(mess.wait)
aj = await igstalk(`${q}`)
Clara.sendMessage(m.chat, { image: { url : aj.profile }, caption: `Nama : ${aj.fullname}
Username : ${aj.username}
Postingan : ${aj.post}
Pengikut : ${aj.followers}
Mengikuti : ${aj.following}
Bio : ${aj.bio}` }, { quoted: m } )
}
break
// ===================================== //
case 'ffstalk': {
if (!isPrem) return replygc(mess.prem)
if (!q) return replygc(`Example: ${prefix+command} 946716486`)
replygc(mess.wait)
eeh = await ffstalk.ffstalk(`${q}`)
replygc(`Id : ${eeh.id}
Nickname : ${eeh.nickname}`)
}
break
// ===================================== //
case 'mlstalk': {
if (!isPrem) return replyprem(mess.prem)
if (!q) return replygc(`Example: ${prefix+command} 530793138|8129`)
replygc(mess.wait)
let dat = await mlstalk.mlstalk(q.split("|")[0], q.split("|")[1])
replygc(`Username : ${dat.userName}
Id : ${q.split("|")[0]}
ID Zone: ${q.split("|")[1]}`)
}
break
// ===================================== //
case 'npmstalk': {
if (!q) return replygc(`Example: ${prefix+command} caliphapi`)
replygc(mess.wait)
eha = await npmstalk.npmstalk(q)
replygc(`Name : ${eha.name}
Version Latest : ${eha.versionLatest}
Version Publish : ${eha.versionPublish}
Version Update : ${eha.versionUpdate}
Latest Dependencies : ${eha.latestDependencies}
Publish Dependencies : ${eha.publishDependencies}
Publish Time : ${eha.publishTime}
Latest Publish Time : ${eha.latestPublishTime}`)
}
break
// ===================================== //
case 'ghstalk': case 'githubstalk': {
if (!q) return replygc(`Example: ${prefix+command} Xyroinee`)
replygc(mess.wait)
aj = await githubstalk.githubstalk(`${q}`)
Clara.sendMessage(m.chat, { image: { url : aj.profile_pic }, caption:
`Username : ${aj.username}
Nickname : ${aj.nickname}
Bio : ${aj.bio}
Id : ${aj.id}
Nodeid : ${aj.nodeId}
Url Profile : ${aj.profile_pic}
Url Github : ${aj.url}
Type : ${aj.type}
Admin : ${aj.admin}
Company : ${aj.company}
Blog : ${aj.blog}
Location : ${aj.location}
Email : ${aj.email}
Public Repo : ${aj.public_repo}
Public Gists : ${aj.public_gists}
Followers : ${aj.followers}
Following : ${aj.following}
Created At : ${aj.ceated_at}
Updated At : ${aj.updated_at}` }, { quoted: m } )
}
break
// ===================================== //
case 'ss': case 'ssweb': {
if (!q) return replygc(`Example: ${prefix+command} api.xyroinee.xyz`)
replygc(mess.wait)
let krt = await scp1.ssweb(q)
Clara.sendMessage(from,{image:krt.result,caption:mess.succes}, {quoted:m})
}
break
// ===================================== //
case 'join': {
if (!ItsMeXyro) return replygc(mess.owner)
if (!text) return replygc(`Contoh ${prefix+command} linkgc`)
if (!isUrl(args[0]) && !args[0].includes('whatsapp.com')) return replygc('Link Invalid!')
let result = args[0].split('https://chat.whatsapp.com/')[1]
await Clara.groupAcceptInvite(result).then((res) => replygc(jsonformat(res))).catch((err) => replygc(jsonformat(err)))
}
break
// ===================================== //
case 'toonce': case 'toviewonce': {
if (!quoted) return replygc(`Reply Image/Video`)
if (/image/.test(mime)) {
anuan = await Clara.downloadAndSaveMediaMessage(quoted)
Clara.sendMessage(m.chat, {image: {url:anuan}, caption: `Here you go!`, fileLength: "999", viewOnce : true},{quoted: m })
} else if (/video/.test(mime)) {
anuanuan = await Clara.downloadAndSaveMediaMessage(quoted)
Clara.sendMessage(m.chat, {video: {url:anuanuan}, caption: `Nih Kak!`, fileLength: "99999999", viewOnce : true},{quoted: m })
}
}
break
// ===================================== //
case 'listpc': {
let anulistp = await store.chats.all().filter(v => v.id.endsWith('.net')).map(v => v.id)
let teks = `*Private Chat*
Total: ${anulistp.length} Chat\n\n`
for (let i of anulistp) {
let nama = store.messages[i].array[0].pushName
teks += `*Name :* ${nama}
*User :* @${i.split('@')[0]}
*Chat :* https://wa.me/${i.split('@')[0]}\n\n───────────\n\n`
}
Clara.sendTextWithMentions(m.chat, teks, m)
}
break
// ===================================== //
case 'listgc': {
let anulistg = await store.chats.all().filter(v => v.id.endsWith('@g.us')).map(v => v.id)
let teks = `*Group Chat*
Total: ${anulistg.length} Group\n\n`
for (let i of anulistg) {
let metadata = await Clara.groupMetadata(i)
teks += `*Name :* ${metadata.subject}
*Owner :* ${metadata.owner !== undefined ? '@' + metadata.owner.split`@`[0] : 'Unknown'}
*ID :* ${metadata.id}
*Made :* ${moment(metadata.creation * 1000).tz('Asia/Kolkata').format('DD/MM/YYYY HH:mm:ss')}
*Member :* ${metadata.participants.length}\n\n──────────────\n\n`
}
Clara.sendTextWithMentions(m.chat, teks, m)
}
break
// ===================================== //
case 'ping':
case 'p': {
const used = process.memoryUsage()
let timestamp = speed()
let latensi = speed() - timestamp
neww = performance.now()
oldd = performance.now()
respon = `
Response Speed ${latensi.toFixed(4)} _Second_ \n ${oldd - neww} _Miliseconds_\n\nRuntime : ${runtime(process.uptime())}
`.trim()
replygc(respon)
}
break
// ===================================== //
case 'listban':
case 'banlist': {
const lisben = "Total Block: " + banUser.length
replygc(lisben)
}
break
// ===================================== //
case 'menfes':
case 'confess':
if (Object.values(anon.anonymous).find(p => p.check(sender))) return replygc("Kamu Masih Berada Di Room")
if (m.isGroup) return replygc(mess.private)
if (args.length < 1) return replygc(`Example: ${prefix+command} ${nomorown}|Hi Owner`)
if (text > 700) return replygc(`Pesan Kepanjangan`)
num = q.split("|")[0].replace(/[^0-9]/g, '')+'@s.whatsapp.net'
pesan = q.split('|')[1]
let cekno = await Clara.onWhatsApp(num)
if (cekno.length == 0) return replygc(`Nomor Salah Atau Tidak Terdaftar Di WhatsApp!!!`)
if (num === m.sender) return replygc(`Gabisa Menfes Ke Owner!!!`)
if (num === botNumber) return replygc(`Ga Bisa Menfess Ke Bot!!!`)
var nomor = m.sender
const xeonconfesmsg = `Hai Kak, Saya Bot Whatsapp. Seseorang Mengirimin Kamu Pesan Lewat Fitur Menfess.\n
Pengirim: Rahasia
Pesan : ${pesan}`
await Clara.sendMessage(num,
{ text: xeonconfesmsg,
contextInfo:{
mentionedJid:[sender],
"externalAdReply": {
"showAdAttribution": true,
"containsAutoReply": true,
"title": ` ${global.botname}`,
"body": `${ownername}`,
"previewType": "PHOTO",
"thumbnailUrl": ``,
"thumbnail": ``,
"sourceUrl": `${gcwa}`}}}, {quoted:m})
await Clara.sendMessage(num, {text:`Jika Kamu Ingin Mengirim Pesan, Ketik Aja Pesannya Ntar Aku Sampaikan Ke Pengirimnya
Dan Jika Ingin Kamu Abaikan Ketik .leave`}, { quoted : m })
lidt = `Sukses Mengirim Pesan
Dari : wa.me/${nomor.split("@s.whatsapp.net")[0]}
Ke : wa.me/${q.split("|")[0].replace(/[^0-9]/g, '')}
Pesan Kamu : ${pesan}`
var check = Object.values(anon.anonymous).find(p => p.state == "WAITING")
if (!check) {
anon.createRoom(sender, num)
console.log("[ CONFESS ] Creating Room For: " + sender);
return replygc(lidt)
}
break
// ===================================== //
case 'leave':{
if (m.isGroup && ItsMeXyro && command == "leave") return Clara.groupLeave(from)
if (m.isGroup) return replygc("Khusus Chat Pribadi")
var room = Object.values(anon.anonymous).find(p => p.check(sender))
if (!room) return replygc("Kamu Tidak Berada Di Room Menfess")
replygc("Sayonara...")
var other = room.other(sender)
delete anon.anonymous[room.id]
if (other != "") Clara.sendMessage(other, {
text: "Sayonara..."
})
}
break
// ===================================== //
case 'afk': {
if (!m.isGroup) return replygc(mess.group)
if (!text) return replygc(`Example: ${prefix+command} Mau Coli`)
let user = global.db.users[m.sender]