npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@mtplusdev/wappy

v1.0.23

Published

Wappy é sua ponte entre ideias e mensagens. Crie bots com WhatsApp de forma simples.

Readme

🌐 Wappy · 💬🤖

Logo Wappy é sua ponte entre ideias e mensagens.

Uma biblioteca simples e poderosa para criar bots, integrações e automações no WhatsApp usando a engine Baileys.

Desenvolvido com 💚 por @MTplusWebSystem


🚀 Instalação

npm install @mtplusdev/wappy qrcode-terminal express cors

A qrcode-terminal exibe o QR Code diretamente no terminal. Instale junto ao wappy no seu projeto. Server fornece a payload para conversão em qr-code


⚡ Exemplo rápido qr-terminal

// main.js
import { createWappy } from '@mtplusdev/wappy';
import qrcode from 'qrcode-terminal';

const client = await createWappy({
  sessionName: 'teste',
  printQRInTerminal: true,
  qrCallback: (qr) => qrcode.generate(qr, { small: true }),
  all: true, // ✅ Permite ou ignora mensagens enviadas por todos
  viewLog: true, // ✅ Mostra logs básicos
  fromMe: false, // ✅ Permite ou ignora mensagens enviadas por você mesmo
  groupIgnore: true, // ✅ Ignora mensagens de grupos
});

client.on('message', async ({ text, targetJid, msg }) => {
  if (text.toLowerCase() === 'ping') {
    await client.sendText(targetJid, '🏓 pong!');
  }

  if (text.toLowerCase() === 'replay') {
    await client.replay(targetJid, '🔁 Isso é uma resposta com citação!', msg);
  }
});

client.start();

💡 Execute com node main.mjs se seu package.json tiver "type": "module".


⚡ Exemplo rápido qr-server

import { createWappy,createServer,startServe } from '@mtplusdev/wappy';

const client = await createWappy({
  sessionName: 'teste',
  qrCallback: (qr) => {
    createServer(qr)
    return qr;
  },
  all: true, // ✅ Permite ou ignora mensagens enviadas por todos
  viewLog: true, // ✅ Mostra logs básicos
  fromMe: false, // ✅ Permite ou ignora mensagens enviadas por você mesmo
  groupIgnore: true, // ✅ Ignora mensagens de grupos
});

startServe("4000")

client.on('message', async ({ text, targetJid, msg }) => {
  if (text.toLowerCase() === 'ping') {
    await client.sendText(targetJid, '🏓 pong!');
  }

  if (text.toLowerCase() === 'replay') {
    await client.replay(targetJid, '🔁 Isso é uma resposta com citação!', msg);
  }
});

client.start();

💡 Execute com node main.mjs se seu package.json tiver "type": "module".


✨ Novidades

🚀 Server

const client = await createWappy({
  qrCallback: (qr) => {
    createServer(qr)
    return qr;
  },
});

retorno no /qr-connection

ex:

{
	"qrCode": "2@B9K5q7U7VrKG4ZgmE8XAW5osqzOIVgeA/YxQvlwbvhI52S6kbw6ehQMw+8KBRKRfl4vr6QLrpxur77DShXqS6Rltl4y97zABq8A=,lwL8/4vwgvKOvD6njZ/Da4i6EDZPLZIoBtndFa+Y6C0=,d9VzKcnYTMWJ4ki4tJ2VRT2nAKmoZXdYU4/Ozm/SKG8=,wnRChE2+ZXzbd4E0S0wwczJYnqrwywlhciYwfUsa/U4=",
	"pairCode": null
}

🔁 replay(jid, text, quotedMsg)

🔁 sendDocument(jid, text, quotedMsg)

Agora é possível responder mensagens com citação, como no WhatsApp tradicional e enviar arquivos.

client.on('message', async ({ text, targetJid, msg }) => {
  if (text.toLowerCase() === '/apk') {
    const filePath = './storage/RVX_19.16.39.apk';

    await client.sendDocument(targetJid, filePath, {
      mimetype: 'application/vnd.android.package-archive',
      fileName: 'youtubeMod.apk'
    });

    await client.replay(
      targetJid,
      "Seu apk foi enviado com sucesso...\nAgora logue com suas informações de teste.",
      msg
    );
  }
});

⚙️ Novos parâmetros na criação:

| Parâmetro | Descrição | | ------------- | ---------------------------------------------------------------------- | | fromMe | Aceita ou ignora mensagens enviadas por você mesmo (true ou false) | | all | Aceita ou ignora mensagens enviadas por todos (true ou false) | | groupIgnore | Ignora mensagens de grupos (true) | | viewLog | Mostra log básico de mensagens recebidas no terminal (true) |


🧱 Estrutura modular para projetos grandes

Se quiser criar uma aplicação robusta e escalável:

/seu-projeto
├── main.js           # ponto de entrada
├── handler.js        # manipulador de mensagens
├── package.json
└── auth/             # sessões geradas automaticamente

main.js

import { createWappy } from '@mtplusdev/wappy';
import qrcode from 'qrcode-terminal';
import { handleMessage } from './handler.js';

const client = await createWappy({
  sessionName: 'meu-bot',
  qrCallback: (qr) => qrcode.generate(qr, { small: true }),
  viewLog: true
});

client.on('message', handleMessage(client));
client.start();

handler.js

export function handleMessage(client) {
  return async ({ text, targetJid, msg }) => {
    if (!text) return;

    if (text.toLowerCase() === 'ping') {
      await client.sendText(targetJid, '🏓 pong!');
    }

    if (text.toLowerCase() === 'responder') {
      await client.replay(targetJid, '🔁 Resposta com citação!', msg);
    }
  };
}

📂 Sessão e autenticação

O Wappy salva sua sessão automaticamente em:

auth/<sessionName>/

Para forçar um novo login, basta apagar essa pasta.


✅ Recursos

  • 📡 Conexão com QR Code
  • 🔄 Reconexão automática
  • 💬 Escuta de mensagens com filtro
  • ✉️ Envio de mensagens (sendText)
  • 🔁 Resposta com citação (replay)
  • 🎯 Filtros para grupos e mensagens do próprio bot

📄 Licença

MIT