Free, Open Source, Self-Hosted WhatsApp API Gateway
TypeScript apibotgatewayself-hostedwhatsappwhatsapp-apiwhatsapp-automationwhatsapp-botwhatsapp-gatewaywhatsapp-gateway-apiwhatsapp-webwhatsapp-web-api
docs: align all docs with v0.3.0 (pluggable engine) + v0.4.0 (single-port deployment)
rmyndharisbb2cac56e45e
diff --git a/.env.example b/.env.exampleindex 5360cf5a3..fe258c1e7 100644--- a/.env.example+++ b/.env.example@@ -46,7 +46,7 @@ CORS_ORIGINS=*# ENGINE CONFIGURATION# =============================================================================# Which WhatsApp engine to use (plugin-based)-# Options: whatsapp-web.js, baileys (future)+# Options: whatsapp-web.js, baileysENGINE_TYPE=whatsapp-web.js# Engine-specific settingsdiff --git a/README.md b/README.mdindex a89394309..7da20bcad 100644--- a/README.md+++ b/README.md@@ -17,7 +17,7 @@<p align="center"><a href="https://github.com/rmyndharis/OpenWA/actions/workflows/ci.yml"><img src="https://github.com/rmyndharis/OpenWA/actions/workflows/ci.yml/badge.svg?branch=main" alt="CI"/></a>- <img src="https://img.shields.io/badge/version-0.2.10-blue.svg" alt="Version"/>+ <img src="https://img.shields.io/badge/version-0.4.0-blue.svg" alt="Version"/><img src="https://img.shields.io/badge/license-MIT-green.svg" alt="License"/><img src="https://img.shields.io/badge/node-22_LTS-brightgreen.svg" alt="Node"/><img src="https://img.shields.io/badge/NestJS-11.x-red.svg" alt="NestJS"/>@@ -279,7 +279,7 @@ curl -X POST http://localhost:2785/api/sessions/{sessionId}/webhooks \| **Runtime** | Node.js 22 LTS || **Framework** | NestJS 11.x || **Language** | TypeScript 5.x |-| **WA Engine** | whatsapp-web.js |+| **WA Engine** | whatsapp-web.js (default) / baileys — set `ENGINE_TYPE` || **Database** | SQLite / PostgreSQL || **Cache** | Redis (optional) || **Storage** | Local / S3 / MinIO |diff --git a/docs/01-project-overview.md b/docs/01-project-overview.mdindex 0fb61a920..ad57820a1 100644--- a/docs/01-project-overview.md+++ b/docs/01-project-overview.md@@ -224,9 +224,10 @@ flowchart TBNE --> |"Modular, scalable, DI"| API[REST API]end- subgraph Engine["WhatsApp Engine"]+ subgraph Engine["WhatsApp Engine (pluggable)"]WW[whatsapp-web.js] --> |"Puppeteer based"| P[More stealth]P --> |"Real browser fingerprint"| S[Lower ban risk]+ BA[baileys] --> |"Browser-free / WebSocket"| BL[Lower resource usage]endsubgraph Storage["Data Storage"]@@ -249,8 +250,8 @@ flowchart TB| Runtime | Node.js 20 LTS | Stable, long-term support || Language | TypeScript | Type safety, better developer experience || Framework | NestJS | Enterprise-grade, modular |-| WA Engine | whatsapp-web.js | Mature, active community |-| Browser | Puppeteer/Chrome | Real browser, stealth |+| WA Engine | whatsapp-web.js (default) or baileys | Pluggable via `ENGINE_TYPE` env var; wwebjs = Puppeteer/stealth, baileys = browser-free |+| Browser | Puppeteer/Chrome | Used by default (whatsapp-web.js) engine; not required for baileys engine || Database | SQLite (default) / PostgreSQL | Zero-config default, PostgreSQL for scaling || Cache | Redis | Fast, pub/sub support || Queue | Bull | Reliable job processing |@@ -265,7 +266,7 @@ flowchart TB1. **Technical**- WhatsApp Web protocol can change at any time- - Puppeteer requires significant resources (~300-500MB RAM per session)+ - Puppeteer requires significant resources (~300-500MB RAM per session) when using the default whatsapp-web.js engine; the baileys engine is browser-free and has a much lower footprint- WhatsApp rate limiting2. **Legal**diff --git a/docs/03-system-architecture.md b/docs/03-system-architecture.mdindex dc496c6d5..5d4fa8e86 100644--- a/docs/03-system-architecture.md+++ b/docs/03-system-architecture.md@@ -26,10 +26,9 @@ flowchart TBQM[Queue<br/>Manager]end- subgraph Engine["WhatsApp Engine"]- WW[whatsapp-web.js]- PP[Puppeteer]- CH[Chrome/Chromium]+ subgraph Engine["WhatsApp Engine (pluggable)"]+ WW[whatsapp-web.js<br/>Puppeteer/Chromium]+ BY[Baileys<br/>WebSocket/No browser]endsubgraph Storage["Storage Layer"]@@ -671,14 +670,14 @@ flowchart TBsubgraph Container["Docker Container"]subgraph Node["Node.js Runtime"]NEST[NestJS Application]- WW[whatsapp-web.js]+ WW[whatsapp-web.js<br/>or Baileys]end- subgraph Browser["Headless Browser"]+ subgraph Browser["Headless Browser (wwebjs only)"]CHROME[Chromium]end- Node --> Browser+ Node -.->|ENGINE_TYPE=whatsapp-web.js| Browserendsubgraph External["External Services"]@@ -883,7 +882,7 @@ flowchart LR## 3.12 Engine Abstraction Layer> [!IMPORTANT]-> Engine abstraction is critical to mitigate **R001: WhatsApp Protocol Changes** in Risk Management. With an abstraction layer, we can easily switch to an alternative engine (e.g., Baileys) when needed.+> Engine abstraction is critical to mitigate **R001: WhatsApp Protocol Changes** in Risk Management. OpenWA ships two production-ready engines selectable via `ENGINE_TYPE`: `whatsapp-web.js` (default, Chromium/Puppeteer-based) and `baileys` (browser-free, WebSocket/Noise protocol). With the abstraction layer, adding further engines requires no changes to application code.### Strategy Pattern for Engine@@ -1192,8 +1191,9 @@ ENGINE_TYPE=mock```mermaidflowchart TB- subgraph Current["Current State"]- A[whatsapp-web.js\nPuppeteer-based]+ subgraph Current["Available Engines"]+ A[whatsapp-web.js\nPuppeteer-based\ndefault]+ A2[Baileys\nWebSocket-based\nENGINE_TYPE=baileys]endsubgraph Risk["Risk Detection"]diff --git a/docs/06-api-specification.md b/docs/06-api-specification.mdindex 7e185c8b6..835411094 100644--- a/docs/06-api-specification.md+++ b/docs/06-api-specification.md@@ -908,7 +908,7 @@ delivery-status tracking behave identically to a direct text send.> **Scope (issue #69):** Only **Option B** — server-side text templates with> variable substitution — is supported. Interactive templates (buttons, list> messages, WhatsApp Business HSM / approved message templates) are **Option A**-> and are **not supported** on the whatsapp-web.js engine.+> and are **not supported** on any of the current engines (`whatsapp-web.js` or `baileys`).```httpPOST /api/sessions/:sessionId/messages/send-template@@ -956,7 +956,7 @@ to a session and rendered with `{{placeholder}}` substitution by thean API key with at least the `operator` role.> Interactive button / list / HSM templates (**Option A**) are out of scope on-> the whatsapp-web.js engine and are not provided.+> all current engines and are not provided.#### Create Templatediff --git a/docs/07-api-collection.md b/docs/07-api-collection.mdindex f9ee60776..3d54bef85 100644--- a/docs/07-api-collection.md+++ b/docs/07-api-collection.md@@ -438,13 +438,12 @@ curl -X POST http://localhost:2785/api/sessions/default/messages \**Interactive messages (Buttons / List): not supported**> ⚠️ **Buttons and List (interactive) messages are not available** through OpenWA's-> whatsapp-web.js engine. WhatsApp stopped honoring the interactive-message payload-> for unofficial web clients around 2021–2022 — the `Buttons` / `List` classes still-> exist in the library, but messages built with them are **silently dropped and never-> delivered** to recipients. OpenWA therefore does not expose `type: "buttons"` or-> `type: "list"` endpoints; sending interactive messages requires the official-> WhatsApp Business Cloud API. (The earlier examples here were speculative and never-> implemented — see #158.)+> unofficial-client engines (`whatsapp-web.js` default or `baileys`). WhatsApp stopped+> honoring the interactive-message payload for unofficial clients around 2021–2022 —+> messages of this type are **silently dropped and never delivered** to recipients.+> OpenWA therefore does not expose `type: "buttons"` or `type: "list"` endpoints;+> sending interactive messages requires the official WhatsApp Business Cloud API.+> (The earlier examples here were speculative and never implemented — see #158.)**Response:**```jsondiff --git a/docs/08-development-guidelines.md b/docs/08-development-guidelines.mdindex b5f3056ba..7b6bbd781 100644--- a/docs/08-development-guidelines.md+++ b/docs/08-development-guidelines.md@@ -814,7 +814,7 @@ API_KEY_MASTER=dev-master-key-change-in-productionSESSION_DATA_PATH=./.wwebjs_authMAX_SESSIONS=3-# Engine+# Engine (whatsapp-web.js = default, Chromium-based; baileys = browser-free WebSocket)ENGINE_TYPE=whatsapp-web.jsPUPPETEER_HEADLESS=true@@ -852,7 +852,7 @@ API_KEY_MASTER=your-secure-master-keySESSION_DATA_PATH=./.wwebjs_authMAX_SESSIONS=10-# Engine+# Engine (whatsapp-web.js = default, Chromium-based; baileys = browser-free WebSocket)ENGINE_TYPE=whatsapp-web.jsPUPPETEER_HEADLESS=truediff --git a/docs/11-operational-runbooks.md b/docs/11-operational-runbooks.mdindex d5cdb9003..05e96246e 100644--- a/docs/11-operational-runbooks.md+++ b/docs/11-operational-runbooks.md@@ -656,8 +656,12 @@ df -h### Resource Estimation+> **Engine note:** The figures below apply to the default `whatsapp-web.js` engine+> (Chromium/Puppeteer). With `ENGINE_TYPE=baileys` (browser-free), memory per session+> is significantly lower — re-baseline with your own load profile.+```-Per Session Requirements:+Per Session Requirements (ENGINE_TYPE=whatsapp-web.js):- Memory: 300-500MB (average 400MB)- CPU: 0.1-0.2 cores idle, 0.5 cores peak- Disk: 100MB base + ~1KB per messagediff --git a/docs/12-troubleshooting-faq.md b/docs/12-troubleshooting-faq.mdindex 7f7a4d7ac..f4bd8300f 100644--- a/docs/12-troubleshooting-faq.md+++ b/docs/12-troubleshooting-faq.md@@ -199,6 +199,8 @@ docker compose up -d### Issue: Session stuck at `authenticating`, never reaches `ready`+> **Engine:** This issue applies to the `whatsapp-web.js` engine only. If you are using `ENGINE_TYPE=baileys`, skip this section.+**Symptoms:** After scanning the QR the phone links the device, but the session stays at`authenticating` indefinitely and never becomes `ready`. `GET /sessions/:id/qr` returns 400 whilestuck. Often seen on ARM64 (e.g. Raspberry Pi) after upgrading to v0.2.x.@@ -220,6 +222,8 @@ Set `WWEBJS_WEB_VERSION=latest` (or leave it unset) to restore the default auto-### Issue: Session fails to launch with `chrome_crashpad_handler: --database is required`+> **Engine:** This issue applies to the `whatsapp-web.js` engine only (Chromium/Puppeteer-based). It does not affect `ENGINE_TYPE=baileys`.+**Symptoms:** The session never starts; the engine log shows `Failed to launch the browser process` with`chrome_crashpad_handler: --database is required`, and the host kernel log shows a Chromium`trap int3` / `Trace/breakpoint trap (core dumped)`. Seen on hardened, `read_only` containers.@@ -434,7 +438,8 @@ docker stats openwa --no-streamcurl -H "X-API-Key: $API_KEY" \http://localhost:2785/api/metrics/memory-# Expected: ~300-500MB per session+# Expected: ~300-500MB per session (whatsapp-web.js / Chromium engine)+# With ENGINE_TYPE=baileys the footprint is significantly lower (no Chromium)```**Solutions:**@@ -450,7 +455,7 @@ services:reservations:memory: 512Menvironment:- # Optimize Puppeteer+ # Optimize Puppeteer (whatsapp-web.js engine only)- PUPPETEER_ARGS=--disable-dev-shm-usage,--disable-gpu,--no-sandbox# Limit cache- WA_CACHE_SIZE=1000@@ -464,7 +469,7 @@ services:|--------------|--------|-----------|| Disable media cache | -30% RAM | Slower media re-send || Reduce message history | -20% RAM | Less searchable history |-| Headless Chrome flags | -15% RAM | None |+| Headless Chrome flags | -15% RAM (wwebjs only) | None || Limit concurrent sessions | Linear | Fewer sessions |### Issue: Slow API Response@@ -655,11 +660,12 @@ docker exec openwa curl http://host.docker.internal:8080> - Implement rate limiting**Q: How many sessions can I run?**-> A: Depends on your server resources:+> A: Depends on your server resources and the engine in use. With the default `whatsapp-web.js` engine (Chromium-based), each session uses ~300-500MB RAM:> - 2GB RAM: 3-5 sessions> - 4GB RAM: 8-10 sessions> - 8GB RAM: 15-20 sessions-> Each session uses ~300-500MB RAM.+>+> With `ENGINE_TYPE=baileys` (browser-free), RAM per session is significantly lower — you can run more sessions on the same hardware. Exact figures depend on message volume and group membership.**Q: Can I use WhatsApp Business account?**> A: Yes, OpenWA works with both personal and WhatsApp Business accounts. Note that WhatsApp Business API (official Meta API) is different and not supported.@@ -757,7 +763,10 @@ elsefi# Backup auth sessions+# whatsapp-web.js engine:cp -r ./data/.wwebjs_auth "$BACKUP_DIR/$DATE/"+# Baileys engine (ENGINE_TYPE=baileys): back up BAILEYS_AUTH_DIR (default: ./data/baileys)+# cp -r ./data/baileys "$BACKUP_DIR/$DATE/"# Keep only last 7 daysfind "$BACKUP_DIR" -type d -mtime +7 -exec rm -rf {} \;@@ -803,7 +812,7 @@ available_events:"from": "[email protected]","to": "[email protected]","body": "Hello!",- "type": "chat",+ "type": "text","timestamp": 1706868600,"isGroup": false,"author": null,diff --git a/docs/13-horizontal-scaling.md b/docs/13-horizontal-scaling.mdindex e043b495b..480e7b959 100644--- a/docs/13-horizontal-scaling.md+++ b/docs/13-horizontal-scaling.md@@ -66,7 +66,7 @@ flowchart TB## 13.2 Session Affinity Strategy-Since WhatsApp sessions maintain WebSocket connections and browser instances, they cannot be freely moved between nodes.+Since WhatsApp sessions maintain active connections (a browser instance for `whatsapp-web.js`, or a WebSocket for `baileys` — set via `ENGINE_TYPE`), they cannot be freely moved between nodes.### Strategy 1: Session-to-Node Mapping (Recommended)@@ -105,7 +105,7 @@ version: '3.8'services:openwa:- image: ghcr.io/rmyndharis/openwa:0.2.0+ image: ghcr.io/rmyndharis/openwa:0.4.0deploy:replicas: 1 # MUST stay 1 until session-claim is implemented — multiple replicas on one session volume corrupt WhatsApp auth (H1/H11)update_config:@@ -163,24 +163,10 @@ services:networks:- openwa-net- traefik:- image: traefik:v3.0- deploy:- replicas: 1- placement:- constraints:- - node.role == manager- ports:- - '80:80'- - '443:443'- volumes:- - /var/run/docker.sock:/var/run/docker.sock:ro- command:- - '--providers.swarm=true'- - '--entrypoints.web.address=:80'- - '--entrypoints.websecure.address=:443'- networks:- - openwa-net+ # NOTE (v0.4.0): OpenWA no longer ships a bundled Traefik container.+ # For TLS / public exposure, bring your own reverse proxy (Traefik, nginx,+ # Caddy, a cloud load balancer, etc.) and point it at openwa:2785.+ # See section 13.5 for Traefik / nginx config examples.volumes:postgres-data:@@ -237,7 +223,7 @@ data:REDIS_HOST: 'redis-service'REDIS_PORT: '6379'ENABLE_QUEUE: 'true'- API_PORT: '3000'+ PORT: '2785'```### k8s/secret.yaml@@ -277,9 +263,9 @@ spec:spec:containers:- name: openwa- image: ghcr.io/rmyndharis/openwa:0.2.0+ image: ghcr.io/rmyndharis/openwa:0.4.0ports:- - containerPort: 3000+ - containerPort: 2785name: httpenvFrom:- configMapRef:@@ -304,13 +290,13 @@ spec:livenessProbe:httpGet:path: /api/health- port: 3000+ port: 2785initialDelaySeconds: 30periodSeconds: 10readinessProbe:httpGet:path: /api/health/ready- port: 3000+ port: 2785initialDelaySeconds: 10periodSeconds: 5volumeClaimTemplates:@@ -337,7 +323,7 @@ spec:app: openwaports:- port: 80- targetPort: 3000+ targetPort: 2785name: http---apiVersion: v1@@ -350,7 +336,7 @@ spec:selector:app: openwaports:- - port: 3000+ - port: 2785name: http```diff --git a/docs/14-migration-guide.md b/docs/14-migration-guide.mdindex a421d7f87..96c08bfe0 100644--- a/docs/14-migration-guide.md+++ b/docs/14-migration-guide.md@@ -815,7 +815,7 @@ breaking_changes:- Rate limiting enforcedconfig:- - ENGINE_TYPE required (default: whatsapp-web.js)+ - ENGINE_TYPE required (default: whatsapp-web.js; also accepts: baileys)- STORAGE_ADAPTER required (default: local)database:@@ -874,7 +874,7 @@ echo "⚙️ Updating configuration..."cat >> .env << 'EOF'# New in v1.0-ENGINE_TYPE=whatsapp-web.js+ENGINE_TYPE=whatsapp-web.js # default (Chromium-based); set to "baileys" for browser-free engineSTORAGE_ADAPTER=localCACHE_ADAPTER=memorydiff --git a/docs/15-project-roadmap.md b/docs/15-project-roadmap.mdindex 4a72b16e0..206957c9e 100644--- a/docs/15-project-roadmap.md+++ b/docs/15-project-roadmap.md@@ -30,15 +30,19 @@ timeline: Webhook delivery-state & templates: Security & container hardening- section v0.3.0 - SDK & Observability- Q3 2026 : JavaScript/Node.js & Python SDK- : Docs Site- : Prometheus Metrics- : Grafana Dashboard+ section v0.3.0 - Engine Pluggability & Plugins (Released)+ Jun 2026 : Baileys engine (browser-free)+ : Pluggable ENGINE_TYPE env var+ : Plugin capability layer++ section v0.4.0 - Single-Port Deployment (Released)+ Jun 2026 : Dashboard served from API port+ : Bundled Traefik removed+ : Bring-your-own reverse proxysection v1.0.0 - Enterprise- Q4 2026 : Baileys Engine- : Kubernetes Operator+ 2027 : Kubernetes Operator+ : Multi-tenant```### Release Summary@@ -61,8 +65,9 @@ timeline| v0.2.8 | Engine decoupling (ack/type/JID), templates, @lid→phone | ✅ Released || v0.2.9 | Reliability/security/a11y hardening (RBAC, deps, shutdown, retention) | ✅ Released || v0.2.10 | Dashboard/CI follow-ups (MessageTester JID, neutral MessageType, qemu v4) | ✅ Released |-| v0.3.0 | Deployment simplification (single-port UI, no Traefik) — next breaking release | 📋 Planned |-| v1.0.0 | Enterprise Ready (Baileys engine, K8s) | 📋 Planned |+| v0.3.0 | Engine pluggability (Baileys engine, plugin layer) | ✅ Released |+| v0.4.0 | Single-port deployment (dashboard on API port, Traefik removed) | ✅ Released |+| v1.0.0 | Enterprise Ready (K8s Operator, multi-tenant) | 📋 Planned |> SDK / docs-site / observability features (Node & Python SDK, Postman collection, Grafana, OpenTelemetry)> are delivered **incrementally** in `0.2.x`/`0.3.x` as they're additive — they no longer gate a single@@ -486,7 +491,7 @@ v0.1.0 Release Package:## 15.6 Future Roadmap (v0.3.0+)> **Note:** Version 0.1.0 is the initial stable release including all features from Phases 1-3.-> Versions 0.1.7, 0.1.8, 0.2.0, and 0.2.1 have since shipped (see the CHANGELOG); v0.3.0+> Versions 0.1.7–0.2.10, 0.3.0, and 0.4.0 have since shipped (see the CHANGELOG); v1.0.0> onward is forward-looking.```mermaid@@ -504,13 +509,13 @@ flowchart LRV020[v0.2.0 - i18n, Real-time Chats,<br/>Webhook Delivery-state & Hardening]end- subgraph v0.x["v0.x Series - Enhancements"]- V030[v0.3.0 - SDK, Developer Tools & Observability]+ subgraph v0.x["✅ Released (v0.3–v0.4)"]+ V030[v0.3.0 - Engine Pluggability<br/>Baileys engine + plugin layer]+ V040[v0.4.0 - Single-Port Deployment<br/>Dashboard on API port, no bundled Traefik]endsubgraph v1.x["v1.x Series - Enterprise"]V10[v1.0.0 - Enterprise Ready]- V11[v1.1.0 - Multi-engine Support]endPhase1 --> Phase2 --> Stable --> v0.x --> v1.x@@ -527,13 +532,21 @@ flowchart LR| Security & API surface hardening | P0 | ✅ || Container / Podman hardening | P1 | ✅ |-### v0.3.0 — Deployment simplification (next breaking release)+### v0.3.0 — Engine pluggability & plugin layer (Released)++`0.3.0` shipped as a **breaking** release (per §15.2). It introduced a pluggable engine layer+(`ENGINE_TYPE` env var: `whatsapp-web.js` default or `baileys` for a browser-free alternative loaded+lazily), moved Puppeteer/browser config out of the neutral engine contract (#265), and added a Tier-2+plugin capability layer (`ctx.messages` / `ctx.engine`; `PluginContext.getService` removed).+Ships with a migration guide.++### v0.4.0 — Single-port deployment (Released)-`0.3.0` is the next **breaking** release (per §15.2). Its headline is the deployment simplification:-serve the dashboard from the API on a single port (`@nestjs/serve-static`) and drop the bundled Traefik-service (#275, #276), plus moving Puppeteer/browser config out of the neutral engine contract (#265).-Ships with a migration guide. The remaining engine-pluggability items (#265) and other non-breaking work-land across `0.2.x`.+`0.4.0` shipped as a **breaking** release. The dashboard SPA is now served directly from the API on its+own port (default `:2785`) via `@nestjs/serve-static`; the bundled Traefik service is removed (#275,+#276). Use your own reverse proxy (nginx, Caddy, a cloud load balancer) for TLS/public exposure.+`SERVE_DASHBOARD=false` opts out. The `DASHBOARD_PORT`, `PROXY_ENABLED`, and `DASHBOARD_ENABLED` env+vars are removed. Ships with a migration guide.#### Incremental themes — SDK, Developer Tools & Observability@@ -562,7 +575,6 @@ Delivered additively whenever ready (so they land in `0.2.x`/`0.3.x` per SemVer,| Feature | Priority | Description || ------------------- | -------- | ------------------------------ |-| Baileys Engine | P2 | Alternative lightweight engine || Kubernetes Operator | P3 | Native K8s deployment || Multi-tenant | P3 | Enterprise SaaS features || Encryption at rest | P2 | Full data encryption |diff --git a/docs/16-risk-management.md b/docs/16-risk-management.mdindex 0d02a5213..d4d0ae667 100644--- a/docs/16-risk-management.md+++ b/docs/16-risk-management.md@@ -52,13 +52,13 @@ flowchart TBM1 --> A1[Watch releases & issues]M2 --> A2[Engine interface pattern]- M3 --> A3[Baileys as backup]+ M3 --> A3[Baileys engine available - ENGINE_TYPE env]M4 --> A4[< 24h patch capability]```**Action Items:**1. Subscribe to `whatsapp-web.js` releases-2. Design the engine abstraction layer+2. Engine abstraction layer — implemented (pluggable `ENGINE_TYPE`: `whatsapp-web.js` default, `baileys` alternative)3. Document fallback procedures4. Maintain relationships with library maintainers@@ -431,7 +431,7 @@ flowchart TBM2 --> C1[Notify users]C1 --> C2[Switch to maintenance mode]C2 --> C3[Evaluate alternatives]- C3 --> |Baileys viable| C4[Implement Baileys engine]+ C3 --> |Baileys viable| C4[Switch to Baileys engine - set ENGINE_TYPE=baileys]C3 --> |No alternatives| C5[Project pause/EOL]```diff --git a/docs/19-plugin-architecture.md b/docs/19-plugin-architecture.mdindex 8081789ab..25a72726d 100644--- a/docs/19-plugin-architecture.md+++ b/docs/19-plugin-architecture.md@@ -21,7 +21,7 @@| **@openwa/plugin-sdk** | 🔜 Planned | NPM package not yet published || **Sandboxed execution** | 🔜 Planned | vm2 isolation not implemented || **Permission enforcement** | ⚠️ Partial | Defined in manifest, not enforced |-| **Built-in plugins** | 🔜 Planned | Auto-reply, Translation examples |+| **Built-in plugins** | ✅ Implemented | `auto-reply` + group auto-translation ship with v0.3.0, disabled by default || **Plugin marketplace** | 🔜 Planned | Install from npm/github |---diff --git a/docs/21-glossary.md b/docs/21-glossary.mdindex e0fe71986..f7c117c20 100644--- a/docs/21-glossary.md+++ b/docs/21-glossary.md@@ -16,7 +16,7 @@ An interface implementation that provides a specific capability. In OpenWA, adap- **Database Adapter**: SQLite, PostgreSQL- **Storage Adapter**: Local, S3- **Cache Adapter**: Memory, Redis-- **Engine Adapter**: whatsapp-web.js, Baileys (future)+- **Engine Adapter**: whatsapp-web.js (default), Baileys### API KeyAuthentication token to access the OpenWA API. Sent via the `X-API-Key` header.@@ -27,7 +27,7 @@ WhatsApp Web session authentication data stored in the `.wwebjs_auth/` folder. I## B### Baileys-An alternative Node.js library for WhatsApp Web that uses WebSocket directly without a browser. Lighter but easier to detect.+Node.js library for WhatsApp Web that uses WebSocket directly without a browser (no Chromium required). Available as a selectable engine in OpenWA via `ENGINE_TYPE=baileys`.### BroadcastSending the same message to multiple recipients. On WhatsApp, this differs from the native "Broadcast List" feature.@@ -66,7 +66,7 @@ Containerization platform for packaging and deploying applications. OpenWA is di## E### Engine-Component that handles communication with WhatsApp Web. The primary engine used is `whatsapp-web.js`.+Component that handles communication with WhatsApp Web. OpenWA supports pluggable engines selected via the `ENGINE_TYPE` environment variable: `whatsapp-web.js` (default, Chromium/Puppeteer-based) or `baileys` (browser-free, WebSocket-based).### EventA system-emitted occurrence, for example:@@ -252,7 +252,7 @@ Protocol for real-time bidirectional communication. Used for:- WhatsApp Web protocol (internal)### whatsapp-web.js-Primary Node.js library used by OpenWA to interact with WhatsApp Web. Uses Puppeteer to control the browser.+Default engine library used by OpenWA to interact with WhatsApp Web. Uses Puppeteer to control a headless Chromium browser. Selected via `ENGINE_TYPE=whatsapp-web.js` (or by omitting the env var).## Zdiff --git a/docs/DOCKER_ID.md b/docs/DOCKER_ID.mdindex c108b373e..782da2b9f 100644--- a/docs/DOCKER_ID.md+++ b/docs/DOCKER_ID.md@@ -91,8 +91,9 @@ Berikut variabel penting yang bisa disesuaikan di `.env`:| `API_PORT` | `2785` | Port REST API sekaligus Dashboard UI (disajikan oleh NestJS). || `DATABASE_TYPE` | `sqlite` | Jenis database yang digunakan (`sqlite` atau `postgres`). || `DATABASE_NAME` | `/app/data/openwa.sqlite` | Lokasi database SQLite atau nama database PostgreSQL. |-| `ENGINE_TYPE` | `whatsapp-web.js` | Driver/mesin engine WhatsApp yang digunakan. |-| `PUPPETEER_HEADLESS` | `true` | Menjalankan browser WhatsApp secara tersembunyi. |+| `ENGINE_TYPE` | `whatsapp-web.js` | Driver/mesin engine WhatsApp yang digunakan (`whatsapp-web.js` default, berbasis Chromium; atau `baileys`, tanpa browser). |+| `SERVE_DASHBOARD` | `true` | Sajikan Dashboard UI dari port API yang sama. Set `false` untuk menonaktifkan penyajian static files. |+| `PUPPETEER_HEADLESS` | `true` | Menjalankan browser WhatsApp secara tersembunyi (hanya berlaku untuk engine `whatsapp-web.js`). |---diff --git a/docs/README.md b/docs/README.mdindex fba27ad62..38cd898d7 100644--- a/docs/README.md+++ b/docs/README.md@@ -16,7 +16,7 @@</p><p align="center">- <img src="https://img.shields.io/badge/version-0.2.10-blue.svg" alt="Version"/>+ <img src="https://img.shields.io/badge/version-0.4.0-blue.svg" alt="Version"/><img src="https://img.shields.io/badge/license-MIT-green.svg" alt="License"/><img src="https://img.shields.io/badge/node-22_LTS-brightgreen.svg" alt="Node"/><img src="https://img.shields.io/badge/NestJS-11.x-red.svg" alt="NestJS"/>@@ -181,16 +181,18 @@ socket.on('message', msg => {| Audit Logging | Ready || Groups / Contacts / Labels API | Ready || Channels / Status / Catalog API | Experimental (engine-limited) |+| Pluggable Engine (wwebjs / Baileys) | Ready (set `ENGINE_TYPE`) |+| Plugin Extension System | Ready || Queue-based Webhook Retries | Optional (QUEUE_ENABLED=true) |## Tech Stack| Layer | Technology || --------- | ----------------------------- |-| Runtime | Node.js 20 LTS |+| Runtime | Node.js 22 LTS || Framework | NestJS 11.x || Language | TypeScript 5.x |-| WA Engine | whatsapp-web.js |+| WA Engine | Pluggable (`ENGINE_TYPE`): whatsapp-web.js (default) or Baileys || WebSocket | Socket.IO || Database | SQLite (default) / PostgreSQL || ORM | TypeORM |