# joao-henrike/nova architecture

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

- Interactive diagram: https://gitdiagram.com/joao-henrike/nova
- Repository: https://github.com/joao-henrike/nova

## Overview

NOVA/CloudStart is an AWS-hosted web application and infrastructure project. The visible runtime workflow is browser use of the frontend, FastAPI routing, OAuth-backed authentication or item operations, and PostgreSQL persistence. The README also documents cloud operations and monitoring; the tree exposes FinOps, monitoring, and resilience code, but not the Terraform and deployment modules described there. The graph therefore maps only evidenced source paths and uses the README for documented product-level relationships; unsampled implementation details are omitted.

Main entry points: [`apps/frontend/public/app.js`](https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/app.js) (Browser frontend), [`apps/backend/app/api/routes/auth.py`](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/api/routes/auth.py) (Authentication routes), [`apps/backend/app/main.py`](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/main.py) (FastAPI application), [`apps/backend/app/api/routes/items.py`](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/api/routes/items.py) (Item routes)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Web application"]
  node_frontend["Browser frontend<br/>[app.js]"]
  node_store["Store workflow<br/>[store.js]"]
  node_checkout["Checkout flow<br/>[checkout.js]"]
  node_quote["Quote flow<br/>[quote.js]"]
  node_confirmation["Confirmation view<br/>[confirmation.js]"]
  node_api_status["API status<br/>[api-status.js]"]
end

subgraph group_backend["Backend API"]
  node_backend_entry["FastAPI application<br/>[main.py]"]
  node_auth_routes["Authentication routes<br/>[auth.py]"]
  node_item_routes["Item routes<br/>[items.py]"]
  node_health_routes["Health routes<br/>[health.py]"]
  node_auth_service["Authentication service<br/>[auth.py]"]
  node_providers["OAuth providers<br/>[providers.py]"]
  node_security["Token security<br/>[security.py]"]
  node_auth_repository["Auth repository<br/>[auth.py]"]
  node_rate_limit["Auth rate limits<br/>[rate_limit.py]"]
  node_items_service["Items service<br/>[items.py]"]
  node_items_repository["Items repository<br/>[items.py]"]
  node_item_schema["Item schemas<br/>[item.py]"]
end

subgraph group_ops["Operations and insight"]
  node_finops["FinOps commands<br/>[finops.py]"]
  node_pricing["Cost pricing<br/>[pricing.py]"]
  node_monitoring["Monitoring bootstrap<br/>[bootstrap.py]"]
  node_resilience["Resilience runner<br/>[run.py]"]
end

node_visitor(("Web user"))
node_database[("PostgreSQL")]
node_oauth_services["Google and Apple"]

node_visitor -->|"uses"| node_frontend
node_frontend -.->|"calls API"| node_backend_entry
node_frontend -.->|"uses"| node_store
node_frontend -.->|"uses"| node_checkout
node_frontend -.->|"uses"| node_quote
node_frontend -.->|"uses"| node_confirmation
node_frontend -.->|"uses"| node_api_status
node_backend_entry -->|"registers"| node_auth_routes
node_backend_entry -->|"registers"| node_item_routes
node_backend_entry -->|"registers"| node_health_routes
node_auth_routes -->|"calls"| node_auth_service
node_auth_routes -->|"enforces"| node_rate_limit
node_auth_routes -->|"calls"| node_providers
node_auth_service -->|"calls"| node_auth_repository
node_auth_service -->|"creates tokens"| node_security
node_auth_routes -.->|"redirects to"| node_oauth_services
node_auth_routes -.->|"reads/writes"| node_database
node_item_routes -->|"calls"| node_items_service
node_items_service -->|"calls"| node_items_repository
node_item_routes -->|"validates"| node_item_schema
node_items_repository -.->|"reads/writes"| node_database
node_health_routes -.->|"checks"| node_database
node_finops -->|"uses"| node_pricing
node_monitoring -.->|"configures"| node_database
node_resilience -.->|"operates"| node_database

click node_frontend "https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/app.js"
click node_store "https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/store.js"
click node_checkout "https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/checkout.js"
click node_quote "https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/quote.js"
click node_confirmation "https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/confirmation.js"
click node_api_status "https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/api-status.js"
click node_backend_entry "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/main.py"
click node_auth_routes "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/api/routes/auth.py"
click node_item_routes "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/api/routes/items.py"
click node_health_routes "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/api/routes/health.py"
click node_auth_service "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/services/auth.py"
click node_providers "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/services/providers.py"
click node_security "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/core/security.py"
click node_auth_repository "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/repositories/auth.py"
click node_rate_limit "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/services/rate_limit.py"
click node_items_service "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/services/items.py"
click node_items_repository "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/repositories/items.py"
click node_item_schema "https://github.com/joao-henrike/nova/blob/main/apps/backend/app/schemas/item.py"
click node_finops "https://github.com/joao-henrike/nova/blob/main/finops/finops.py"
click node_pricing "https://github.com/joao-henrike/nova/blob/main/finops/pricing.py"
click node_monitoring "https://github.com/joao-henrike/nova/blob/main/monitoring/bootstrap.py"
click node_resilience "https://github.com/joao-henrike/nova/blob/main/resilience/run.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_frontend,node_store,node_checkout,node_quote,node_confirmation,node_api_status,node_visitor toneBlue
class node_backend_entry,node_auth_routes,node_item_routes,node_health_routes,node_auth_service,node_providers,node_security,node_auth_repository,node_rate_limit,node_items_service,node_items_repository,node_item_schema,node_database toneAmber
class node_finops,node_pricing,node_monitoring,node_resilience toneMint
class node_oauth_services toneIndigo
```

## Components

### Web application

- [Browser frontend](https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/app.js): `apps/frontend/public/app.js`
- [Store workflow](https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/store.js): `apps/frontend/public/store.js`
- [Checkout flow](https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/checkout.js): `apps/frontend/public/checkout.js`
- [Quote flow](https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/quote.js): `apps/frontend/public/quote.js`
- [Confirmation view](https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/confirmation.js): `apps/frontend/public/confirmation.js`
- [API status](https://github.com/joao-henrike/nova/blob/main/apps/frontend/public/api-status.js): `apps/frontend/public/api-status.js`

### Backend API

- [FastAPI application](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/main.py): `apps/backend/app/main.py`
- [Authentication routes](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/api/routes/auth.py): `apps/backend/app/api/routes/auth.py`
- [Item routes](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/api/routes/items.py): `apps/backend/app/api/routes/items.py`
- [Health routes](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/api/routes/health.py): `apps/backend/app/api/routes/health.py`
- [Authentication service](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/services/auth.py): `apps/backend/app/services/auth.py`
- [OAuth providers](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/services/providers.py): `apps/backend/app/services/providers.py`
- [Token security](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/core/security.py): `apps/backend/app/core/security.py`
- [Auth repository](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/repositories/auth.py): `apps/backend/app/repositories/auth.py`
- [Auth rate limits](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/services/rate_limit.py): `apps/backend/app/services/rate_limit.py`
- [Items service](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/services/items.py): `apps/backend/app/services/items.py`
- [Items repository](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/repositories/items.py): `apps/backend/app/repositories/items.py`
- [Item schemas](https://github.com/joao-henrike/nova/blob/main/apps/backend/app/schemas/item.py): `apps/backend/app/schemas/item.py`

### Operations and insight

- [FinOps commands](https://github.com/joao-henrike/nova/blob/main/finops/finops.py): `finops/finops.py`
- [Cost pricing](https://github.com/joao-henrike/nova/blob/main/finops/pricing.py): `finops/pricing.py`
- [Monitoring bootstrap](https://github.com/joao-henrike/nova/blob/main/monitoring/bootstrap.py): `monitoring/bootstrap.py`
- [Resilience runner](https://github.com/joao-henrike/nova/blob/main/resilience/run.py): `resilience/run.py`

### Other components

- **Web user**
- **PostgreSQL**
- **Google and Apple**

## Connections

- Web user → Browser frontend: uses
- Browser frontend → FastAPI application: calls API
- Browser frontend → Store workflow: uses
- Browser frontend → Checkout flow: uses
- Browser frontend → Quote flow: uses
- Browser frontend → Confirmation view: uses
- Browser frontend → API status: uses
- FastAPI application → Authentication routes: registers (evidence: `apps/backend/app/main.py`)
- FastAPI application → Item routes: registers (evidence: `apps/backend/app/main.py`)
- FastAPI application → Health routes: registers (evidence: `apps/backend/app/main.py`)
- Authentication routes → Authentication service: calls (evidence: `apps/backend/app/api/routes/auth.py`)
- Authentication routes → Auth rate limits: enforces (evidence: `apps/backend/app/api/routes/auth.py`)
- Authentication routes → OAuth providers: calls (evidence: `apps/backend/app/api/routes/auth.py`)
- Authentication service → Auth repository: calls (evidence: `apps/backend/app/services/auth.py`)
- Authentication service → Token security: creates tokens (evidence: `apps/backend/app/services/auth.py`)
- Authentication routes → Google and Apple: redirects to (evidence: `apps/backend/app/api/routes/auth.py`)
- Authentication routes → PostgreSQL: reads/writes (evidence: `apps/backend/app/api/routes/auth.py`)
- Item routes → Items service: calls (evidence: `apps/backend/app/api/routes/items.py`)
- Items service → Items repository: calls (evidence: `apps/backend/app/services/items.py`)
- Item routes → Item schemas: validates (evidence: `apps/backend/app/api/routes/items.py`)
- Items repository → PostgreSQL: reads/writes
- Health routes → PostgreSQL: checks (evidence: `apps/backend/app/api/routes/health.py`)
- FinOps commands → Cost pricing: uses (evidence: `finops/finops.py`)
- Monitoring bootstrap → PostgreSQL: configures
- Resilience runner → PostgreSQL: operates
