Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

anju-xpro-baileys

video-yt5.1kMIT9.0.1TypeScript support: included

WhatsApp API

whatsapp, js-whatsapp, whatsapp-api, whatsapp-web, whatsapp-chat, whatsapp-group, automation, baileys-elite, multi-device

readme

🚀 BAILEYS-ELITE


🔥 Ultimate WhatsApp Web API Experience 🥵

TypeScript JavaScript WhatsApp NPM


⚡️ Supercharged WhatsApp API 🌟

Elevate your messaging experience with the most advanced WhatsApp Web API solution available


🔮 | WHY BAILEYS-ELITE?

⚡ Lightning Fast
🛡️ Secure
🧩 Feature-Rich
🔄 Active Development

📌 | IMPORTANT NOTE

⚠️ The original repository was initially removed by its creator and subsequently taken over by WhiskeySockets. This enhanced version includes numerous improvements and powerful new features designed to transform your WhatsApp development experience.

💫 | INSTALLATION

📂 In package.json:

"dependencies": {
    "baileys-elite": "*"
}

⚙️ Terminal Installation:

npm install baileys-elite

🔌 Import:

// ESM 
import makeWASocket from 'baileys-elite'
// CommonJS
const { default: makeWASocket } = require("baileys-elite")

✨ | FEATURE SHOWCASE

🎀 Enhanced Features Matrix

Feature Description Status
🔊 Channel Messaging Send & manage WhatsApp channel content
🎛️ Interactive Messages Create rich button-based experiences
🤖 AI Message Icon Brand your bot messages with AI icon
🖼️ Enhanced Media Uncropped profile pictures & optimized media
🔐 Custom Pairing Personalized device pairing codes
🔧 Performance Optimizations Cleaner logs & improved signal handling
📱 Cross-Platform Works on all NodeJS supported platforms

🌱 SMALL BUT POWERFUL FEATURES 🎉

📰 | NEWSLETTER MANAGEMENT

<summary style="background: linear-gradient(90deg, #4F46E5, #7C3AED); color: white; padding: 10px 15px; border-radius: 5px; cursor: pointer; font-weight: bold;">📚 Expand Newsletter Features</summary>

📊 Get Newsletter Info

// By invite
const metadata = await sock.newsletterMetadata("invite", "xxxxx")
// By JID
const metadata = await sock.newsletterMetadata("jid", "abcd@newsletter")
console.log(metadata)

📝 Update Newsletter Content

// Update description
await sock.newsletterUpdateDescription("abcd@newsletter", "New Description")

// Update name
await sock.newsletterUpdateName("abcd@newsletter", "New Name")

// Update picture
await sock.newsletterUpdatePicture("abcd@newsletter", buffer)

// Remove picture
await sock.newsletterRemovePicture("abcd@newsletter")

🔔 Notification Management

// Unmute newsletter
await sock.newsletterUnmute("abcd@newsletter")

// Mute newsletter
await sock.newsletterMute("abcd@newsletter")

🔄 Newsletter Management

// Create new newsletter
const metadata = await sock.newsletterCreate("Newsletter Name", "Newsletter Description")
console.log(metadata)

// Delete newsletter
await sock.newsletterDelete("abcd@newsletter")

// Follow newsletter
await sock.newsletterFollow("abcd@newsletter")

// Unfollow newsletter
await sock.newsletterUnfollow("abcd@newsletter")

😀 Engagement Features

// Send reaction to newsletter post
// Get ID from message URL: https://whatsapp.com/channel/xxxxx/175
const id = "175"
await sock.newsletterReactMessage("abcd@newsletter", id, "🥳")

🎛️ | INTERACTIVE MESSAGING

<summary style="background: linear-gradient(90deg, #EC4899, #F43F5E); color: white; padding: 10px 15px; border-radius: 5px; cursor: pointer; font-weight: bold;">🎯 Expand Button & Interactive Features</summary>

📝 Text Buttons

const buttons = [
  { buttonId: 'id1', buttonText: { displayText: 'Button 1' }, type: 1 },
  { buttonId: 'id2', buttonText: { displayText: 'Button 2' }, type: 1 }
]

const buttonMessage = {
    text: "Hi it's button message",
    footer: 'Hello World',
    buttons,
    headerType: 1,
    viewOnce: true
}

await sock.sendMessage(id, buttonMessage, { quoted: null })

🖼️ Image Buttons

const buttons = [
  { buttonId: 'id1', buttonText: { displayText: 'Button 1' }, type: 1 },
  { buttonId: 'id2', buttonText: { displayText: 'Button 2' }, type: 1 }
]

const buttonMessage = {
    image: { url: "https://example.com/abcd.jpg" }, // image: buffer or path
    caption: "Hi it's button message with image",
    footer: 'Hello World',
    buttons,
    headerType: 1,
    viewOnce: true
}

await sock.sendMessage(id, buttonMessage, { quoted: null })

🎬 Video Buttons

const buttons = [
  { buttonId: 'id1', buttonText: { displayText: 'Button 1' }, type: 1 },
  { buttonId: 'id2', buttonText: { displayText: 'Button 2' }, type: 1 }
]

const buttonMessage = {
    video: { url: "https://example.com/abcd.mp4" }, // video: buffer or path
    caption: "Hi it's button message with video",
    footer: 'Hello World',
    buttons,
    headerType: 1,
    viewOnce: true
}

await sock.sendMessage(id, buttonMessage, { quoted: null })

🔄 Advanced Interactive Messages

const interactiveButtons = [
     {
        name: "quick_reply",
        buttonParamsJson: JSON.stringify({
             display_text: "Quick Reply",
             id: "ID"
        })
     },
     {
        name: "cta_url",
        buttonParamsJson: JSON.stringify({
             display_text: "Tap Here!",
             url: "https://www.example.com/"
        })
     },
     {
        name: "cta_copy",
        buttonParamsJson: JSON.stringify({
             display_text: "Copy Code",
             id: "12345",
             copy_code: "12345"
        })
     }
]

const interactiveMessage = {
    text: "Hello World!",
    title: "this is the title",
    footer: "this is the footer",
    interactiveButtons
}

await sock.sendMessage(id, interactiveMessage, { quoted: null })

🖼️ Rich Media Interactive Messages

const interactiveButtons = [
     {
        name: "quick_reply",
        buttonParamsJson: JSON.stringify({
             display_text: "Quick Reply",
             id: "ID"
        })
     },
     {
        name: "cta_url",
        buttonParamsJson: JSON.stringify({
             display_text: "Visit Website",
             url: "https://www.example.com/"
        })
     }
]

// With Image
const imageInteractiveMessage = {
    image: { url: "https://example.com/abcd.jpg" },
    caption: "Check out this amazing photo!",
    title: "Photo Showcase",
    footer: "Tap a button below",
    interactiveButtons
}

await sock.sendMessage(id, imageInteractiveMessage, { quoted: null })

// With Video
const videoInteractiveMessage = {
    video: { url: "https://example.com/abcd.mp4" },
    caption: "Watch this awesome video!",
    title: "Video Showcase",
    footer: "Tap a button below",
    interactiveButtons
}

await sock.sendMessage(id, videoInteractiveMessage, { quoted: null })

🤖 | AI MESSAGING

AI Icon Feature

// Simply add "ai: true" to display AI icon with your message
await sock.sendMessage(id, { text: "Hello! I'm your AI assistant.", ai: true })
💡 Pro Tip: AI icons make your bot messages stand out and indicate automated responses to users.

🔐 | CUSTOM PAIRING

Custom Code Implementation

if(usePairingCode && !sock.authState.creds.registered) {
    const phoneNumber = await question('Please enter your mobile phone number:\n')
    const custom = "SH1Z0D3V" // must be 8 digits, can be letters or numbers
    const code = await sock.requestPairingCode(phoneNumber, custom)
    console.log(`Pairing code: ${code?.match(/.{1,4}/g)?.join('-') || code}`)
}
🔒 Security Note: Custom pairing codes enhance security while providing a personalized experience.

🛠️ | QUICK IMPLEMENTATION GUIDE

🚀 Step 1: Install

Add baileys-elite to your project using npm

npm install baileys-elite

🔄 Step 2: Import

Import the library into your project

import makeWASocket from 'baileys-elite'

⚙️ Step 3: Configure

Set up your WhatsApp connection

const sock = makeWASocket({...})

🚀 Step 4: Implement

Start using the enhanced features

await sock.sendMessage(id, {...})

🐛 | REPORTING ISSUES

Found a bug? Have a suggestion?

If you encounter any issues while using this repository, please feel free to open a new issue.

👾 Our team actively monitors and responds to all issues.

📝 | NOTES

Everything other than the modifications mentioned above remains the same as the original repository. You can check out the original repository at WhiskeySockets.

⭐ STAR THIS REPOSITORY ⭐
👨‍💻 Developers
🤖 Bot Creators
🚀 Innovators

Powered by Baileys-Elite - The Ultimate WhatsApp Web API Experience