# rdanielsstat/hub-platform architecture

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

- Interactive diagram: https://gitdiagram.com/rdanielsstat/hub-platform
- Repository: https://github.com/rdanielsstat/hub-platform

## Overview

Hub-Platform is a personal idea-management application: users sign in, capture and score ideas, track them through lifecycle statuses, and refine them with notes, links, and dashboard filters. The React client calls a FastAPI backend, whose routers enforce identity and usage limits before using a SQL-backed store. The README documents the product capabilities and deployment/observability design; source excerpts and the SOURCE INDEX substantiate the shown calls. Some frontend and backend feature internals are unsampled, so their relationships are shown only where documented.

Main entry points: [`backend/app/main.py`](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/main.py) (FastAPI application), [`frontend/src/services/api/http.ts`](https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/services/api/http.ts) (API client), [`frontend/src/App.tsx`](https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/App.tsx) (App shell), [`backend/app/routers/auth.py`](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/routers/auth.py) (Authentication API)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Web application"]
  node_app["App shell<br/>[App.tsx]"]
  node_auth_ui["Sign-in screens<br/>[login.tsx]"]
  node_dashboard["Idea dashboard<br/>[dashboard.tsx]"]
  node_capture["Quick capture"]
  node_detail["Project details<br/>[project-detail.tsx]"]
  node_notes_ui["Notes panel<br/>[notes-panel.tsx]"]
  node_api_client["API client<br/>[http.ts]"]
end

subgraph group_api["API and domain"]
  node_auth_routes["Authentication API<br/>[auth.py]"]
  node_project_routes["Project lifecycle API<br/>[projects.py]"]
  node_note_routes["Notes API<br/>[notes.py]"]
  node_error_routes["Client error API<br/>[errors.py]"]
  node_api_app["FastAPI application<br/>[main.py]"]
  node_project_model["Project domain<br/>[project.py]"]
end

subgraph group_persistence["Persistence"]
  node_store["SQL data store<br/>[store.py]"]
  node_database[("SQLite / Postgres<br/>[session.py]")]
end

subgraph group_security["Security controls"]
  node_quota["Usage caps<br/>[quotas.py]"]
  node_auth_controls["Identity controls<br/>[security.py]"]
  node_rate_limit["IP rate limits<br/>[rate_limit.py]"]
end

subgraph group_operations["Observability"]
  node_otel["Telemetry setup<br/>[__init__.py]"]
  node_grafana["Grafana Cloud"]
  node_lambda["AWS Lambda"]
end

node_user(("Personal user"))

node_user -->|"uses"| node_app
node_app -->|"routes unauthenticated"| node_auth_ui
node_app -->|"routes signed-in"| node_dashboard
node_app -->|"routes project"| node_detail
node_app -->|"opens capture"| node_capture
node_dashboard -.->|"loads and filters"| node_api_client
node_capture -.->|"creates idea"| node_api_client
node_detail -.->|"updates idea"| node_api_client
node_detail -->|"renders"| node_notes_ui
node_notes_ui -.->|"manages notes"| node_api_client
node_auth_ui -->|"signs in"| node_api_client
node_api_client -.->|"sends requests"| node_api_app
node_api_app -->|"registers"| node_auth_routes
node_api_app -->|"registers"| node_project_routes
node_api_app -->|"registers"| node_note_routes
node_api_app -->|"registers"| node_error_routes
node_auth_routes -->|"hashes and verifies"| node_auth_controls
node_auth_routes -->|"limits attempts"| node_rate_limit
node_auth_routes -->|"reads and writes users"| node_store
node_project_routes -->|"checks cap"| node_quota
node_note_routes -->|"checks cap"| node_quota
node_project_routes -->|"reads and writes projects"| node_store
node_note_routes -->|"reads and writes notes"| node_store
node_project_routes -->|"validates fields"| node_project_model
node_store -->|"persists records"| node_database
node_api_app -->|"initializes"| node_otel
node_otel -->|"exports telemetry"| node_grafana
node_error_routes -->|"limits reports"| node_rate_limit
node_user -.->|"uses deployed service"| node_lambda

click node_app "https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/App.tsx"
click node_auth_ui "https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/pages/login.tsx"
click node_dashboard "https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/pages/dashboard.tsx"
click node_capture "https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/components/quick-capture-dialog.tsx"
click node_detail "https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/pages/project-detail.tsx"
click node_notes_ui "https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/components/detail/notes-panel.tsx"
click node_api_client "https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/services/api/http.ts"
click node_auth_routes "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/routers/auth.py"
click node_project_routes "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/routers/projects.py"
click node_note_routes "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/routers/notes.py"
click node_error_routes "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/routers/errors.py"
click node_api_app "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/main.py"
click node_project_model "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/models/project.py"
click node_quota "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/core/quotas.py"
click node_auth_controls "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/auth/security.py"
click node_rate_limit "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/auth/rate_limit.py"
click node_store "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/db/store.py"
click node_database "https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/db/session.py"
click node_otel "https://github.com/rdanielsstat/hub-platform/blob/main/backend/observability/__init__.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_app,node_auth_ui,node_dashboard,node_capture,node_detail,node_notes_ui,node_api_client,node_user toneBlue
class node_auth_routes,node_project_routes,node_note_routes,node_error_routes,node_api_app,node_project_model toneAmber
class node_store,node_database toneMint
class node_quota,node_auth_controls,node_rate_limit toneRose
class node_otel,node_grafana,node_lambda toneIndigo
```

## Components

### Web application

- [App shell](https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/App.tsx): `frontend/src/App.tsx`
- [Sign-in screens](https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/pages/login.tsx): `frontend/src/pages/login.tsx`
- [Idea dashboard](https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/pages/dashboard.tsx): `frontend/src/pages/dashboard.tsx`
- [Quick capture](https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/components/quick-capture-dialog.tsx): `frontend/src/components/quick-capture-dialog.tsx`
- [Project details](https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/pages/project-detail.tsx): `frontend/src/pages/project-detail.tsx`
- [Notes panel](https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/components/detail/notes-panel.tsx): `frontend/src/components/detail/notes-panel.tsx`
- [API client](https://github.com/rdanielsstat/hub-platform/blob/main/frontend/src/services/api/http.ts): `frontend/src/services/api/http.ts`

### API and domain

- [Authentication API](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/routers/auth.py): `backend/app/routers/auth.py`
- [Project lifecycle API](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/routers/projects.py): `backend/app/routers/projects.py`
- [Notes API](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/routers/notes.py): `backend/app/routers/notes.py`
- [Client error API](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/routers/errors.py): `backend/app/routers/errors.py`
- [FastAPI application](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/main.py): `backend/app/main.py`
- [Project domain](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/models/project.py): `backend/app/models/project.py`

### Persistence

- [SQL data store](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/db/store.py): `backend/app/db/store.py`
- [SQLite / Postgres](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/db/session.py): `backend/app/db/session.py`

### Security controls

- [Usage caps](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/core/quotas.py): `backend/app/core/quotas.py`
- [Identity controls](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/auth/security.py): `backend/app/auth/security.py`
- [IP rate limits](https://github.com/rdanielsstat/hub-platform/blob/main/backend/app/auth/rate_limit.py): `backend/app/auth/rate_limit.py`

### Observability

- [Telemetry setup](https://github.com/rdanielsstat/hub-platform/blob/main/backend/observability/__init__.py): `backend/observability/__init__.py`
- **Grafana Cloud**
- **AWS Lambda**

### Other components

- **Personal user**

## Connections

- Personal user → App shell: uses (evidence: `README.md`)
- App shell → Sign-in screens: routes unauthenticated (evidence: `frontend/src/App.tsx`)
- App shell → Idea dashboard: routes signed-in (evidence: `frontend/src/App.tsx`)
- App shell → Project details: routes project (evidence: `frontend/src/App.tsx`)
- App shell → Quick capture: opens capture (evidence: `frontend/src/App.tsx`)
- Idea dashboard → API client: loads and filters
- Quick capture → API client: creates idea
- Project details → API client: updates idea
- Project details → Notes panel: renders (evidence: `frontend/src/pages/project-detail.tsx`)
- Notes panel → API client: manages notes
- Sign-in screens → API client: signs in
- API client → FastAPI application: sends requests
- FastAPI application → Authentication API: registers (evidence: `backend/app/main.py`)
- FastAPI application → Project lifecycle API: registers (evidence: `backend/app/main.py`)
- FastAPI application → Notes API: registers (evidence: `backend/app/main.py`)
- FastAPI application → Client error API: registers (evidence: `backend/app/main.py`)
- Authentication API → Identity controls: hashes and verifies (evidence: `backend/app/routers/auth.py`)
- Authentication API → IP rate limits: limits attempts (evidence: `backend/app/routers/auth.py`)
- Authentication API → SQL data store: reads and writes users (evidence: `backend/app/routers/auth.py`)
- Project lifecycle API → Usage caps: checks cap (evidence: `backend/app/core/quotas.py`)
- Notes API → Usage caps: checks cap (evidence: `backend/app/core/quotas.py`)
- Project lifecycle API → SQL data store: reads and writes projects (evidence: `backend/app/routers/projects.py`)
- Notes API → SQL data store: reads and writes notes (evidence: `backend/app/routers/notes.py`)
- Project lifecycle API → Project domain: validates fields (evidence: `backend/app/routers/projects.py`)
- SQL data store → SQLite / Postgres: persists records (evidence: `backend/app/db/store.py`)
- FastAPI application → Telemetry setup: initializes (evidence: `backend/app/main.py`)
- Telemetry setup → Grafana Cloud: exports telemetry (evidence: `backend/observability/__init__.py`)
- Client error API → IP rate limits: limits reports (evidence: `backend/app/routers/errors.py`)
- Personal user → AWS Lambda: uses deployed service (evidence: `README.md`)
