Skip to content

Instantly share code, notes, and snippets.

@KingRoxy01
KingRoxy01 / index.js
Created September 22, 2025 10:44
Super admin WhatsApp bot
import makeWASocket, { fetchLatestBaileysVersion } from "@whiskeysockets/baileys";
import { existsSync, writeFileSync, readFileSync } from "fs";
import path from "path";
const __dirname = path.resolve();
const authFile = path.join(__dirname, "auth_info.json");
const storageFile = path.join(__dirname, "bot_storage.json");
let authState = { creds: {}, keys: {} };
let storage = { bans: {}, mutes: {}, activity: {} }; // per group