@mbermeo/wa-blaster 0.1.4 → 0.1.7
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 +72 -6
- package/bin/wa-blast.js +22 -0
- package/dist/node20/cli/index.jsc +0 -0
- package/dist/node20/cli/lib.jsc +0 -0
- package/dist/node20/mcp/index.jsc +0 -0
- package/dist/node20/src/accountManager.jsc +0 -0
- package/dist/node20/src/campaignRunner.jsc +0 -0
- package/dist/node20/src/db.jsc +0 -0
- package/dist/node20/src/paths.jsc +0 -0
- package/dist/node20/src/routes/accounts.jsc +0 -0
- package/dist/node20/src/routes/campaigns.jsc +0 -0
- package/dist/node20/src/routes/inbound.jsc +0 -0
- package/dist/node20/src/server.jsc +0 -0
- package/dist/node20/src/utils/csvParser.jsc +0 -0
- package/dist/node20/src/utils/templateEngine.jsc +0 -0
- package/dist/node22/cli/index.jsc +0 -0
- package/dist/node22/cli/lib.jsc +0 -0
- package/dist/node22/mcp/index.jsc +0 -0
- package/dist/node22/src/accountManager.jsc +0 -0
- package/dist/node22/src/campaignRunner.jsc +0 -0
- package/dist/node22/src/db.jsc +0 -0
- package/dist/node22/src/paths.jsc +0 -0
- package/dist/node22/src/routes/accounts.jsc +0 -0
- package/dist/node22/src/routes/campaigns.jsc +0 -0
- package/dist/node22/src/routes/inbound.jsc +0 -0
- package/dist/node22/src/server.jsc +0 -0
- package/dist/node22/src/utils/csvParser.jsc +0 -0
- package/dist/node22/src/utils/templateEngine.jsc +0 -0
- package/dist/node24/cli/index.jsc +0 -0
- package/dist/node24/cli/lib.jsc +0 -0
- package/dist/node24/mcp/index.jsc +0 -0
- package/dist/node24/src/accountManager.jsc +0 -0
- package/dist/node24/src/campaignRunner.jsc +0 -0
- package/dist/node24/src/db.jsc +0 -0
- package/dist/node24/src/paths.jsc +0 -0
- package/dist/node24/src/routes/accounts.jsc +0 -0
- package/dist/node24/src/routes/campaigns.jsc +0 -0
- package/dist/node24/src/routes/inbound.jsc +0 -0
- package/dist/node24/src/server.jsc +0 -0
- package/dist/node24/src/utils/csvParser.jsc +0 -0
- package/dist/node24/src/utils/templateEngine.jsc +0 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,21 @@
|
|
|
1
|
-
#
|
|
1
|
+
# `@mbermeo/wa-blaster` — Sistema de Mensajes Masivos por WhatsApp
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://www.npmjs.com/package/@mbermeo/wa-blaster)
|
|
4
|
+
[](https://nodejs.org/)
|
|
5
|
+
|
|
6
|
+
Sistema para enviar mensajes masivos por WhatsApp con soporte multi-cuenta, plantillas con variables, imágenes con A/B testing, scheduling por hora/día, control de campañas y comportamiento anti-spam. Incluye API HTTP, interfaz web, **CLI** y **MCP server** para que agentes de IA (Claude, etc.) lo controlen nativamente.
|
|
7
|
+
|
|
8
|
+
## Inicio rápido
|
|
9
|
+
|
|
10
|
+
```bash
|
|
11
|
+
# Levantar el server (auto-detecta puerto libre, datos en ~/.wa-blast/)
|
|
12
|
+
npx -y @mbermeo/wa-blaster@latest serve
|
|
13
|
+
|
|
14
|
+
# Desde otra terminal: usar el CLI
|
|
15
|
+
npx -y @mbermeo/wa-blaster@latest accounts list
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
Para integrar con Claude Desktop / Code, ver [`docs/AGENT_MCP.md`](docs/AGENT_MCP.md).
|
|
4
19
|
|
|
5
20
|
---
|
|
6
21
|
|
|
@@ -30,19 +45,70 @@ Sistema para enviar mensajes masivos por WhatsApp con soporte multi-cuenta, plan
|
|
|
30
45
|
|
|
31
46
|
## Requisitos
|
|
32
47
|
|
|
33
|
-
- **Node.js
|
|
34
|
-
- **
|
|
35
|
-
-
|
|
36
|
-
|
|
48
|
+
- **Node.js 20.x, 22.x o 24.x** — el paquete distribuye bytecode V8 compilado para esas versiones específicas. Si usás otra versión, el binario falla con un mensaje claro al ejecutarse.
|
|
49
|
+
- **macOS, Linux o Windows** — Puppeteer descarga Chromium automáticamente la primera vez (~170 MB).
|
|
50
|
+
- **Un teléfono con WhatsApp** para escanear el QR de autenticación.
|
|
51
|
+
|
|
52
|
+
### ¿No tenés una versión compatible de Node?
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
# Con nvm (recomendado)
|
|
56
|
+
nvm install 22 && nvm use 22
|
|
57
|
+
|
|
58
|
+
# Con fnm
|
|
59
|
+
fnm install 22 && fnm use 22
|
|
60
|
+
|
|
61
|
+
# Con volta
|
|
62
|
+
volta install node@22
|
|
63
|
+
|
|
64
|
+
# Manual: descargá la LTS desde https://nodejs.org/
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
Verificá con:
|
|
68
|
+
```bash
|
|
69
|
+
node --version # debe imprimir v20.x, v22.x o v24.x
|
|
70
|
+
```
|
|
37
71
|
|
|
38
72
|
---
|
|
39
73
|
|
|
40
74
|
## Instalación
|
|
41
75
|
|
|
76
|
+
### Como CLI/MCP (recomendado)
|
|
77
|
+
|
|
78
|
+
No requiere instalación: usá `npx` directamente.
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
# Probar
|
|
82
|
+
npx -y @mbermeo/wa-blaster@latest --version
|
|
83
|
+
|
|
84
|
+
# Levantar el server (puerto auto-asignado por el OS)
|
|
85
|
+
npx -y @mbermeo/wa-blaster@latest serve
|
|
86
|
+
|
|
87
|
+
# Usar el CLI desde otra terminal (auto-detecta el server)
|
|
88
|
+
npx -y @mbermeo/wa-blaster@latest accounts list
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
Tip: agregá un alias en tu `~/.zshrc` o `~/.bashrc` para no repetir el namespace:
|
|
92
|
+
```bash
|
|
93
|
+
alias wab='npx -y @mbermeo/wa-blaster@latest'
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
### Como dependencia global
|
|
97
|
+
|
|
98
|
+
```bash
|
|
99
|
+
npm install -g @mbermeo/wa-blaster
|
|
100
|
+
wa-blast --version
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
### Desde el código fuente (desarrollo)
|
|
104
|
+
|
|
42
105
|
```bash
|
|
43
106
|
git clone <repo>
|
|
44
107
|
cd agente_whatsapp
|
|
45
108
|
npm install
|
|
109
|
+
npm run build # compila bytecode para tu versión actual de Node
|
|
110
|
+
npm run build:all # compila para Node 20, 22, 24 (requiere nvm)
|
|
111
|
+
npm test
|
|
46
112
|
```
|
|
47
113
|
|
|
48
114
|
---
|
package/bin/wa-blast.js
CHANGED
|
@@ -22,6 +22,28 @@
|
|
|
22
22
|
const fs = require('fs');
|
|
23
23
|
const path = require('path');
|
|
24
24
|
|
|
25
|
+
// ─── Preflight: versión de Node mínima ──────────────────────────────────────
|
|
26
|
+
// Bytenode genera bytecode específico por versión mayor de V8/Node, así que
|
|
27
|
+
// si el usuario está en una versión sin bytecode compilado, fallamos temprano
|
|
28
|
+
// con un mensaje claro y accionable. Esto se complementa con engines.node
|
|
29
|
+
// del package.json (warning) y con el check posterior por target específico.
|
|
30
|
+
(function preflight() {
|
|
31
|
+
const major = parseInt(process.versions.node.split('.')[0], 10);
|
|
32
|
+
const MIN = 20;
|
|
33
|
+
if (major < MIN) {
|
|
34
|
+
process.stderr.write(
|
|
35
|
+
`\n[wa-blast] Node ${process.versions.node} no es compatible.\n` +
|
|
36
|
+
`[wa-blast] Se requiere Node >= ${MIN}.x\n\n` +
|
|
37
|
+
`Soluciones:\n` +
|
|
38
|
+
` • Con nvm: nvm install 22 && nvm use 22\n` +
|
|
39
|
+
` • Con fnm: fnm install 22 && fnm use 22\n` +
|
|
40
|
+
` • Con volta: volta install node@22\n` +
|
|
41
|
+
` • Manual: https://nodejs.org/ (descargá la LTS)\n\n`
|
|
42
|
+
);
|
|
43
|
+
process.exit(1);
|
|
44
|
+
}
|
|
45
|
+
})();
|
|
46
|
+
|
|
25
47
|
// ─── Pre-parseo de flags globales ────────────────────────────────────────────
|
|
26
48
|
// Minimal, antes de cargar nada más. El CLI/lib reparsea normalmente después.
|
|
27
49
|
//
|
|
Binary file
|
package/dist/node20/cli/lib.jsc
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/node20/src/db.jsc
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/node22/cli/lib.jsc
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/node22/src/db.jsc
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/node24/cli/lib.jsc
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/node24/src/db.jsc
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|