# sanskritisonee/wexa-blastradius architecture

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

- Interactive diagram: https://gitdiagram.com/sanskritisonee/wexa-blastradius
- Repository: https://github.com/sanskritisonee/wexa-blastradius

## Overview

BlastRadius is a supply-chain vulnerability impact explorer. An engineer selects a CVE; the frontend fetches its blast radius, and the API queries CognoDB for shortest dependency paths from affected services to the vulnerable package. The app presents those paths as a hop-distance radar and summarizes affected services and teams. Separate views rank packages by reachable services and roll up team exposure; the API also supports explicit service-to-package path tracing. The seed loader supplies demo graph data. Evidence covers the sampled runtime files and README; the neighborhood query is documented but not routed by the sampled API.

Main entry points: [`frontend/src/App.jsx`](https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/App.jsx) (BlastRadius app), [`backend/src/db/driver.js`](https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/db/driver.js) (Database driver), [`backend/src/index.js`](https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/index.js) (API server), [`backend/src/routes/graph.js`](https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/routes/graph.js) (Graph endpoints)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Impact explorer"]
  node_app["BlastRadius app<br/>[App.jsx]"]
  node_api_client["API client<br/>[api.js]"]
  node_cve_list["CVE queue<br/>[CveList.jsx]"]
  node_radar["Blast-radius radar<br/>[RadarGraph.jsx]"]
  node_details["Impact details<br/>[DetailsPanel.jsx]"]
  node_package_rank["Package ranking"]
  node_team_rollup["Team exposure<br/>[TeamExposure.jsx]"]
end

subgraph group_api["REST API"]
  node_api_server["API server<br/>[index.js]"]
  node_graph_routes["Graph endpoints<br/>[graph.js]"]
end

subgraph group_graphdata["Graph data"]
  node_cypher["Cypher queries<br/>[cypher.js]"]
  node_driver["Database driver<br/>[driver.js]"]
end

subgraph group_seed["Demo dataset"]
  node_seed_loader["Seed loader<br/>[seed.js]"]
  node_seed_data["Graph seed data<br/>[data.js]"]
end

node_engineer(("Engineer"))
node_cognodb[("CognoDB Cloud")]

node_engineer -->|"uses"| node_app
node_app -->|"requests data"| node_api_client
node_app -->|"renders"| node_cve_list
node_app -->|"renders results"| node_radar
node_app -->|"renders results"| node_details
node_app -->|"renders ranking"| node_package_rank
node_app -->|"renders rollup"| node_team_rollup
node_api_client -->|"HTTP requests"| node_api_server
node_api_server -->|"mounts routes"| node_graph_routes
node_api_server -->|"checks connectivity"| node_driver
node_graph_routes -->|"runs queries"| node_cypher
node_graph_routes -->|"executes queries"| node_driver
node_driver -->|"reads and writes"| node_cognodb
node_seed_loader -->|"loads records"| node_seed_data
node_seed_loader -->|"writes graph"| node_driver
node_radar -->|"renders supplied data"| node_app
node_details -->|"summarizes supplied data"| node_app
node_package_rank -->|"displays supplied ranking"| node_app
node_team_rollup -->|"displays supplied rollup"| node_app

click node_app "https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/App.jsx"
click node_api_client "https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/api.js"
click node_cve_list "https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/CveList.jsx"
click node_radar "https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/RadarGraph.jsx"
click node_details "https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/DetailsPanel.jsx"
click node_package_rank "https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/RiskiestPackages.jsx"
click node_team_rollup "https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/TeamExposure.jsx"
click node_api_server "https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/index.js"
click node_graph_routes "https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/routes/graph.js"
click node_cypher "https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/queries/cypher.js"
click node_driver "https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/db/driver.js"
click node_seed_loader "https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/seed/seed.js"
click node_seed_data "https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/seed/data.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_api_client,node_cve_list,node_radar,node_details,node_package_rank,node_team_rollup toneBlue
class node_api_server,node_graph_routes,node_cognodb toneAmber
class node_cypher,node_driver toneMint
class node_seed_loader,node_seed_data toneRose
class node_engineer toneIndigo
```

## Components

### Impact explorer

- [BlastRadius app](https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/App.jsx): `frontend/src/App.jsx`
- [API client](https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/api.js): `frontend/src/api.js`
- [CVE queue](https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/CveList.jsx): `frontend/src/components/CveList.jsx`
- [Blast-radius radar](https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/RadarGraph.jsx): `frontend/src/components/RadarGraph.jsx`
- [Impact details](https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/DetailsPanel.jsx): `frontend/src/components/DetailsPanel.jsx`
- [Package ranking](https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/RiskiestPackages.jsx): `frontend/src/components/RiskiestPackages.jsx`
- [Team exposure](https://github.com/sanskritisonee/wexa-blastradius/blob/main/frontend/src/components/TeamExposure.jsx): `frontend/src/components/TeamExposure.jsx`

### REST API

- [API server](https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/index.js): `backend/src/index.js`
- [Graph endpoints](https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/routes/graph.js): `backend/src/routes/graph.js`

### Graph data

- [Cypher queries](https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/queries/cypher.js): `backend/src/queries/cypher.js`
- [Database driver](https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/db/driver.js): `backend/src/db/driver.js`

### Demo dataset

- [Seed loader](https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/seed/seed.js): `backend/src/seed/seed.js`
- [Graph seed data](https://github.com/sanskritisonee/wexa-blastradius/blob/main/backend/src/seed/data.js): `backend/src/seed/data.js`

### Other components

- **Engineer**
- **CognoDB Cloud**

## Connections

- Engineer → BlastRadius app: uses (evidence: `README.md`)
- BlastRadius app → API client: requests data (evidence: `frontend/src/App.jsx`)
- BlastRadius app → CVE queue: renders (evidence: `frontend/src/App.jsx`)
- BlastRadius app → Blast-radius radar: renders results (evidence: `frontend/src/App.jsx`)
- BlastRadius app → Impact details: renders results (evidence: `frontend/src/App.jsx`)
- BlastRadius app → Package ranking: renders ranking (evidence: `frontend/src/App.jsx`)
- BlastRadius app → Team exposure: renders rollup (evidence: `frontend/src/App.jsx`)
- API client → API server: HTTP requests (evidence: `README.md`)
- API server → Graph endpoints: mounts routes (evidence: `backend/src/index.js`)
- API server → Database driver: checks connectivity (evidence: `backend/src/index.js`)
- Graph endpoints → Cypher queries: runs queries (evidence: `backend/src/routes/graph.js`)
- Graph endpoints → Database driver: executes queries (evidence: `backend/src/routes/graph.js`)
- Database driver → CognoDB Cloud: reads and writes (evidence: `backend/src/db/driver.js`)
- Seed loader → Graph seed data: loads records (evidence: `backend/src/seed/seed.js`)
- Seed loader → Database driver: writes graph (evidence: `backend/src/seed/seed.js`)
- Blast-radius radar → BlastRadius app: renders supplied data (evidence: `frontend/src/App.jsx`)
- Impact details → BlastRadius app: summarizes supplied data (evidence: `frontend/src/App.jsx`)
- Package ranking → BlastRadius app: displays supplied ranking (evidence: `frontend/src/App.jsx`)
- Team exposure → BlastRadius app: displays supplied rollup (evidence: `frontend/src/App.jsx`)
