# floberrot/ziggytheque architecture

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

- Interactive diagram: https://gitdiagram.com/floberrot/ziggytheque
- Repository: https://github.com/floberrot/ziggytheque

## Overview

ZiggyTheque is a manga-library and collection-management application. The main user workflow is to search or scan a manga, add its series and volumes, then track ownership, reading, wishlist and prices; users can also browse analytics and notifications. The Vue client calls a Symfony API organized into bounded contexts and CQRS command/query handling, with PostgreSQL-backed domain data and catalogue integrations. The graph combines README-documented capabilities with relationships visible in the supplied excerpts and source index; unsampled handler and persistence wiring is not asserted.

Main entry points: [`back/src/Collection/Infrastructure/Http/CatalogueController.php`](https://github.com/floberrot/ziggytheque/blob/main/back/src/Collection/Infrastructure/Http/CatalogueController.php) (Catalogue API), [`back/src/Manga/Application`](https://github.com/floberrot/ziggytheque/tree/main/back/src/Manga/Application) (Manga operations), [`back/src/Collection/Application`](https://github.com/floberrot/ziggytheque/tree/main/back/src/Collection/Application) (Collection operations), [`front/src/api/client.ts`](https://github.com/floberrot/ziggytheque/blob/main/front/src/api/client.ts) (API client)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["Web client"]
  node_vue["Vue application<br/>[App.vue]"]
  node_pages["Library pages"]
  node_api["API client<br/>[client.ts]"]
  node_scanui["Scan workflow<br/>[useScanSession.ts]"]
end

subgraph group_identity["Identity"]
  node_auth["Authentication API<br/>[AuthController.php]"]
end

subgraph group_manga["Manga catalogue"]
  node_mangactrl["Manga API"]
  node_catalogue["Catalogue API"]
  node_scanapi["Scan API<br/>[ScanController.php]"]
  node_mangaapp["Manga operations"]
  node_cataloguesearch["Catalogue search"]
  node_mangaentity["Manga and volumes<br/>[Manga.php]"]
  node_mangastore["Manga repository"]
  node_coverproxy["Cover proxy"]
end

subgraph group_collection["Collection tracking"]
  node_collectionapi["Collection API"]
  node_collectionapp["Collection operations"]
  node_matcher["Catalogue matcher"]
  node_collectionstore["Collection repository"]
  node_wishlist["Wishlist API"]
end

subgraph group_insights["Insights and updates"]
  node_stats["Collection analytics"]
  node_articles["Articles and activity"]
  node_notifications["Notifications"]
end

node_reader(("Reader"))
node_externalcatalogues["External catalogues"]
node_postgres[("PostgreSQL")]

node_reader -->|"uses"| node_vue
node_vue -->|"routes to"| node_pages
node_pages -.->|"requests data"| node_api
node_api -.->|"calls API"| node_auth
node_api -.->|"calls API"| node_mangactrl
node_api -.->|"calls API"| node_catalogue
node_scanui -.->|"submits scans"| node_scanapi
node_reader -->|"searches editions"| node_catalogue
node_reader -->|"scans barcode"| node_scanui
node_mangactrl -.->|"handles requests"| node_mangaapp
node_catalogue -.->|"handles requests"| node_mangaapp
node_scanapi -.->|"handles requests"| node_mangaapp
node_mangaapp -.->|"reads and writes"| node_mangastore
node_mangastore -.->|"persists data"| node_postgres
node_catalogue -.->|"searches editions"| node_cataloguesearch
node_catalogue -->|"matches collection"| node_matcher
node_mangaapp -.->|"enriches from"| node_externalcatalogues
node_coverproxy -->|"fetches covers"| node_externalcatalogues
node_reader -->|"manages collection"| node_collectionapi
node_collectionapi -->|"dispatches commands"| node_collectionapp
node_collectionapi -->|"asks queries"| node_collectionapp
node_collectionapp -.->|"reads and writes"| node_collectionstore
node_collectionstore -.->|"persists data"| node_postgres
node_reader -->|"manages wishlist"| node_wishlist
node_wishlist -->|"dispatches commands"| node_collectionapp
node_wishlist -->|"asks queries"| node_collectionapp
node_reader -->|"views analytics"| node_stats
node_reader -->|"views updates"| node_notifications
node_reader -->|"browses articles"| node_articles

click node_vue "https://github.com/floberrot/ziggytheque/blob/main/front/src/App.vue"
click node_pages "https://github.com/floberrot/ziggytheque/tree/main/front/src/pages"
click node_api "https://github.com/floberrot/ziggytheque/blob/main/front/src/api/client.ts"
click node_scanui "https://github.com/floberrot/ziggytheque/blob/main/front/src/composables/useScanSession.ts"
click node_auth "https://github.com/floberrot/ziggytheque/blob/main/back/src/Auth/Infrastructure/Http/AuthController.php"
click node_mangactrl "https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Infrastructure/Http/MangaController.php"
click node_catalogue "https://github.com/floberrot/ziggytheque/blob/main/back/src/Collection/Infrastructure/Http/CatalogueController.php"
click node_scanapi "https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Infrastructure/Http/ScanController.php"
click node_mangaapp "https://github.com/floberrot/ziggytheque/tree/main/back/src/Manga/Application"
click node_cataloguesearch "https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Domain/Service/CatalogueSearch.php"
click node_mangaentity "https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Domain/Manga.php"
click node_mangastore "https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Infrastructure/Doctrine/DoctrineMangaRepository.php"
click node_coverproxy "https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Infrastructure/Http/CoverProxyController.php"
click node_collectionapi "https://github.com/floberrot/ziggytheque/blob/main/back/src/Collection/Infrastructure/Http/CollectionController.php"
click node_collectionapp "https://github.com/floberrot/ziggytheque/tree/main/back/src/Collection/Application"
click node_matcher "https://github.com/floberrot/ziggytheque/blob/main/back/src/Collection/Domain/Service/CatalogueCollectionMatcher.php"
click node_collectionstore "https://github.com/floberrot/ziggytheque/blob/main/back/src/Collection/Infrastructure/Doctrine/DoctrineCollectionRepository.php"
click node_wishlist "https://github.com/floberrot/ziggytheque/blob/main/back/src/Wishlist/Infrastructure/Http/WishlistController.php"
click node_stats "https://github.com/floberrot/ziggytheque/blob/main/back/src/Stats/Infrastructure/Http/StatsController.php"
click node_articles "https://github.com/floberrot/ziggytheque/blob/main/back/src/Notification/Infrastructure/Http/ArticleController.php"
click node_notifications "https://github.com/floberrot/ziggytheque/blob/main/back/src/Notification/Infrastructure/Http/NotificationController.php"

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_vue,node_pages,node_api,node_scanui toneBlue
class node_auth,node_postgres toneAmber
class node_mangactrl,node_catalogue,node_scanapi,node_mangaapp,node_cataloguesearch,node_mangaentity,node_mangastore,node_coverproxy toneMint
class node_collectionapi,node_collectionapp,node_matcher,node_collectionstore,node_wishlist toneRose
class node_stats,node_articles,node_notifications,node_reader,node_externalcatalogues toneIndigo
```

## Components

### Web client

- [Vue application](https://github.com/floberrot/ziggytheque/blob/main/front/src/App.vue): `front/src/App.vue`
- [Library pages](https://github.com/floberrot/ziggytheque/tree/main/front/src/pages): `front/src/pages`
- [API client](https://github.com/floberrot/ziggytheque/blob/main/front/src/api/client.ts): `front/src/api/client.ts`
- [Scan workflow](https://github.com/floberrot/ziggytheque/blob/main/front/src/composables/useScanSession.ts): `front/src/composables/useScanSession.ts`

### Identity

- [Authentication API](https://github.com/floberrot/ziggytheque/blob/main/back/src/Auth/Infrastructure/Http/AuthController.php): `back/src/Auth/Infrastructure/Http/AuthController.php`

### Manga catalogue

- [Manga API](https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Infrastructure/Http/MangaController.php): `back/src/Manga/Infrastructure/Http/MangaController.php`
- [Catalogue API](https://github.com/floberrot/ziggytheque/blob/main/back/src/Collection/Infrastructure/Http/CatalogueController.php): `back/src/Collection/Infrastructure/Http/CatalogueController.php`
- [Scan API](https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Infrastructure/Http/ScanController.php): `back/src/Manga/Infrastructure/Http/ScanController.php`
- [Manga operations](https://github.com/floberrot/ziggytheque/tree/main/back/src/Manga/Application): `back/src/Manga/Application`
- [Catalogue search](https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Domain/Service/CatalogueSearch.php): `back/src/Manga/Domain/Service/CatalogueSearch.php`
- [Manga and volumes](https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Domain/Manga.php): `back/src/Manga/Domain/Manga.php`
- [Manga repository](https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Infrastructure/Doctrine/DoctrineMangaRepository.php): `back/src/Manga/Infrastructure/Doctrine/DoctrineMangaRepository.php`
- [Cover proxy](https://github.com/floberrot/ziggytheque/blob/main/back/src/Manga/Infrastructure/Http/CoverProxyController.php): `back/src/Manga/Infrastructure/Http/CoverProxyController.php`

### Collection tracking

- [Collection API](https://github.com/floberrot/ziggytheque/blob/main/back/src/Collection/Infrastructure/Http/CollectionController.php): `back/src/Collection/Infrastructure/Http/CollectionController.php`
- [Collection operations](https://github.com/floberrot/ziggytheque/tree/main/back/src/Collection/Application): `back/src/Collection/Application`
- [Catalogue matcher](https://github.com/floberrot/ziggytheque/blob/main/back/src/Collection/Domain/Service/CatalogueCollectionMatcher.php): `back/src/Collection/Domain/Service/CatalogueCollectionMatcher.php`
- [Collection repository](https://github.com/floberrot/ziggytheque/blob/main/back/src/Collection/Infrastructure/Doctrine/DoctrineCollectionRepository.php): `back/src/Collection/Infrastructure/Doctrine/DoctrineCollectionRepository.php`
- [Wishlist API](https://github.com/floberrot/ziggytheque/blob/main/back/src/Wishlist/Infrastructure/Http/WishlistController.php): `back/src/Wishlist/Infrastructure/Http/WishlistController.php`

### Insights and updates

- [Collection analytics](https://github.com/floberrot/ziggytheque/blob/main/back/src/Stats/Infrastructure/Http/StatsController.php): `back/src/Stats/Infrastructure/Http/StatsController.php`
- [Articles and activity](https://github.com/floberrot/ziggytheque/blob/main/back/src/Notification/Infrastructure/Http/ArticleController.php): `back/src/Notification/Infrastructure/Http/ArticleController.php`
- [Notifications](https://github.com/floberrot/ziggytheque/blob/main/back/src/Notification/Infrastructure/Http/NotificationController.php): `back/src/Notification/Infrastructure/Http/NotificationController.php`

### Other components

- **Reader**
- **External catalogues**
- **PostgreSQL**

## Connections

- Reader → Vue application: uses
- Vue application → Library pages: routes to
- Library pages → API client: requests data
- API client → Authentication API: calls API
- API client → Manga API: calls API
- API client → Catalogue API: calls API
- Scan workflow → Scan API: submits scans
- Reader → Catalogue API: searches editions
- Reader → Scan workflow: scans barcode
- Manga API → Manga operations: handles requests
- Catalogue API → Manga operations: handles requests
- Scan API → Manga operations: handles requests
- Manga operations → Manga repository: reads and writes
- Manga repository → PostgreSQL: persists data
- Catalogue API → Catalogue search: searches editions
- Catalogue API → Catalogue matcher: matches collection
- Manga operations → External catalogues: enriches from
- Cover proxy → External catalogues: fetches covers (evidence: `back/src/Manga/Infrastructure/Http/CoverProxyController.php`)
- Reader → Collection API: manages collection
- Collection API → Collection operations: dispatches commands (evidence: `back/src/Collection/Infrastructure/Http/CollectionController.php`)
- Collection API → Collection operations: asks queries (evidence: `back/src/Collection/Infrastructure/Http/CollectionController.php`)
- Collection operations → Collection repository: reads and writes
- Collection repository → PostgreSQL: persists data
- Reader → Wishlist API: manages wishlist
- Wishlist API → Collection operations: dispatches commands (evidence: `back/src/Wishlist/Infrastructure/Http/WishlistController.php`)
- Wishlist API → Collection operations: asks queries (evidence: `back/src/Wishlist/Infrastructure/Http/WishlistController.php`)
- Reader → Collection analytics: views analytics
- Reader → Notifications: views updates
- Reader → Articles and activity: browses articles (evidence: `back/src/Notification/Infrastructure/Http/ArticleController.php`)
