# victor-hugos/vant-business architecture

> Architecture diagram of the GitHub repository victor-hugos/vant-business, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-01). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/victor-hugos/vant-business
- Repository: https://github.com/victor-hugos/vant-business

## Overview

VANT.Business is a commercial lead-generation site: visitors learn about its services, submit a diagnostic briefing, and the team follows up through its private admin workflow and WhatsApp. The repository also preserves internal tools, news, newsletter, and agent operations. Edges are limited to README statements and source-index or excerpt evidence; several admin API interactions are not visible in the sampled source and are marked unverified.

Main entry points: [`src/App.jsx`](https://github.com/victor-hugos/vant-business/blob/main/src/App.jsx) (Routes and shell), [`src/pages/AdminPublishingPage.jsx`](https://github.com/victor-hugos/vant-business/blob/main/src/pages/AdminPublishingPage.jsx) (Admin workspace), [`api/_newsStore.js`](https://github.com/victor-hugos/vant-business/blob/main/api/_newsStore.js) (News storage), [`api`](https://github.com/victor-hugos/vant-business/tree/main/api) (Admin API endpoints)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_public["Public experience"]
  node_app["Routes and shell<br/>[App.jsx]"]
  node_home["Home positioning<br/>[HomePage.jsx]"]
  node_solutions["Solutions catalog<br/>[RecursosPage.jsx]"]
  node_diagnosis["Diagnostic briefing<br/>[AutomatizePage.jsx]"]
  node_tooldata["Tool catalog<br/>[recursos.js]"]
end

subgraph group_commercial["Lead operations"]
  node_subscribe["Lead capture API<br/>[subscribe.js]"]
  node_leadstore[("Lead history<br/>[subscribe.js]")]
  node_adminui["Admin workspace"]
  node_loginui["Admin login"]
  node_leadworkflow["Lead prioritization<br/>[adminLeads.js]"]
  node_handoff["WhatsApp handoff"]
  node_adminapi["Admin API endpoints"]
end

subgraph group_editorial["Editorial operations"]
  node_newsapi["News API<br/>[news.js]"]
  node_newsstore[("News storage<br/>[_newsStore.js]")]
  node_newsletter["Newsletter digest"]
  node_newsletterstore[("Subscriber storage")]
  node_agentapi["Agent runner<br/>[admin-run-agent.js]"]
  node_agentdata["Agent blueprints<br/>[aiPipeline.js]"]
  node_newscollector["News collector<br/>[_newsCollector.js]"]
  node_toolsstore[("Tool storage<br/>[_toolsStore.js]")]
end

subgraph group_shared["Shared services"]
  node_auth["Admin authentication<br/>[_adminAuth.js]"]
  node_mailer["Email delivery<br/>[_mailer.js]"]
  node_events["Click tracking<br/>[track-click.js]"]
  node_out["Outbound redirect<br/>[out.js]"]
end

node_visitor(("Visitor"))
node_whatsapp(("WhatsApp"))
node_supabase[("Supabase")]

node_visitor -->|"opens site"| node_app
node_app -->|"routes to"| node_home
node_app -->|"routes to"| node_solutions
node_app -->|"routes to"| node_diagnosis
node_app -->|"routes to"| node_adminui
node_visitor -->|"requests diagnosis"| node_diagnosis
node_solutions -->|"uses catalog"| node_tooldata
node_diagnosis -->|"submits briefing"| node_subscribe
node_subscribe -->|"records lead"| node_leadstore
node_diagnosis -->|"builds handoff"| node_handoff
node_handoff -->|"opens conversation"| node_whatsapp
node_adminui -->|"renders login"| node_loginui
node_adminui -->|"builds pipeline"| node_leadworkflow
node_adminui -->|"loads fallback"| node_tooldata
node_adminui -.->|"requests admin data"| node_adminapi
node_adminapi -.->|"checks access"| node_auth
node_adminapi -.->|"manages news"| node_newsstore
node_adminapi -.->|"manages tools"| node_toolsstore
node_newsapi -.->|"reads news"| node_newsstore
node_newsletter -->|"loads news"| node_newsstore
node_newsletter -->|"loads subscribers"| node_newsletterstore
node_newsletter -->|"sends digest"| node_mailer
node_agentapi -->|"uses blueprints"| node_agentdata
node_newscollector -.->|"collects news"| node_newsstore
node_toolsstore -->|"stores tools"| node_supabase
node_newsstore -->|"stores news"| node_supabase
node_newsletterstore -->|"stores subscribers"| node_supabase
node_visitor -.->|"generates clicks"| node_events
node_out -.->|"tracks redirect"| node_events

click node_app "https://github.com/victor-hugos/vant-business/blob/main/src/App.jsx"
click node_home "https://github.com/victor-hugos/vant-business/blob/main/src/pages/HomePage.jsx"
click node_solutions "https://github.com/victor-hugos/vant-business/blob/main/src/pages/RecursosPage.jsx"
click node_diagnosis "https://github.com/victor-hugos/vant-business/blob/main/src/pages/AutomatizePage.jsx"
click node_tooldata "https://github.com/victor-hugos/vant-business/blob/main/src/data/recursos.js"
click node_subscribe "https://github.com/victor-hugos/vant-business/blob/main/api/subscribe.js"
click node_leadstore "https://github.com/victor-hugos/vant-business/blob/main/api/subscribe.js"
click node_adminui "https://github.com/victor-hugos/vant-business/blob/main/src/pages/AdminPublishingPage.jsx"
click node_loginui "https://github.com/victor-hugos/vant-business/blob/main/src/components/AdminLoginScreen.jsx"
click node_leadworkflow "https://github.com/victor-hugos/vant-business/blob/main/src/utils/adminLeads.js"
click node_handoff "https://github.com/victor-hugos/vant-business/blob/main/src/utils/briefingWhatsApp.js"
click node_adminapi "https://github.com/victor-hugos/vant-business/tree/main/api"
click node_auth "https://github.com/victor-hugos/vant-business/blob/main/api/_adminAuth.js"
click node_newsapi "https://github.com/victor-hugos/vant-business/blob/main/api/news.js"
click node_newsstore "https://github.com/victor-hugos/vant-business/blob/main/api/_newsStore.js"
click node_newsletter "https://github.com/victor-hugos/vant-business/blob/main/api/newsletter-digest.js"
click node_newsletterstore "https://github.com/victor-hugos/vant-business/blob/main/api/_newsletterStore.js"
click node_mailer "https://github.com/victor-hugos/vant-business/blob/main/api/_mailer.js"
click node_agentapi "https://github.com/victor-hugos/vant-business/blob/main/api/admin-run-agent.js"
click node_agentdata "https://github.com/victor-hugos/vant-business/blob/main/src/data/aiPipeline.js"
click node_newscollector "https://github.com/victor-hugos/vant-business/blob/main/api/_newsCollector.js"
click node_toolsstore "https://github.com/victor-hugos/vant-business/blob/main/api/_toolsStore.js"
click node_events "https://github.com/victor-hugos/vant-business/blob/main/api/track-click.js"
click node_out "https://github.com/victor-hugos/vant-business/blob/main/api/out.js"

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_app,node_home,node_solutions,node_diagnosis,node_tooldata toneBlue
class node_subscribe,node_leadstore,node_adminui,node_loginui,node_leadworkflow,node_handoff,node_adminapi,node_supabase toneAmber
class node_newsapi,node_newsstore,node_newsletter,node_newsletterstore,node_agentapi,node_agentdata,node_newscollector,node_toolsstore toneMint
class node_auth,node_mailer,node_events,node_out toneRose
class node_visitor,node_whatsapp toneIndigo
```

## Components

### Public experience

- [Routes and shell](https://github.com/victor-hugos/vant-business/blob/main/src/App.jsx): `src/App.jsx`
- [Home positioning](https://github.com/victor-hugos/vant-business/blob/main/src/pages/HomePage.jsx): `src/pages/HomePage.jsx`
- [Solutions catalog](https://github.com/victor-hugos/vant-business/blob/main/src/pages/RecursosPage.jsx): `src/pages/RecursosPage.jsx`
- [Diagnostic briefing](https://github.com/victor-hugos/vant-business/blob/main/src/pages/AutomatizePage.jsx): `src/pages/AutomatizePage.jsx`
- [Tool catalog](https://github.com/victor-hugos/vant-business/blob/main/src/data/recursos.js): `src/data/recursos.js`

### Lead operations

- [Lead capture API](https://github.com/victor-hugos/vant-business/blob/main/api/subscribe.js): `api/subscribe.js`
- [Lead history](https://github.com/victor-hugos/vant-business/blob/main/api/subscribe.js): `api/subscribe.js`
- [Admin workspace](https://github.com/victor-hugos/vant-business/blob/main/src/pages/AdminPublishingPage.jsx): `src/pages/AdminPublishingPage.jsx`
- [Admin login](https://github.com/victor-hugos/vant-business/blob/main/src/components/AdminLoginScreen.jsx): `src/components/AdminLoginScreen.jsx`
- [Lead prioritization](https://github.com/victor-hugos/vant-business/blob/main/src/utils/adminLeads.js): `src/utils/adminLeads.js`
- [WhatsApp handoff](https://github.com/victor-hugos/vant-business/blob/main/src/utils/briefingWhatsApp.js): `src/utils/briefingWhatsApp.js`
- [Admin API endpoints](https://github.com/victor-hugos/vant-business/tree/main/api): `api`

### Editorial operations

- [News API](https://github.com/victor-hugos/vant-business/blob/main/api/news.js): `api/news.js`
- [News storage](https://github.com/victor-hugos/vant-business/blob/main/api/_newsStore.js): `api/_newsStore.js`
- [Newsletter digest](https://github.com/victor-hugos/vant-business/blob/main/api/newsletter-digest.js): `api/newsletter-digest.js`
- [Subscriber storage](https://github.com/victor-hugos/vant-business/blob/main/api/_newsletterStore.js): `api/_newsletterStore.js`
- [Agent runner](https://github.com/victor-hugos/vant-business/blob/main/api/admin-run-agent.js): `api/admin-run-agent.js`
- [Agent blueprints](https://github.com/victor-hugos/vant-business/blob/main/src/data/aiPipeline.js): `src/data/aiPipeline.js`
- [News collector](https://github.com/victor-hugos/vant-business/blob/main/api/_newsCollector.js): `api/_newsCollector.js`
- [Tool storage](https://github.com/victor-hugos/vant-business/blob/main/api/_toolsStore.js): `api/_toolsStore.js`

### Shared services

- [Admin authentication](https://github.com/victor-hugos/vant-business/blob/main/api/_adminAuth.js): `api/_adminAuth.js`
- [Email delivery](https://github.com/victor-hugos/vant-business/blob/main/api/_mailer.js): `api/_mailer.js`
- [Click tracking](https://github.com/victor-hugos/vant-business/blob/main/api/track-click.js): `api/track-click.js`
- [Outbound redirect](https://github.com/victor-hugos/vant-business/blob/main/api/out.js): `api/out.js`

### Other components

- **Visitor**
- **WhatsApp**
- **Supabase**

## Connections

- Visitor → Routes and shell: opens site (evidence: `README.md`)
- Routes and shell → Home positioning: routes to (evidence: `src/App.jsx`)
- Routes and shell → Solutions catalog: routes to (evidence: `src/App.jsx`)
- Routes and shell → Diagnostic briefing: routes to (evidence: `src/App.jsx`)
- Routes and shell → Admin workspace: routes to (evidence: `src/App.jsx`)
- Visitor → Diagnostic briefing: requests diagnosis (evidence: `README.md`)
- Solutions catalog → Tool catalog: uses catalog (evidence: `src/data/recursos.js`)
- Diagnostic briefing → Lead capture API: submits briefing (evidence: `src/pages/AutomatizePage.jsx`)
- Lead capture API → Lead history: records lead (evidence: `README.md`)
- Diagnostic briefing → WhatsApp handoff: builds handoff (evidence: `src/pages/AutomatizePage.jsx`)
- WhatsApp handoff → WhatsApp: opens conversation (evidence: `README.md`)
- Admin workspace → Admin login: renders login (evidence: `src/pages/AdminPublishingPage.jsx`)
- Admin workspace → Lead prioritization: builds pipeline (evidence: `src/pages/AdminPublishingPage.jsx`)
- Admin workspace → Tool catalog: loads fallback (evidence: `src/pages/AdminPublishingPage.jsx`)
- Admin workspace → Admin API endpoints: requests admin data
- Admin API endpoints → Admin authentication: checks access (evidence: `api/admin-run-agent.js`)
- Admin API endpoints → News storage: manages news (evidence: `api/subscribe.js`)
- Admin API endpoints → Tool storage: manages tools (evidence: `api/_toolsStore.js`)
- News API → News storage: reads news
- Newsletter digest → News storage: loads news (evidence: `api/newsletter-digest.js`)
- Newsletter digest → Subscriber storage: loads subscribers (evidence: `api/newsletter-digest.js`)
- Newsletter digest → Email delivery: sends digest (evidence: `api/newsletter-digest.js`)
- Agent runner → Agent blueprints: uses blueprints (evidence: `api/admin-run-agent.js`)
- News collector → News storage: collects news
- Tool storage → Supabase: stores tools (evidence: `api/_toolsStore.js`)
- News storage → Supabase: stores news (evidence: `api/_newsStore.js`)
- Subscriber storage → Supabase: stores subscribers (evidence: `api/_newsletterStore.js`)
- Visitor → Click tracking: generates clicks
- Outbound redirect → Click tracking: tracks redirect
