shadowmd-baileys 8.6.59 → 8.6.91

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,60 +1,259 @@
1
+ # Shadow Md Baileys
2
+
1
3
  <p align="center">
2
- <img src="https://files.catbox.moe/qrycog.jpg" width="100%" />
4
+ <img src="https://qu.ax/f3hpw" width="450" style="border-radius:12px; box-shadow: 0 4px 8px rgba(0,0,0,0.2);">
3
5
  </p>
4
6
 
5
- <h1 align="center">SHADOWMD - BAILEYS</h1>
6
-
7
7
  <p align="center">
8
- Base WhatsApp Bot Multi Device Using Baileys
8
+ <strong>Enterprise-Grade WhatsApp Business API</strong><br>
9
+ <sub>High-performance modified Baileys library for scalable WhatsApp integrations</sub>
9
10
  </p>
10
11
 
11
12
  <p align="center">
12
- <img src="https://img.shields.io/badge/Version-Latest-blue?style=for-the-badge">
13
- <img src="https://img.shields.io/badge/NodeJS-v18+-green?style=for-the-badge">
14
- <img src="https://img.shields.io/badge/Status-Active-success?style=for-the-badge">
13
+ <img src="https://img.shields.io/badge/Node.js-v20+-green?style=for-the-badge&logo=node.js" alt="Node.js">
14
+ <img src="https://img.shields.io/badge/Modified-Baileys-blue?style=for-the-badge" alt="Modified Baileys">
15
+ <img src="https://img.shields.io/badge/License-MIT-yellow?style=for-the-badge" alt="License">
15
16
  </p>
16
17
 
17
- ## ✨ Features
18
+ ---
19
+
20
+ ## Deskripsi
21
+ **Clutch Baileys** (`shadowmd-baileys`) adalah versi modifikasi dari *Baileys library* yang dioptimalkan untuk kebutuhan bisnis, otomasi, dan integrasi skala besar. Pustaka ini mendukung berbagai fitur pesan interaktif terbaru dari WhatsApp Business API yang tidak tersedia di library standar.
22
+
23
+ ---
18
24
 
19
- - Multi Device Support
20
- - Pairing Code
21
- - Fast Response
22
- - Lightweight
23
- - Easy To Use
24
- - Suitable For Pushkontak & Jaga Group
25
- - Simple Structure
25
+ ## Fitur Unggulan
26
+ * **Auto-Reject Calls & Auto-Reply**: Blokir panggilan telepon suara/video masuk secara otomatis dan kirim pesan respon kustom.
27
+ * **Auto-Read Status**: Otomatis melihat/membaca status/story kontak WhatsApp lain ketika diposting.
28
+ * **Auto-Read Messages**: Otomatis mengirim laporan centang biru (read receipt) untuk semua pesan masuk.
29
+ * **WhatsApp Flows Support**: Kirim formulir interaktif di dalam chat untuk mempermudah alur transaksi bisnis.
30
+ * **Multi-Media Album Message**: Kirim beberapa gambar/video sekaligus terasosiasi dalam satu album chat.
31
+ * **Status WhatsApp & Mention**: Kirim story/status WhatsApp story serta sebut (*mention*) kontak atau grup secara spesifik.
32
+ * **Interactive & Product Message**: Dukungan penuh untuk list, native flow buttons, dan katalog produk.
33
+ * **Custom Message ID Prefix**: Setiap pesan otomatis menggunakan generator ID kustom berawalan `'CLUTCH-'`.
26
34
 
27
- ## 📦 Installation
35
+ ---
28
36
 
37
+ ## Persyaratan Sistem
38
+ * **Node.js**: Versi `20` atau yang lebih baru.
39
+
40
+ ---
41
+
42
+ ## Instalasi
29
43
  ```bash
30
- pkg update && pkg upgrade
31
- pkg install git nodejs ffmpeg imagemagick yarn
32
- git clone https://github.com/budetzz/shadowmd-baileys
33
- cd shadowmd-baileys
34
- yarn install
35
- npm start
44
+ npm install shadowmd-baileys
45
+ # atau menggunakan yarn
46
+ yarn add shadowmd-baileys
36
47
  ```
37
48
 
38
- ## 🛠 Information
49
+ ---
50
+
51
+ ## Contoh Penggunaan & Konfigurasi
52
+
53
+ ### 1. Inisialisasi & Konfigurasi Auto-Reject Calls
54
+ ```javascript
55
+ const makeWASocket = require('shadowmd-baileys').default;
56
+ const { useMultiFileAuthState } = require('shadowmd-baileys');
39
57
 
40
- ```txt
41
- Creator : MazzBudetzz
42
- Base : Baileys
43
- Version : Latest
44
- Language : JavaScript
58
+ async function startSock() {
59
+ const { state, saveCreds } = await useMultiFileAuthState('auth_info_folder');
60
+
61
+ const sock = makeWASocket({
62
+ auth: state,
63
+ printQRInTerminal: true,
64
+
65
+ // PENGATURAN KUSTOM AUTO-REJECT CALLS & AUTO-READ
66
+ rejectCalls: true, // Setel ke true untuk menolak semua panggilan masuk secara otomatis
67
+ callRejectMessage: { text: "Maaf, akun ini tidak menerima panggilan suara/video." }, // Pesan balasan otomatis
68
+ autoReadStatus: true, // Setel ke true untuk membaca otomatis semua status/story kontak
69
+ autoReadMessages: false // Setel ke true jika ingin otomatis mengirim centang biru untuk semua chat masuk
70
+ });
71
+
72
+ sock.ev.on('creds.update', saveCreds);
73
+
74
+ sock.ev.on('connection.update', (update) => {
75
+ const { connection, lastDisconnect } = update;
76
+ if (connection === 'close') {
77
+ console.log('Koneksi terputus, mencoba menghubungkan kembali...');
78
+ startSock();
79
+ } else if (connection === 'open') {
80
+ console.log('Koneksi berhasil terbuka!');
81
+ }
82
+ });
83
+
84
+ return sock;
85
+ }
86
+
87
+ startSock();
45
88
  ```
46
89
 
47
- ## ⚠️ Warning
90
+ ---
48
91
 
49
- Script ini hanya untuk pembelajaran.
50
- Dilarang memperjualbelikan tanpa izin creator.
92
+ ## Dokumentasi API Pengiriman Pesan Kustom
51
93
 
52
- ## 💬 Contact
94
+ Seluruh fitur di bawah diakses menggunakan method `sendMessage` standar atau instance utilitas `sock.rahmi`.
53
95
 
54
- - WhatsApp : wa.me/6285834223876
55
- - Telegram : t.me/MazzBudetzz
56
- - Channel : https://whatsapp.com/channel/0029VbCE5GELo4hkgpIJTy16
96
+ ### 1. Mengirim WhatsApp Flows (Form Interaktif)
97
+ Kirim antarmuka formulir interaktif menggunakan tipe `flowMessage`.
98
+ ```javascript
99
+ await sock.sendMessage(jid, {
100
+ flowMessage: {
101
+ title: "Pilih Layanan",
102
+ body: "Silakan isi formulir pemesanan dengan menekan tombol di bawah ini.",
103
+ footer: "Clutch Flows",
104
+ flowId: "1234567890", // ID Flow dari Meta Developer
105
+ buttonText: "Buka Formulir",
106
+ screen: "RESERVATION_SCREEN", // ID Screen awal Flow Anda
107
+ params: {
108
+ user_name: "Shadow Md",
109
+ phone: "628xxx"
110
+ }
111
+ }
112
+ });
113
+ ```
57
114
 
58
- <p align="center">
59
- Made With ❤️ By MazzBudetzz
60
- </p>
115
+ ### 2. Mengirim Album (Multi-Media Terkait)
116
+ Kirim beberapa gambar atau video sekaligus terkelompok dalam satu album pesan di WhatsApp.
117
+ ```javascript
118
+ await sock.sendMessage(jid, {
119
+ albumMessage: [
120
+ { image: { url: 'https://source.unsplash.com/random/800x600?nature' }, caption: 'Foto Alam 1' },
121
+ { image: { url: 'https://source.unsplash.com/random/800x600?water' } },
122
+ { video: { url: 'http://techslides.com/demos/sample-videos/small.mp4' } }
123
+ ],
124
+ albumOptions: {
125
+ newsletterJid: "1203xxxxxxxx@newsletter", // Opsional
126
+ newsletterName: "MazzBudetzz Info Channel", // Opsional
127
+ senderName: "Shadow Md" // Opsional
128
+ }
129
+ });
130
+ ```
131
+
132
+ ### 3. Mengirim Status / Story Mention (Sebut Kontak/Grup)
133
+ Kirim status WhatsApp baru ke `status@broadcast` serta mention nomor kontak atau grup tertentu.
134
+ ```javascript
135
+ await sock.sendStatusMention({
136
+ image: { url: 'https://source.unsplash.com/random/1080x1920?business' },
137
+ text: "Pembaruan sistem Shadow Baileys siap digunakan!"
138
+ }, [
139
+ "6281249703469@s.whatsapp.net",
140
+ "1203630249219323@g.us"
141
+ ]);
142
+ ```
143
+
144
+ ### 4. Mengirim Pesan Produk & Katalog
145
+ ```javascript
146
+ await sock.sendMessage(jid, {
147
+ productMessage: {
148
+ title: "Clutch Premium Bot License",
149
+ description: "Akses bot premium 1 bulan penuh tanpa batas.",
150
+ body: "Dapatkan penawaran terbaik hari ini!",
151
+ footer: "Klik tombol di bawah untuk detail produk",
152
+ productId: "998877",
153
+ retailerId: "clutch-001",
154
+ priceAmount1000: 50000000, // Rp 50.000 (1000 * harga asli)
155
+ currencyCode: "IDR",
156
+ thumbnail: { url: "https://cdn-alip.clutch.web.id/api/u/mq1sahji.jpg" },
157
+ buttons: [
158
+ {
159
+ name: "send_location",
160
+ buttonParamsJson: "{}"
161
+ }
162
+ ]
163
+ }
164
+ });
165
+ ```
166
+
167
+ ### 5. Mengirim Pesan Pembayaran (`PAYMENT`)
168
+ ```javascript
169
+ await sock.sendMessage(jid, {
170
+ requestPaymentMessage: {
171
+ amount: 25000000, // Rp 25.000
172
+ currency: "IDR",
173
+ expiry: Math.floor(Date.now() / 1000) + 86400, // Berlaku 24 Jam
174
+ from: "0@s.whatsapp.net",
175
+ note: "Pembayaran lisensi bot bulanan",
176
+ // Atau lampirkan stiker
177
+ // sticker: { stickerMessage: ... }
178
+ }
179
+ });
180
+ ```
181
+
182
+ ### 6. Mengirim Pesan Acara (`EVENT`)
183
+ ```javascript
184
+ await sock.sendMessage(jid, {
185
+ eventMessage: {
186
+ name: "Clutch Gathering 2026",
187
+ description: "Temu komunitas developer & pengguna bot WhatsApp Indonesia.",
188
+ startTime: Date.now() + 86400000,
189
+ endTime: Date.now() + 86400000 + 7200000,
190
+ location: {
191
+ degreesLatitude: -6.200000,
192
+ degreesLongitude: 106.816666,
193
+ name: "Jakarta Convention Center"
194
+ },
195
+ joinLink: "https://chat.whatsapp.com/..."
196
+ }
197
+ });
198
+ ```
199
+
200
+ ### 7. Mengirim Hasil Poling (`POLL_RESULT`)
201
+ ```javascript
202
+ await sock.sendMessage(jid, {
203
+ pollResultMessage: {
204
+ name: "Hasil polling makan siang hari ini:",
205
+ pollVotes: [
206
+ { optionName: "Nasi Goreng", optionVoteCount: 15 },
207
+ { optionName: "Mie Ayam", optionVoteCount: 8 }
208
+ ]
209
+ }
210
+ });
211
+ ```
212
+
213
+ ### 8. Mengirim Pesan Interaktif (Native Flow Buttons / List / Tombol)
214
+ Kirim pesan interaktif dengan tombol native seperti pilihan menu (Single-Select List) atau tombol link (CTA URL).
215
+ ```javascript
216
+ await sock.sendMessage(jid, {
217
+ interactiveMessage: {
218
+ header: "Layanan Clutch",
219
+ title: "Silakan pilih salah satu menu di bawah ini untuk memulai transaksi.",
220
+ footer: "Clutch Bot System",
221
+ // Opsional: Sertakan gambar/media di bagian atas
222
+ // image: { url: "https://example.com/banner.jpg" },
223
+ buttons: [
224
+ {
225
+ name: "single_select",
226
+ buttonParamsJson: JSON.stringify({
227
+ title: "Buka Menu",
228
+ sections: [
229
+ {
230
+ title: "Daftar Produk",
231
+ rows: [
232
+ { id: "license_premium", title: "Lisensi Premium", description: "Beli lisensi bot 30 hari" },
233
+ { id: "topup_balance", title: "Top Up Saldo", description: "Isi ulang saldo instan" }
234
+ ]
235
+ }
236
+ ]
237
+ })
238
+ },
239
+ {
240
+ name: "cta_url",
241
+ buttonParamsJson: JSON.stringify({
242
+ display_text: "Gabung Grup",
243
+ url: "https://chat.whatsapp.com/...",
244
+ merchant_url: "https://chat.whatsapp.com/..."
245
+ })
246
+ }
247
+ ]
248
+ }
249
+ });
250
+ ```
251
+
252
+ ---
253
+
254
+ ## Kontak & Informasi Pengembang
255
+ Jika Anda memerlukan bantuan teknis, integrasi berbayar, atau ingin berkontribusi:
256
+ * **Developer**: Alip Clutch
257
+ * **Instagram**: [@mazzbudetzz__](https://instagram.com/mazzbudetzz__)
258
+ * **Telegram**: [@mazzbudetzz](https://t.me/mazzbudetzz)
259
+ * **WhatsApp**: [MazzBudetzzDigital](https://wa.me/MazzBudetzzDigital)