# anirudhbagri/whatsapp-bulk-messenger architecture

> Architecture diagram of the GitHub repository anirudhbagri/whatsapp-bulk-messenger, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-27). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/anirudhbagri/whatsapp-bulk-messenger
- Repository: https://github.com/anirudhbagri/whatsapp-bulk-messenger

## Overview

This is a small command-line tool for sending one text message to a list of WhatsApp numbers. The workflow reads the message and recipients, opens WhatsApp Web for a user-managed login, then visits each recipient and sends the message. The README mentions personalized messages using other CSV columns, but the sampled implementation reads line-separated numbers and does not show templating. The graph reflects the inspected script and documented login flow.

Main entry points: [`automator.py`](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py) (Command Entry), [`message.txt`](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/message.txt) (Message Text), [`numbers.txt`](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/numbers.txt) (Recipient Numbers)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_inputs["Message Inputs"]
  node_message_file["Message Text<br/>[message.txt]"]
  node_numbers_file["Recipient Numbers<br/>[numbers.txt]"]
end

subgraph group_automation["Sending Workflow"]
  node_main["Command Entry<br/>[automator.py]"]
  node_message_reader["Read Message<br/>[automator.py]"]
  node_number_reader["Read Numbers<br/>[automator.py]"]
  node_driver["Browser Driver<br/>[automator.py]"]
  node_login["WhatsApp Login<br/>[automator.py]"]
  node_sender["Send Messages<br/>[automator.py]"]
end

node_user(("User"))
node_browser["Chrome Browser"]
node_whatsapp["WhatsApp Web"]

node_user -->|"runs"| node_main
node_message_reader -->|"reads"| node_message_file
node_number_reader -->|"reads"| node_numbers_file
node_main -->|"calls"| node_message_reader
node_main -->|"calls"| node_number_reader
node_main -->|"creates"| node_driver
node_driver -->|"controls"| node_browser
node_main -->|"calls"| node_login
node_login -->|"opens"| node_browser
node_browser -->|"loads"| node_whatsapp
node_user -->|"confirms login"| node_login
node_main -->|"calls"| node_sender
node_sender -->|"navigates and clicks"| node_browser
node_sender -->|"sends text"| node_whatsapp

click node_message_file "https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/message.txt"
click node_numbers_file "https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/numbers.txt"
click node_main "https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py"
click node_message_reader "https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py"
click node_number_reader "https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py"
click node_driver "https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py"
click node_login "https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py"
click node_sender "https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_message_file,node_numbers_file,node_user,node_browser toneBlue
class node_main,node_message_reader,node_number_reader,node_driver,node_login,node_sender toneAmber
class node_whatsapp toneIndigo
```

## Components

### Message Inputs

- [Message Text](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/message.txt): `message.txt`
- [Recipient Numbers](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/numbers.txt): `numbers.txt`

### Sending Workflow

- [Command Entry](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py): `automator.py`
- [Read Message](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py): `automator.py`
- [Read Numbers](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py): `automator.py`
- [Browser Driver](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py): `automator.py`
- [WhatsApp Login](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py): `automator.py`
- [Send Messages](https://github.com/anirudhbagri/whatsapp-bulk-messenger/blob/primary/automator.py): `automator.py`

### Other components

- **User**
- **Chrome Browser**
- **WhatsApp Web**

## Connections

- User → Command Entry: runs
- Read Message → Message Text: reads
- Read Numbers → Recipient Numbers: reads
- Command Entry → Read Message: calls
- Command Entry → Read Numbers: calls
- Command Entry → Browser Driver: creates
- Browser Driver → Chrome Browser: controls
- Command Entry → WhatsApp Login: calls
- WhatsApp Login → Chrome Browser: opens
- Chrome Browser → WhatsApp Web: loads
- User → WhatsApp Login: confirms login
- Command Entry → Send Messages: calls
- Send Messages → Chrome Browser: navigates and clicks
- Send Messages → WhatsApp Web: sends text
