Skip to content

crysnovax/CODY

Repository files navigation

Cody AI V2 Banner

XXX

Cody AI V2

Powered by CRYSNOVA AI — The Most Advanced WhatsApp Self-Bot Ever Built


Stars Forks Issues License Version Node

✦ Quick Links

Channel Support Group GitHub


🚀 One-Click Deploy

Deploy to Heroku Deploy to Render Deploy to Vercel

🔗 Pair & Get Session ID

Pair Session


⚉ What is Cody AI?

Cody AI V2 is a premium-grade WhatsApp self-bot powered by CRYSNOVA AI built on Node.js and Baileys. It runs directly on your personal WhatsApp account and delivers enterprise-level automation, AI integration, and group management — all for free.

Built and maintained by crysnovax · Nigeria 🔥


🚀 Why Cody AI Stands Apart

Feature Description
Dynamic Plugin System Drop .js files to add commands — zero restarts, zero config
🧠 Multi-Model AI Suite GPT-4.5, DeepSeek, Gemini, image gen, voice AI, custom agents
🌐 250+ Language Support Auto-translation + localised responses in any language
✍️ 100+ Font Styles Monospace, cursive, gothic, runes, manga and more
🎨 Advanced Media Editing Upscale, remove BG, cartoonify, watermark, glow, pixelate
🛡️ 24/7 Stable Connection Auto-reconnect, keep-alive, session persistence
👥 Full Group Management Warn system, anti-spam, anti-link, welcome/goodbye, mute, kick
🔒 Safe & Battle-Tested Zero ban reports — months of active production use
💎 250+ Commands AI · Media · Admin · Economy · Fun · Downloader · Tools

🔥 Full Feature Breakdown

🤖 AI Suite
  • GPT-4.5, DeepSeek, Gemini integration
  • AI image generation & editing
  • Story writing, horror mode, code assistant
  • Smart chatbot with per-chat memory & training
  • Voice transcription (Whisper)
  • Image description & OCR
  • AI background changer & remini enhance
🖼️ Media & Editing
  • Remove background, cartoonify, sketch
  • Upscale, pixelate, glow, invert, blur
  • Color filters: gold, cyan, red, purple, green, gray
  • Image collage & merge
  • Sticker maker, GIF converter
  • View-once revealer (VV)
  • Wanted poster, jail overlay, burial card
👥 Group Management
  • Anti-link, anti-word, anti-spam, anti-tag
  • Anti group mention (status mention detection)
  • Welcome & goodbye messages with profile photo
  • Warn system with appeal flow (3-strike auto-kick)
  • Mute user, mute sticker, group lock/unlock
  • Poll creator, hidetag, tagall
  • Promote / demote / kick / add members
⬇️ Downloaders
  • YouTube (audio + video), Spotify, TikTok
  • Facebook, Instagram, Pinterest
  • APK downloader, Mediafire, direct links
  • Shazam song recognition + download
🔧 Owner & Bot Controls
  • AFK system with auto-disable & timer
  • Auto-read, anti-call, auto-react
  • Fake typing (all messages or commands only)
  • Status view, status like, save status, post status
  • Sudo system (3-layer permission)
  • Bot font (per-chat + global)
  • Auto-translation (per-chat + global)
  • Runtime variable control (setvar/getvar/delvar)
  • Live reload — no restart needed
🛠️ Tools & Utilities
  • Scientific calculator, QR code, URL shortener
  • Temporary email, virtual number
  • Anti-delete (DM or in-chat, global private mode)
  • Reminder system, font converter (100+ fonts)
  • Translate, reverse translate
  • Document converter: Word, PDF, HTML, ZIP, TXT
  • Weather, dictionary, wiki, news, esports
🎵 Audio Effects
  • 8D audio, bass boost, nightcore, reverb
  • Robot, chipmunk, drunk, deep, slow
  • Echo, distort, tremolo, reverse
  • Voice changer (TTS with multiple voices)
  • Audio merge

⚙️ Requirements

  • Node.js v23 or higher
  • npm v8+
  • A WhatsApp account (self-bot — runs on your number)
  • Recommended: VPS / Linux server (AWS, Pterodactyl, etc.)
  • warning ⚠️; this project was built specifically for forked bailey @crysnovax/baileys and will totally malfunction without it

📦 Installation

# 1. Clone the repository
git clone https://github.com/crysnovax/CODY.git
cd CODY

# 2. Install dependencies
npm install

# 3. Configure your settings
cp settings/config.example.js settings/config.js
# Edit config.js with your number, prefix, etc.

# 4. Start the bot
node index.js

On first run you will be prompted for a pairing code. Enter your WhatsApp number and link via Settings → Linked Devices → Link a Device.


⚡ Quick Setup (VPS)

# If RAM is limited, add swap first
sudo fallocate -l 2G /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile

# Then install and start
npm install && node index.js

❔AUTO DEPLOY PANEL SCRIPT

paste in panel and save as index.js

const { execSync, spawn } = require('child_process');
const fs = require('fs');
const path = require('path');
const readline = require('readline');

// Colors (ANSI codes)
const colors = {
    reset: '\x1b[0m',
    bright: '\x1b[1m',
    dim: '\x1b[2m',
    black: '\x1b[30m', red: '\x1b[31m', green: '\x1b[32m',
    yellow: '\x1b[33m', blue: '\x1b[34m', magenta: '\x1b[35m',
    cyan: '\x1b[36m', white: '\x1b[37m',
    bgBlack: '\x1b[40m', bgGreen: '\x1b[42m'
};

function c(text, color = 'white') {
    return `${colors[color]}${text}${colors.reset}`;
}

const rl = readline.createInterface({
    input: process.stdin,
    output: process.stdout
});

function ask(question) {
    return new Promise((resolve) => {
        rl.question(question, (answer) => resolve(answer.trim()));
    });
}

function run(command, cwd = '.') {
    console.log(c(`[RUN] ${command}`, 'dim'));
    try {
        return execSync(command, { cwd, encoding: 'utf8', stdio: 'inherit' });
    } catch (error) {
        console.error(c(`[ERROR] Command failed: ${command}`, 'red'));
        throw error;
    }
}

// .env helpers
function readEnv(envPath) {
    if (!fs.existsSync(envPath)) return {};
    const map = {};
    for (const line of fs.readFileSync(envPath, 'utf8').split('\n')) {
        const trimmed = line.trim();
        if (!trimmed || trimmed.startsWith('#')) continue;
        const idx = trimmed.indexOf('=');
        if (idx === -1) continue;
        map[trimmed.slice(0, idx).trim()] = trimmed.slice(idx + 1).trim();
    }
    return map;
}

function writeEnv(envPath, updates) {
    if (!fs.existsSync(envPath)) {
        const lines = Object.entries(updates).map(([k, v]) => `${k}=${v}`).join('\n');
        fs.writeFileSync(envPath, lines + '\n');
        return;
    }
    const raw = fs.readFileSync(envPath, 'utf8').split('\n');
    const seen = new Set();
    const out = [];
    for (const line of raw) {
        const trimmed = line.trim();
        if (!trimmed || trimmed.startsWith('#')) { out.push(line); continue; }
        const idx = trimmed.indexOf('=');
        if (idx === -1) { out.push(line); continue; }
        const k = trimmed.slice(0, idx).trim();
        seen.add(k);
        out.push(k in updates ? `${k}=${updates[k]}` : line);
    }
    for (const [k, v] of Object.entries(updates)) {
        if (!seen.has(k)) out.push(`${k}=${v}`);
    }
    fs.writeFileSync(envPath, out.join('\n'));
}

// Check if config is complete
function isConfigComplete(env) {
    return env.OWNER_NUMBER && env.OWNER_NAME && env.BOT_NAME &&
           env.OWNER_NUMBER.length >= 10;
}

// Display banner
function showBanner() {
    console.clear();
    console.log(c('\n╔══════════════════════════════════════════════════════════════╗', 'cyan'));
    console.log(c('║                                                              ║', 'cyan'));
    console.log(c('║             ', 'cyan') + c('🚀 Cody AI V2 — DEPLOY SCRIPT 🚀', 'bright') + c('            ║', 'cyan'));
    console.log(c('║                                                              ║', 'cyan'));
    console.log(c('║         ', 'cyan') + c('Automated Setup & Configuration System', 'yellow') + c('              ║', 'cyan'));
    console.log(c('║                                                              ║', 'cyan'));
    console.log(c('╚══════════════════════════════════════════════════════════════╝', 'cyan'));
    console.log('');
}

// Display existing config
function showExistingConfig(env) {
    console.log(c('┌─────────────────────────────────────────────────────────────┐', 'green'));
    console.log(c('│                                                             │', 'green'));
    console.log(c('│  ', 'green') + c('✅ CONFIGURATION FOUND!', 'bright') + c('                                 │', 'green'));
    console.log(c('│                                                             │', 'green'));
    console.log(c('├─────────────────────────────────────────────────────────────┤', 'green'));
    console.log(c('│                                                             │', 'green'));
    console.log(c('│  ', 'green') + c(`👤 Owner: ${env.OWNER_NAME}`, 'white') + ' '.repeat(Math.max(0, 50 - env.OWNER_NAME.length)) + c('│', 'green'));
    console.log(c('│  ', 'green') + c(`📞 Number: ${env.OWNER_NUMBER}`, 'white') + ' '.repeat(Math.max(0, 49 - env.OWNER_NUMBER.length)) + c('│', 'green'));
    console.log(c('│  ', 'green') + c(`🤖 Bot: ${env.BOT_NAME}`, 'white') + ' '.repeat(Math.max(0, 52 - env.BOT_NAME.length)) + c('│', 'green'));
    console.log(c('│                                                             │', 'green'));
    console.log(c('└─────────────────────────────────────────────────────────────┘', 'green'));
    console.log('');
    console.log(c('🔄 Using existing configuration...\n', 'cyan'));
}

// Ask for new configuration
async function askForConfig(envPath) {
    console.log(c('┌─────────────────────────────────────────────────────────────┐', 'magenta'));
    console.log(c('│                                                             │', 'magenta'));
    console.log(c('│  ', 'magenta') + c('📋 FIRST TIME SETUP', 'bright') + c('                                     │', 'magenta'));
    console.log(c('│                                                             │', 'magenta'));
    console.log(c('│  ', 'magenta') + c('Please provide the following information:', 'yellow') + c('                │', 'magenta'));
    console.log(c('│                                                             │', 'magenta'));
    console.log(c('└─────────────────────────────────────────────────────────────┘', 'magenta'));
    console.log('');

    // Owner Number
    console.log(c('┌─────────────────────────────────────────────────────────────┐', 'blue'));
    console.log(c('│ 1. OWNER NUMBER                                             │', 'blue'));
    console.log(c('└─────────────────────────────────────────────────────────────┘', 'blue'));
    console.log(c('   💡 Your WhatsApp number without + (e.g., 2348077528901)', 'dim'));
    
    let ownerNumber = await ask(c('   Enter: ', 'yellow'));
    while (!ownerNumber || !/^\d{10,15}$/.test(ownerNumber)) {
        console.log(c('   ❌ Invalid! Must be 10-15 digits only', 'red'));
        ownerNumber = await ask(c('   Enter: ', 'yellow'));
    }
    console.log(c(`   ✓ Number: ${ownerNumber}\n`, 'green'));

    // Owner Name
    console.log(c('┌─────────────────────────────────────────────────────────────┐', 'blue'));
    console.log(c('│ 2. OWNER NAME                                               │', 'blue'));
    console.log(c('└─────────────────────────────────────────────────────────────┘', 'blue'));
    console.log(c('   💡 Your name or nickname', 'dim'));
    
    let ownerName = await ask(c('   Enter: ', 'yellow'));
    if (!ownerName) ownerName = 'Cody AI';
    console.log(c(`   ✓ Name: ${ownerName}\n`, 'green'));

    // Bot Name
    console.log(c('┌─────────────────────────────────────────────────────────────┐', 'blue'));
    console.log(c('│ 3. BOT NAME                                                 │', 'blue'));
    console.log(c('└─────────────────────────────────────────────────────────────┘', 'blue'));
    console.log(c('   💡 Display name for your bot', 'dim'));
    
    let botName = await ask(c('   Enter: ', 'yellow'));
    if (!botName) botName = 'Cody AI V2';
    console.log(c(`   ✓ Bot: ${botName}\n`, 'green'));

    // Save to .env
    writeEnv(envPath, {
        BOT_NAME: botName,
        OWNER_NUMBER: ownerNumber,
        OWNER_NUMBERS: ownerNumber,
        OWNER_NAME: ownerName,
    });

    // Show success
    console.log(c('┌─────────────────────────────────────────────────────────────┐', 'green'));
    console.log(c('│                                                             │', 'green'));
    console.log(c('│  ', 'green') + c('✅ CONFIGURATION SAVED!', 'bright') + c('                                 │', 'green'));
    console.log(c('│                                                             │', 'green'));
    console.log(c('│  ', 'green') + c(`👤 Owner: ${ownerName}`, 'white') + ' '.repeat(Math.max(0, 50 - ownerName.length)) + c('│', 'green'));
    console.log(c('│  ', 'green') + c(`📞 Number: ${ownerNumber}`, 'white') + ' '.repeat(Math.max(0, 49 - ownerNumber.length)) + c('│', 'green'));
    console.log(c('│  ', 'green') + c(`🤖 Bot: ${botName}`, 'white') + ' '.repeat(Math.max(0, 52 - botName.length)) + c('│', 'green'));
    console.log(c('│                                                             │', 'green'));
    console.log(c('└─────────────────────────────────────────────────────────────┘', 'green'));
    console.log('');
}

// Main setup function
async function setupConfiguration() {
    const envPath = path.join(PROJECT_DIR, '.env');
    const envExamplePath = path.join(PROJECT_DIR, '.env.example');

    // Create .env from example if doesn't exist
    if (!fs.existsSync(envPath) && fs.existsSync(envExamplePath)) {
        fs.copyFileSync(envExamplePath, envPath);
        console.log(c('✓ Created .env from template\n', 'green'));
    }

    // Read existing config
    const env = readEnv(envPath);

    // Check if config is complete
    if (isConfigComplete(env)) {
        // Auto-use existing config, no questions!
        showExistingConfig(env);
        return;
    }

    // First time or incomplete - ask for config
    await askForConfig(envPath);
}

const PROJECT_DIR = 'CODY';
const REPO_URL = 'https://github.com/crysnovax/CODY.git';
const ENTRY_FILE = 'index.js';

async function main() {
    showBanner();
    
    console.log(c('═══ STARTING DEPLOYMENT ═══\n', 'bright'));

    // Step 1: Clone
    if (!fs.existsSync(PROJECT_DIR)) {
        console.log(c('[1/4] 📥 Cloning repository...', 'cyan'));
        run(`git clone ${REPO_URL} ${PROJECT_DIR}`);
        console.log(c('✓ Cloned!\n', 'green'));
    } else {
        console.log(c('[1/4] ✓ Repository exists\n', 'green'));
    }

    // Step 2: Install
    console.log(c('[2/4] 📦 Installing dependencies...', 'cyan'));
    run('npm install', PROJECT_DIR);
    console.log(c('✓ Dependencies ready!\n', 'green'));

    // Step 3: Configure (SMART - asks only once!)
    console.log(c('[3/4] ⚙️  Checking configuration...', 'cyan'));
    await setupConfiguration();
    rl.close();

    // Step 4: Start
    console.log(c('[4/4] 🚀 Starting bot...', 'cyan'));
    console.log('');

    const mainJsPath = path.join(PROJECT_DIR, ENTRY_FILE);
    const packageJsonPath = path.join(PROJECT_DIR, 'package.json');
    
    let startCommand, startArgs;

    if (fs.existsSync(mainJsPath)) {
        startCommand = 'node';
        startArgs = [ENTRY_FILE];
    } else if (fs.existsSync(packageJsonPath)) {
        const pkg = JSON.parse(fs.readFileSync(packageJsonPath, 'utf8'));
        if (pkg.scripts?.start) {
            startCommand = 'npm';
            startArgs = ['start'];
        } else {
            throw new Error(`No ${ENTRY_FILE} or start script found`);
        }
    } else {
        throw new Error(`No ${ENTRY_FILE} found`);
    }

    console.log(c('╔══════════════════════════════════════════════════════════════╗', 'green'));
    console.log(c('║                                                              ║', 'green'));
    console.log(c('║             ', 'green') + c('🎉 BOT IS STARTING! 🎉', 'bright') + c('                          ║', 'green'));
    console.log(c('║                                                              ║', 'green'));
    console.log(c('╚══════════════════════════════════════════════════════════════╝', 'green'));
    console.log('');

    const child = spawn(startCommand, startArgs, {
        cwd: PROJECT_DIR,
        stdio: 'inherit',
        shell: true
    });

    child.on('close', (code) => process.exit(code));
    child.on('error', (err) => {
        console.error(c('Failed to start:', 'red'), err);
        process.exit(1);
    });
}

main().catch(err => {
    console.error(c('\n❌ FAILED:', 'red'), err.message);
    rl.close();
    process.exit(1);
});

🗂️ Project Structure

CODY/
├── index.js               ← Entry point
├── ?.js                   ← Message routing engine
├── settings/
│   └── config.js          ← Bot configuration
├── src/
│   ├── Commands/          ← All command files (by category)
│   ├── Plugin/            ← Core handlers & plugins
│   └── core/              ← Command registry
├── library/
│   └── serialize.js       ← Message serializer
└── database/              ← Runtime data (JSON)

✦ Configuration Reference

Key Default Description
PREFIX . Command prefix
OWNER_NUMBER Your WhatsApp number
PUBLIC_MODE false Allow all users to use commands
AUTO_READ true Auto-read messages
AUTO_REACT true React to commands
ANTI_CALL true Auto-reject calls
MENU_STYLE 0 Menu design (0–6)
TIMEZONE Africa/Lagos Your timezone
BOT_LANG en Bot language

All values can be changed live with .setvar KEY VALUE — no restart needed.


✦ Command Format

module.exports = {
    name:      'example',
    alias:     ['ex'],
    desc:      'An example command',
    category:  'Tools',
    sudoOnly:  false,
    reactions: { start: '⚙️', success: '✅' },

    execute: async (sock, m, { args, reply }) => {
        await reply('Hello World!');
    }
};

Drop the file into the correct src/Commands/<Category>/ folder and run .reload — no restart needed.


🛡️ Security & Safety

  • Runs as a self-bot — WhatsApp does not flag personal automation the same way as business API abuse
  • No data is sent to third parties without your explicit commands
  • Session credentials are stored locally only
  • Zero ban reports in months of active production use across multiple accounts

📊 Stats

GitHub Activity


🤝 Contributing

Pull requests are welcome. For major changes, open an issue first to discuss.

  1. Fork the repository
  2. Create your feature branch: git checkout -b feature/my-feature
  3. Commit your changes: git commit -m 'Add my feature'
  4. Push to the branch: git push origin feature/my-feature
  5. Open a Pull Request

📄 License

This project is licensed under the MIT License — see LICENSE for details.


Built with 🔥 by crysnovax

If this project helped you, please consider giving it a ⭐

Star History Chart


© 2026 Cody AI Powered by CRYSNOVA AI · by crysnovax · All Rights Reserved

About

CODY AI >> brought to you by CRYSNOVA_AI

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Generated from crysnovax/CRYSNOVA_AI