How enrique-nunez/bot-whatsapp works
Project type and purpose
• This is an open‑source, full‑stack TypeScript monorepo for “BuilderBot,” a conversational‑flow framework and CLI tool.
• It uses Nx/Lerna for workspace management, Rollup for bundling, Jest for tests, Husky/Commitlint/Prettier/ESLint for quality, and GitHub Actions for CI/CD.
• Primary use case: let developers generate and run WhatsApp bots agnostic to provider, with pluggable database adapters and NLP/context integrations.
File structure
• Top‑level config: pnpm-workspace.yaml, nx.json, lerna.json, package.json
• packages/ contains:
• bot – core library that handles flows, state, events, I/O abstractions, utils
• cli – a CLI to create projects, run checks, install dependencies
• contexts‑* – Dialogflow/other context integrations
• database‑* – adapters for JSON, Mongo, MySQL, Postgres
• provider‑* – WhatsApp provider plugins (Baileys, Meta, Twilio, Venom, WPPConnect)
• eslint-plugin-builderbot – code linting rules for flow correctness
• starters/ holds templated app skeletons for each combination of provider + database + language (JS/TS)
• scripts/ orchestrates code generation, zone definitions, cleanup
README
• Describes “BuilderBot” as an agnostic WhatsApp bot framework plus a generator (npm create builderbot@latest).