# jiajunqiuwu/asistente-whatsapp architecture

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

- Interactive diagram: https://gitdiagram.com/jiajunqiuwu/asistente-whatsapp
- Repository: https://github.com/jiajunqiuwu/asistente-whatsapp

## Overview

Gestor de tareas combines an independent terminal workflow with a local Django/Angular account and news application. The web journey covers registration and email verification, authentication, preferences, filtered feed news, manual newsletter preview/send, and per-account attempt history; alert settings are stored but do not trigger alerts. The CLI separately manages SQLite tasks and can read feeds or preview/send a newsletter. Edges reflect README statements and the supplied source excerpts or index references; unsampled details are not inferred.

Main entry points: [`frontend/src/app/app.routes.ts`](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/app.routes.ts) (Page routes), [`backend/accounts/api_views.py`](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/api_views.py) (API endpoints), [`frontend/src/app/account.service.ts`](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/account.service.ts) (Account client), [`backend/accounts/newsletter_service.py`](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/newsletter_service.py) (Newsletter service)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_webui["Angular web UI"]
  node_angular["Angular app<br/>[app.ts]"]
  node_routes["Page routes<br/>[app.routes.ts]"]
  node_authui["Session client<br/>[auth.service.ts]"]
  node_accountui["Account client<br/>[account.service.ts]"]
  node_contracts["API contracts<br/>[api.models.ts]"]
  node_registerui["Registration page"]
  node_verifyui["Verification page"]
  node_prefsui["Preferences page"]
  node_newsui["News page<br/>[news.component.ts]"]
  node_newsletterui["Newsletter page"]
  node_historyui["History page"]
end

subgraph group_webapi["Django account API"]
  node_views["API endpoints<br/>[api_views.py]"]
  node_forms["Account forms<br/>[forms.py]"]
  node_verification["Email verification"]
  node_records[("Account records<br/>[models.py]")]
end

subgraph group_domain["News and messaging"]
  node_newsletter["Newsletter service"]
  node_feedreader["RSS Atom reader<br/>[news.py]"]
end

subgraph group_cli["Terminal application"]
  node_cli["CLI commands<br/>[__main__.py]"]
  node_briefing["CLI briefing<br/>[briefing.py]"]
  node_emailcli["CLI email<br/>[email_sender.py]"]
  node_tasks["Task operations<br/>[tasks.py]"]
  node_taskdb[("Task SQLite")]
end

node_person(("User"))
node_feeds[("Public feeds")]
node_mail["Email backend"]

node_person -->|"uses browser"| node_angular
node_angular -->|"loads pages"| node_routes
node_routes -->|"routes to"| node_registerui
node_routes -->|"routes to"| node_verifyui
node_routes -->|"routes to"| node_prefsui
node_routes -->|"routes to"| node_newsui
node_routes -->|"routes to"| node_newsletterui
node_routes -->|"routes to"| node_historyui
node_angular -->|"refreshes session"| node_authui
node_registerui -->|"registers through"| node_accountui
node_verifyui -->|"verifies through"| node_accountui
node_prefsui -->|"loads and saves"| node_accountui
node_newsletterui -->|"requests newsletter"| node_accountui
node_historyui -->|"loads history"| node_accountui
node_authui -->|"calls session API"| node_views
node_accountui -->|"calls account API"| node_views
node_views -->|"validates registration"| node_forms
node_views -->|"checks tokens"| node_verification
node_views -->|"requests preview or send"| node_newsletter
node_views -->|"reads and writes"| node_records
node_newsletter -->|"reads preferences and records attempts"| node_records
node_newsletter -->|"fetches news"| node_feedreader
node_feedreader -->|"reads RSS Atom"| node_feeds
node_newsletter -->|"sends manual email"| node_mail
node_person -->|"runs commands"| node_cli
node_cli -->|"builds briefing"| node_briefing
node_cli -->|"configures or sends"| node_emailcli
node_cli -->|"manages tasks"| node_tasks
node_briefing -->|"gets news"| node_feedreader
node_briefing -->|"gets pending tasks"| node_tasks
node_emailcli -->|"creates briefing"| node_briefing
node_emailcli -->|"sends optionally"| node_mail
node_tasks -->|"reads and writes"| node_taskdb

click node_angular "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/app.ts"
click node_routes "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/app.routes.ts"
click node_authui "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/auth.service.ts"
click node_accountui "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/account.service.ts"
click node_contracts "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/api.models.ts"
click node_registerui "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/register/register.component.ts"
click node_verifyui "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/verify-email/verify-email.component.ts"
click node_prefsui "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/preferences/preferences.component.ts"
click node_newsui "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/news/news.component.ts"
click node_newsletterui "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/newsletter/newsletter.component.ts"
click node_historyui "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/history/history.component.ts"
click node_views "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/api_views.py"
click node_forms "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/forms.py"
click node_verification "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/email_verification.py"
click node_records "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/models.py"
click node_newsletter "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/newsletter_service.py"
click node_feedreader "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/news.py"
click node_cli "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/__main__.py"
click node_briefing "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/briefing.py"
click node_emailcli "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/email_sender.py"
click node_tasks "https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/tasks.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_angular,node_routes,node_authui,node_accountui,node_contracts,node_registerui,node_verifyui,node_prefsui,node_newsui,node_newsletterui,node_historyui,node_person toneBlue
class node_views,node_forms,node_verification,node_records,node_feeds toneAmber
class node_newsletter,node_feedreader toneMint
class node_cli,node_briefing,node_emailcli,node_tasks,node_taskdb toneRose
class node_mail toneIndigo
```

## Components

### Angular web UI

- [Angular app](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/app.ts): `frontend/src/app/app.ts`
- [Page routes](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/app.routes.ts): `frontend/src/app/app.routes.ts`
- [Session client](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/auth.service.ts): `frontend/src/app/auth.service.ts`
- [Account client](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/account.service.ts): `frontend/src/app/account.service.ts`
- [API contracts](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/api.models.ts): `frontend/src/app/api.models.ts`
- [Registration page](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/register/register.component.ts): `frontend/src/app/register/register.component.ts`
- [Verification page](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/verify-email/verify-email.component.ts): `frontend/src/app/verify-email/verify-email.component.ts`
- [Preferences page](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/preferences/preferences.component.ts): `frontend/src/app/preferences/preferences.component.ts`
- [News page](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/news/news.component.ts): `frontend/src/app/news/news.component.ts`
- [Newsletter page](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/newsletter/newsletter.component.ts): `frontend/src/app/newsletter/newsletter.component.ts`
- [History page](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/frontend/src/app/history/history.component.ts): `frontend/src/app/history/history.component.ts`

### Django account API

- [API endpoints](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/api_views.py): `backend/accounts/api_views.py`
- [Account forms](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/forms.py): `backend/accounts/forms.py`
- [Email verification](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/email_verification.py): `backend/accounts/email_verification.py`
- [Account records](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/models.py): `backend/accounts/models.py`

### News and messaging

- [Newsletter service](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/backend/accounts/newsletter_service.py): `backend/accounts/newsletter_service.py`
- [RSS Atom reader](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/news.py): `app/news.py`

### Terminal application

- [CLI commands](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/__main__.py): `app/__main__.py`
- [CLI briefing](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/briefing.py): `app/briefing.py`
- [CLI email](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/email_sender.py): `app/email_sender.py`
- [Task operations](https://github.com/jiajunqiuwu/asistente-whatsapp/blob/main/app/tasks.py): `app/tasks.py`
- **Task SQLite**

### Other components

- **User**
- **Public feeds**
- **Email backend**

## Connections

- User → Angular app: uses browser
- Angular app → Page routes: loads pages (evidence: `frontend/src/app/app.routes.ts`)
- Page routes → Registration page: routes to (evidence: `frontend/src/app/app.routes.ts`)
- Page routes → Verification page: routes to (evidence: `frontend/src/app/app.routes.ts`)
- Page routes → Preferences page: routes to (evidence: `frontend/src/app/app.routes.ts`)
- Page routes → News page: routes to (evidence: `frontend/src/app/app.routes.ts`)
- Page routes → Newsletter page: routes to (evidence: `frontend/src/app/app.routes.ts`)
- Page routes → History page: routes to (evidence: `frontend/src/app/app.routes.ts`)
- Angular app → Session client: refreshes session (evidence: `frontend/src/app/app.ts`)
- Registration page → Account client: registers through (evidence: `frontend/src/app/register/register.component.ts`)
- Verification page → Account client: verifies through (evidence: `frontend/src/app/verify-email/verify-email.component.ts`)
- Preferences page → Account client: loads and saves (evidence: `frontend/src/app/preferences/preferences.component.ts`)
- Newsletter page → Account client: requests newsletter (evidence: `frontend/src/app/newsletter/newsletter.component.ts`)
- History page → Account client: loads history (evidence: `frontend/src/app/history/history.component.ts`)
- Session client → API endpoints: calls session API (evidence: `frontend/src/app/auth.service.ts`)
- Account client → API endpoints: calls account API (evidence: `frontend/src/app/account.service.ts`)
- API endpoints → Account forms: validates registration (evidence: `backend/accounts/api_views.py`)
- API endpoints → Email verification: checks tokens (evidence: `backend/accounts/api_views.py`)
- API endpoints → Newsletter service: requests preview or send (evidence: `backend/accounts/api_views.py`)
- API endpoints → Account records: reads and writes (evidence: `backend/accounts/api_views.py`)
- Newsletter service → Account records: reads preferences and records attempts (evidence: `backend/accounts/newsletter_service.py`)
- Newsletter service → RSS Atom reader: fetches news (evidence: `backend/accounts/newsletter_service.py`)
- RSS Atom reader → Public feeds: reads RSS Atom
- Newsletter service → Email backend: sends manual email
- User → CLI commands: runs commands
- CLI commands → CLI briefing: builds briefing (evidence: `app/__main__.py`)
- CLI commands → CLI email: configures or sends (evidence: `app/__main__.py`)
- CLI commands → Task operations: manages tasks (evidence: `app/__main__.py`)
- CLI briefing → RSS Atom reader: gets news (evidence: `app/briefing.py`)
- CLI briefing → Task operations: gets pending tasks (evidence: `app/briefing.py`)
- CLI email → CLI briefing: creates briefing (evidence: `app/email_sender.py`)
- CLI email → Email backend: sends optionally
- Task operations → Task SQLite: reads and writes (evidence: `app/tasks.py`)
