# tokenmanizo/flowscope architecture

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

- Interactive diagram: https://gitdiagram.com/tokenmanizo/flowscope
- Repository: https://github.com/tokenmanizo/flowscope

## Overview

FlowScope is a Burp Suite extension for collecting human, scanner, and LLM traffic, comparing API coverage, and investigating cross-account authorization. Its central workflow is to scope a project, collect request/response observations, analyze them into coverage and authorization graphs, and inspect evidence or replay safe requests with another identity. The README also documents account/session management, a permissions matrix, ZAP and Codex exploration, and local project saving. Some subsystem links are documented capabilities rather than inspected call paths; those edges are marked dashed where source wiring was not shown.

Main entry points: [`frontend/src/lib/api/client.ts`](https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/lib/api/client.ts) (API client), [`src/main/java/io/flowscope/web/FlowScopeWebServer.java`](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/web/FlowScopeWebServer.java) (Loopback web server), [`src/main/java/io/flowscope/burp/FlowScopeExtension.java`](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/burp/FlowScopeExtension.java) (Burp extension), [`src/main/java/io/flowscope/core/Pipeline.java`](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/Pipeline.java) (Coverage analysis)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_capture["Traffic capture"]
  node_extension["Burp extension"]
  node_human_sessions["Human sessions"]
end

subgraph group_analysis["Analysis"]
  node_observations["Request observations<br/>[RequestRecord.java]"]
  node_run_context["Run context"]
  node_config["Analysis and account policy"]
  node_route_discovery["Client route discovery"]
  node_pipeline["Coverage analysis<br/>[Pipeline.java]"]
  node_flow_graph["Authorization graph"]
end

subgraph group_replay["Identity replay"]
  node_session_broker["Session broker<br/>[SessionBroker.java]"]
  node_cross_replay["Cross-identity replay"]
end

subgraph group_service["Web service and storage"]
  node_web_server["Loopback web server"]
  node_project_store[("Project storage")]
end

subgraph group_frontend["Web interface"]
  node_app["Web application<br/>[App.tsx]"]
  node_api_client["API client<br/>[client.ts]"]
  node_graph_view["Coverage graph view<br/>[GraphPage.tsx]"]
  node_matrix_view["Authorization matrix<br/>[MatrixPage.tsx]"]
  node_evidence_view["Evidence review<br/>[EvidencePage.tsx]"]
  node_inspection_view["Inspection workspace<br/>[InspectionPage.tsx]"]
  node_accounts_view["Account management<br/>[AccountsPage.tsx]"]
end

node_burp(("Burp Suite"))
node_human(("Human tester"))
node_zap(("ZAP scanner"))
node_codex(("Codex explorer"))
node_target(("Target application"))

node_burp -->|"hosts extension"| node_extension
node_human -.->|"sends traffic"| node_extension
node_zap -->|"proxies traffic"| node_extension
node_codex -.->|"explores APIs"| node_extension
node_extension -.->|"records traffic"| node_observations
node_human -.->|"captures sessions"| node_human_sessions
node_human_sessions -->|"uses run context"| node_run_context
node_observations -->|"analyzes records"| node_pipeline
node_config -->|"configures analysis"| node_pipeline
node_pipeline -->|"builds graph"| node_flow_graph
node_observations -->|"seeds routes"| node_route_discovery
node_cross_replay -->|"gets credentials"| node_session_broker
node_cross_replay -->|"replays requests"| node_target
node_burp -->|"opens local UI"| node_web_server
node_web_server -->|"runs analysis"| node_pipeline
node_web_server -->|"coordinates replay"| node_cross_replay
node_web_server -.->|"persists projects"| node_project_store
node_app -.->|"uses API"| node_api_client
node_app -->|"loads web UI"| node_web_server
node_api_client -.->|"requests data"| node_web_server
node_graph_view -.->|"loads graph data"| node_api_client
node_matrix_view -.->|"loads matrix data"| node_api_client
node_evidence_view -.->|"loads evidence"| node_api_client
node_inspection_view -.->|"controls inspection"| node_api_client
node_accounts_view -.->|"manages accounts"| node_api_client

click node_extension "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/burp/FlowScopeExtension.java"
click node_human_sessions "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/burp/HumanBrowserSessions.java"
click node_observations "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/RequestRecord.java"
click node_run_context "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/RunContextRegistry.java"
click node_config "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/AnalysisConfig.java"
click node_route_discovery "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/ClientRouteSeeds.java"
click node_pipeline "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/Pipeline.java"
click node_flow_graph "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/graph/FlowGraphBuilder.java"
click node_session_broker "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/integration/SessionBroker.java"
click node_cross_replay "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/integration/CrossIdentityReplayOrchestrator.java"
click node_web_server "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/web/FlowScopeWebServer.java"
click node_project_store "https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/integration/SqliteProjectStore.java"
click node_app "https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/app/App.tsx"
click node_api_client "https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/lib/api/client.ts"
click node_graph_view "https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/graph/GraphPage.tsx"
click node_matrix_view "https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/matrix/MatrixPage.tsx"
click node_evidence_view "https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/evidence/EvidencePage.tsx"
click node_inspection_view "https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/inspection/InspectionPage.tsx"
click node_accounts_view "https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/accounts/AccountsPage.tsx"

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_extension,node_human_sessions toneBlue
class node_observations,node_run_context,node_config,node_route_discovery,node_pipeline,node_flow_graph toneAmber
class node_session_broker,node_cross_replay toneMint
class node_web_server,node_project_store toneRose
class node_app,node_api_client,node_graph_view,node_matrix_view,node_evidence_view,node_inspection_view,node_accounts_view,node_burp,node_human,node_zap,node_codex,node_target toneIndigo
```

## Components

### Traffic capture

- [Burp extension](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/burp/FlowScopeExtension.java): `src/main/java/io/flowscope/burp/FlowScopeExtension.java`
- [Human sessions](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/burp/HumanBrowserSessions.java): `src/main/java/io/flowscope/burp/HumanBrowserSessions.java`

### Analysis

- [Request observations](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/RequestRecord.java): `src/main/java/io/flowscope/core/RequestRecord.java`
- [Run context](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/RunContextRegistry.java): `src/main/java/io/flowscope/core/RunContextRegistry.java`
- [Analysis and account policy](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/AnalysisConfig.java): `src/main/java/io/flowscope/core/AnalysisConfig.java`
- [Client route discovery](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/ClientRouteSeeds.java): `src/main/java/io/flowscope/core/ClientRouteSeeds.java`
- [Coverage analysis](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/Pipeline.java): `src/main/java/io/flowscope/core/Pipeline.java`
- [Authorization graph](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/core/graph/FlowGraphBuilder.java): `src/main/java/io/flowscope/core/graph/FlowGraphBuilder.java`

### Identity replay

- [Session broker](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/integration/SessionBroker.java): `src/main/java/io/flowscope/integration/SessionBroker.java`
- [Cross-identity replay](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/integration/CrossIdentityReplayOrchestrator.java): `src/main/java/io/flowscope/integration/CrossIdentityReplayOrchestrator.java`

### Web service and storage

- [Loopback web server](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/web/FlowScopeWebServer.java): `src/main/java/io/flowscope/web/FlowScopeWebServer.java`
- [Project storage](https://github.com/tokenmanizo/flowscope/blob/main/src/main/java/io/flowscope/integration/SqliteProjectStore.java): `src/main/java/io/flowscope/integration/SqliteProjectStore.java`

### Web interface

- [Web application](https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/app/App.tsx): `frontend/src/app/App.tsx`
- [API client](https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/lib/api/client.ts): `frontend/src/lib/api/client.ts`
- [Coverage graph view](https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/graph/GraphPage.tsx): `frontend/src/features/graph/GraphPage.tsx`
- [Authorization matrix](https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/matrix/MatrixPage.tsx): `frontend/src/features/matrix/MatrixPage.tsx`
- [Evidence review](https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/evidence/EvidencePage.tsx): `frontend/src/features/evidence/EvidencePage.tsx`
- [Inspection workspace](https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/inspection/InspectionPage.tsx): `frontend/src/features/inspection/InspectionPage.tsx`
- [Account management](https://github.com/tokenmanizo/flowscope/blob/main/frontend/src/features/accounts/AccountsPage.tsx): `frontend/src/features/accounts/AccountsPage.tsx`

### Other components

- **Burp Suite**
- **Human tester**
- **ZAP scanner**
- **Codex explorer**
- **Target application**

## Connections

- Burp Suite → Burp extension: hosts extension
- Human tester → Burp extension: sends traffic
- ZAP scanner → Burp extension: proxies traffic
- Codex explorer → Burp extension: explores APIs
- Burp extension → Request observations: records traffic
- Human tester → Human sessions: captures sessions
- Human sessions → Run context: uses run context (evidence: `src/main/java/io/flowscope/burp/HumanBrowserSessions.java`)
- Request observations → Coverage analysis: analyzes records (evidence: `src/main/java/io/flowscope/core/Pipeline.java`)
- Analysis and account policy → Coverage analysis: configures analysis (evidence: `src/main/java/io/flowscope/core/Pipeline.java`)
- Coverage analysis → Authorization graph: builds graph (evidence: `src/main/java/io/flowscope/core/Pipeline.java`)
- Request observations → Client route discovery: seeds routes (evidence: `src/main/java/io/flowscope/core/ClientRouteSeeds.java`)
- Cross-identity replay → Session broker: gets credentials (evidence: `src/main/java/io/flowscope/integration/CrossIdentityReplayOrchestrator.java`)
- Cross-identity replay → Target application: replays requests
- Burp Suite → Loopback web server: opens local UI
- Loopback web server → Coverage analysis: runs analysis (evidence: `src/main/java/io/flowscope/web/FlowScopeWebServer.java`)
- Loopback web server → Cross-identity replay: coordinates replay (evidence: `src/main/java/io/flowscope/web/FlowScopeWebServer.java`)
- Loopback web server → Project storage: persists projects
- Web application → API client: uses API
- Web application → Loopback web server: loads web UI
- API client → Loopback web server: requests data
- Coverage graph view → API client: loads graph data
- Authorization matrix → API client: loads matrix data
- Evidence review → API client: loads evidence
- Inspection workspace → API client: controls inspection
- Account management → API client: manages accounts
