# yvanol-fotso/izilens architecture

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

- Interactive diagram: https://gitdiagram.com/yvanol-fotso/izilens
- Repository: https://github.com/yvanol-fotso/izilens

## Overview

IZILens is an identity-verification platform with a Python/FastAPI backend and a web dashboard. A typical workflow is an organization user or API integration authenticating, creating a KYC case, submitting identity documents, and receiving a reviewable result; hosted journeys are also supported. The product additionally covers KYB, biometrics, OCR, billing, audit, and webhooks. The README documents these capabilities, but many implementations were not sampled, so links to those branches are shown as unverified rather than asserted as observed calls.

Main entry points: [`backend/app/modules/kyc/routes.py`](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/routes.py) (KYC case API), [`backend/app/modules/kyc/service.py`](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/service.py) (KYC processing), [`backend/app/modules/backoffice/routes.py`](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/backoffice/routes.py) (Compliance review), [`backend/app/api/v1/endpoints.py`](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/api/v1/endpoints.py) (FastAPI endpoints)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_access["Access and platform"]
  node_api["FastAPI endpoints<br/>[endpoints.py]"]
  node_auth["Authentication<br/>[routes.py]"]
  node_access_control["Access control<br/>[dependencies.py]"]
  node_principal["Request identity<br/>[principal.py]"]
end

subgraph group_verification["Verification"]
  node_kyc_routes["KYC case API<br/>[routes.py]"]
  node_kyc_journeys["KYC journeys<br/>[journeys.py]"]
  node_kyc_service["KYC processing<br/>[service.py]"]
  node_kyc_repository[("KYC persistence<br/>[repository.py]")]
  node_ocr["OCR engine<br/>[engine.py]"]
  node_kyb["Business verification"]
  node_biometrics["Biometric checks"]
end

subgraph group_operations["Operations"]
  node_backoffice["Compliance review<br/>[routes.py]"]
  node_billing["Billing<br/>[service.py]"]
  node_audit["Audit trail<br/>[service.py]"]
  node_webhooks["Webhook delivery<br/>[service.py]"]
  node_database[("Application database<br/>[database.py]")]
end

subgraph group_dashboard["Web dashboard"]
  node_dashboard["Customer dashboard"]
  node_review_ui["Verification review UI"]
end

node_client(("Organization user"))
node_integration(("API integration"))

node_client -.->|"uses"| node_dashboard
node_dashboard -.->|"requests"| node_api
node_integration -.->|"submits requests"| node_api
node_api -.->|"routes auth"| node_auth
node_kyc_routes -->|"requires access"| node_access_control
node_access_control -->|"builds identity"| node_principal
node_kyc_routes -->|"manages journeys"| node_kyc_journeys
node_kyc_routes -->|"lists cases"| node_kyc_repository
node_kyc_routes -->|"loads case"| node_kyc_service
node_kyc_service -.->|"persists cases"| node_kyc_repository
node_kyc_service -.->|"extracts text"| node_ocr
node_kyc_routes -.->|"accepts checks"| node_biometrics
node_client -.->|"requests verification"| node_kyb
node_backoffice -->|"decides cases"| node_kyc_service
node_backoffice -->|"lists cases"| node_kyc_repository
node_backoffice -.->|"notifies"| node_webhooks
node_kyc_service -.->|"records usage"| node_billing
node_billing -->|"records changes"| node_audit
node_webhooks -->|"stores deliveries"| node_database
node_kyc_routes -->|"uses sessions"| node_database
node_review_ui -.->|"renders within"| node_dashboard

click node_api "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/api/v1/endpoints.py"
click node_auth "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/auth/routes.py"
click node_access_control "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/core/dependencies.py"
click node_principal "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/core/principal.py"
click node_kyc_routes "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/routes.py"
click node_kyc_journeys "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/journeys.py"
click node_kyc_service "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/service.py"
click node_kyc_repository "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/repository.py"
click node_ocr "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/shared/ocr/engine.py"
click node_kyb "https://github.com/yvanol-fotso/izilens/tree/main/backend/app/modules/kyb"
click node_biometrics "https://github.com/yvanol-fotso/izilens/tree/main/backend/app/modules/biometrics"
click node_backoffice "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/backoffice/routes.py"
click node_billing "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/billing/service.py"
click node_audit "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/audit/service.py"
click node_webhooks "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/webhooks/service.py"
click node_database "https://github.com/yvanol-fotso/izilens/blob/main/backend/app/core/database.py"
click node_dashboard "https://github.com/yvanol-fotso/izilens/tree/main/dashboard/src/routes/app"
click node_review_ui "https://github.com/yvanol-fotso/izilens/tree/main/dashboard/src/lib/components/verifications"

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_api,node_auth,node_access_control,node_principal,node_client toneBlue
class node_kyc_routes,node_kyc_journeys,node_kyc_service,node_kyc_repository,node_ocr,node_kyb,node_biometrics toneAmber
class node_backoffice,node_billing,node_audit,node_webhooks,node_database,node_integration toneMint
class node_dashboard,node_review_ui toneRose
```

## Components

### Access and platform

- [FastAPI endpoints](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/api/v1/endpoints.py): `backend/app/api/v1/endpoints.py`
- [Authentication](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/auth/routes.py): `backend/app/modules/auth/routes.py`
- [Access control](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/core/dependencies.py): `backend/app/core/dependencies.py`
- [Request identity](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/core/principal.py): `backend/app/core/principal.py`

### Verification

- [KYC case API](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/routes.py): `backend/app/modules/kyc/routes.py`
- [KYC journeys](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/journeys.py): `backend/app/modules/kyc/journeys.py`
- [KYC processing](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/service.py): `backend/app/modules/kyc/service.py`
- [KYC persistence](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/kyc/repository.py): `backend/app/modules/kyc/repository.py`
- [OCR engine](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/shared/ocr/engine.py): `backend/app/shared/ocr/engine.py`
- [Business verification](https://github.com/yvanol-fotso/izilens/tree/main/backend/app/modules/kyb): `backend/app/modules/kyb`
- [Biometric checks](https://github.com/yvanol-fotso/izilens/tree/main/backend/app/modules/biometrics): `backend/app/modules/biometrics`

### Operations

- [Compliance review](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/backoffice/routes.py): `backend/app/modules/backoffice/routes.py`
- [Billing](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/billing/service.py): `backend/app/modules/billing/service.py`
- [Audit trail](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/audit/service.py): `backend/app/modules/audit/service.py`
- [Webhook delivery](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/modules/webhooks/service.py): `backend/app/modules/webhooks/service.py`
- [Application database](https://github.com/yvanol-fotso/izilens/blob/main/backend/app/core/database.py): `backend/app/core/database.py`

### Web dashboard

- [Customer dashboard](https://github.com/yvanol-fotso/izilens/tree/main/dashboard/src/routes/app): `dashboard/src/routes/app`
- [Verification review UI](https://github.com/yvanol-fotso/izilens/tree/main/dashboard/src/lib/components/verifications): `dashboard/src/lib/components/verifications`

### Other components

- **Organization user**
- **API integration**

## Connections

- Organization user → Customer dashboard: uses
- Customer dashboard → FastAPI endpoints: requests
- API integration → FastAPI endpoints: submits requests
- FastAPI endpoints → Authentication: routes auth
- KYC case API → Access control: requires access (evidence: `backend/app/modules/kyc/routes.py`)
- Access control → Request identity: builds identity (evidence: `backend/app/core/dependencies.py`)
- KYC case API → KYC journeys: manages journeys (evidence: `backend/app/modules/kyc/routes.py`)
- KYC case API → KYC persistence: lists cases (evidence: `backend/app/modules/kyc/routes.py`)
- KYC case API → KYC processing: loads case (evidence: `backend/app/modules/kyc/routes.py`)
- KYC processing → KYC persistence: persists cases (evidence: `backend/app/modules/kyc/service.py`)
- KYC processing → OCR engine: extracts text (evidence: `backend/app/modules/kyc/service.py`)
- KYC case API → Biometric checks: accepts checks
- Organization user → Business verification: requests verification
- Compliance review → KYC processing: decides cases (evidence: `backend/app/modules/backoffice/routes.py`)
- Compliance review → KYC persistence: lists cases (evidence: `backend/app/modules/backoffice/routes.py`)
- Compliance review → Webhook delivery: notifies (evidence: `backend/app/modules/backoffice/routes.py`)
- KYC processing → Billing: records usage (evidence: `backend/app/modules/kyc/service.py`)
- Billing → Audit trail: records changes (evidence: `backend/app/modules/billing/service.py`)
- Webhook delivery → Application database: stores deliveries (evidence: `backend/app/modules/webhooks/service.py`)
- KYC case API → Application database: uses sessions (evidence: `backend/app/modules/kyc/routes.py`)
- Verification review UI → Customer dashboard: renders within
