# nextcloud/deck architecture

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

- Interactive diagram: https://gitdiagram.com/nextcloud/deck
- Repository: https://github.com/nextcloud/deck

## Overview

Deck is a Nextcloud kanban app for personal planning and team projects. A user works in the Vue app to organize boards into stacks and cards, then enriches cards with assignments, labels, dates, attachments, and comments; board sharing and collaboration support team use. The frontend communicates with server controllers, which delegate domain operations to services and persistence mappers. README capabilities also include activity, search, imports, dashboard views, and integrations. Some subsystem links are based on documented routes and module roles because their implementations were not sampled.

Main entry points: [`lib/Service/BoardService.php`](https://github.com/nextcloud/deck/blob/main/lib/Service/BoardService.php) (Board service), [`lib/Db/BoardMapper.php`](https://github.com/nextcloud/deck/blob/main/lib/Db/BoardMapper.php) (Domain mappers), [`lib/Controller/CardOcsController.php`](https://github.com/nextcloud/deck/blob/main/lib/Controller/CardOcsController.php) (Card controller), [`src/App.vue`](https://github.com/nextcloud/deck/blob/main/src/App.vue) (Vue app)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["Web app"]
  node_app["Vue app<br/>[App.vue]"]
  node_boardui["Board interface<br/>[Board.vue]"]
  node_cardui["Card interface<br/>[CardSidebar.vue]"]
  node_frontendapis["Frontend APIs<br/>[BoardApi.js]"]
end

subgraph group_domain["Board operations"]
  node_boardroutes["Board endpoints<br/>[routes.php]"]
  node_boardcontroller["Board controller"]
  node_cardcontroller["Card controller"]
  node_boardsvc["Board service<br/>[BoardService.php]"]
  node_cardsvc["Card service<br/>[CardService.php]"]
  node_stacksvc["Stack service<br/>[StackService.php]"]
  node_commentsvc["Comment service<br/>[CommentService.php]"]
  node_attachmentsvc["Attachment service"]
end

subgraph group_persistence["Storage"]
  node_mappers["Domain mappers<br/>[BoardMapper.php]"]
  node_database[("Nextcloud database")]
end

subgraph group_collaboration["Collaboration"]
  node_sharing["Board sharing"]
  node_activity["Activity stream"]
  node_sessions["Live sessions<br/>[SessionService.php]"]
  node_notify["Notify push"]
end

subgraph group_extensions["Integrations"]
  node_search["Search<br/>[SearchService.php]"]
  node_fulltext["Full-text indexing"]
  node_import["Board import"]
  node_externalboards["Remote boards"]
  node_circles["Circles"]
  node_dashboard["Dashboard widgets"]
end

node_user(("Deck user"))

node_user -->|"uses"| node_app
node_app -->|"renders"| node_boardui
node_boardui -->|"opens cards"| node_cardui
node_app -->|"loads boards"| node_frontendapis
node_frontendapis -->|"requests"| node_boardroutes
node_boardroutes -->|"dispatches"| node_boardcontroller
node_boardroutes -->|"dispatches"| node_cardcontroller
node_boardcontroller -->|"calls"| node_boardsvc
node_cardcontroller -->|"calls"| node_cardsvc
node_cardcontroller -->|"looks up board"| node_boardsvc
node_cardcontroller -->|"routes remote operations"| node_externalboards
node_boardsvc -->|"persists and reads"| node_mappers
node_cardsvc -->|"persists and reads"| node_mappers
node_stacksvc -->|"persists and reads"| node_mappers
node_commentsvc -->|"uses domain data"| node_mappers
node_attachmentsvc -->|"uses domain data"| node_mappers
node_mappers -->|"reads and writes"| node_database
node_boardsvc -->|"supports board access"| node_sharing
node_boardsvc -.->|"optional team integration"| node_circles
node_cardsvc -->|"records changes"| node_activity
node_sessions -->|"queues updates"| node_notify
node_search -.->|"supports indexing"| node_fulltext
node_import -->|"creates imported boards"| node_boardsvc
node_dashboard -.->|"uses board data"| node_boardsvc

click node_app "https://github.com/nextcloud/deck/blob/main/src/App.vue"
click node_boardui "https://github.com/nextcloud/deck/blob/main/src/components/board/Board.vue"
click node_cardui "https://github.com/nextcloud/deck/blob/main/src/components/card/CardSidebar.vue"
click node_frontendapis "https://github.com/nextcloud/deck/blob/main/src/services/BoardApi.js"
click node_boardroutes "https://github.com/nextcloud/deck/blob/main/appinfo/routes.php"
click node_boardcontroller "https://github.com/nextcloud/deck/blob/main/lib/Controller/BoardController.php"
click node_cardcontroller "https://github.com/nextcloud/deck/blob/main/lib/Controller/CardOcsController.php"
click node_boardsvc "https://github.com/nextcloud/deck/blob/main/lib/Service/BoardService.php"
click node_cardsvc "https://github.com/nextcloud/deck/blob/main/lib/Service/CardService.php"
click node_stacksvc "https://github.com/nextcloud/deck/blob/main/lib/Service/StackService.php"
click node_commentsvc "https://github.com/nextcloud/deck/blob/main/lib/Service/CommentService.php"
click node_attachmentsvc "https://github.com/nextcloud/deck/blob/main/lib/Service/AttachmentService.php"
click node_mappers "https://github.com/nextcloud/deck/blob/main/lib/Db/BoardMapper.php"
click node_sharing "https://github.com/nextcloud/deck/blob/main/lib/Sharing/DeckShareProvider.php"
click node_activity "https://github.com/nextcloud/deck/blob/main/lib/Activity/ActivityManager.php"
click node_sessions "https://github.com/nextcloud/deck/blob/main/lib/Service/SessionService.php"
click node_search "https://github.com/nextcloud/deck/blob/main/lib/Service/SearchService.php"
click node_fulltext "https://github.com/nextcloud/deck/blob/main/lib/Service/FullTextSearchService.php"
click node_import "https://github.com/nextcloud/deck/blob/main/lib/Service/Importer/BoardImportService.php"
click node_externalboards "https://github.com/nextcloud/deck/blob/main/lib/Service/ExternalBoardService.php"
click node_dashboard "https://github.com/nextcloud/deck/blob/main/lib/Dashboard/DeckWidgetUpcoming.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_app,node_boardui,node_cardui,node_frontendapis,node_user toneBlue
class node_boardroutes,node_boardcontroller,node_cardcontroller,node_boardsvc,node_cardsvc,node_stacksvc,node_commentsvc,node_attachmentsvc toneAmber
class node_mappers,node_database toneMint
class node_sharing,node_activity,node_sessions,node_notify toneRose
class node_search,node_fulltext,node_import,node_externalboards,node_circles,node_dashboard toneIndigo
```

## Components

### Web app

- [Vue app](https://github.com/nextcloud/deck/blob/main/src/App.vue): `src/App.vue`
- [Board interface](https://github.com/nextcloud/deck/blob/main/src/components/board/Board.vue): `src/components/board/Board.vue`
- [Card interface](https://github.com/nextcloud/deck/blob/main/src/components/card/CardSidebar.vue): `src/components/card/CardSidebar.vue`
- [Frontend APIs](https://github.com/nextcloud/deck/blob/main/src/services/BoardApi.js): `src/services/BoardApi.js`

### Board operations

- [Board endpoints](https://github.com/nextcloud/deck/blob/main/appinfo/routes.php): `appinfo/routes.php`
- [Board controller](https://github.com/nextcloud/deck/blob/main/lib/Controller/BoardController.php): `lib/Controller/BoardController.php`
- [Card controller](https://github.com/nextcloud/deck/blob/main/lib/Controller/CardOcsController.php): `lib/Controller/CardOcsController.php`
- [Board service](https://github.com/nextcloud/deck/blob/main/lib/Service/BoardService.php): `lib/Service/BoardService.php`
- [Card service](https://github.com/nextcloud/deck/blob/main/lib/Service/CardService.php): `lib/Service/CardService.php`
- [Stack service](https://github.com/nextcloud/deck/blob/main/lib/Service/StackService.php): `lib/Service/StackService.php`
- [Comment service](https://github.com/nextcloud/deck/blob/main/lib/Service/CommentService.php): `lib/Service/CommentService.php`
- [Attachment service](https://github.com/nextcloud/deck/blob/main/lib/Service/AttachmentService.php): `lib/Service/AttachmentService.php`

### Storage

- [Domain mappers](https://github.com/nextcloud/deck/blob/main/lib/Db/BoardMapper.php): `lib/Db/BoardMapper.php`
- **Nextcloud database**

### Collaboration

- [Board sharing](https://github.com/nextcloud/deck/blob/main/lib/Sharing/DeckShareProvider.php): `lib/Sharing/DeckShareProvider.php`
- [Activity stream](https://github.com/nextcloud/deck/blob/main/lib/Activity/ActivityManager.php): `lib/Activity/ActivityManager.php`
- [Live sessions](https://github.com/nextcloud/deck/blob/main/lib/Service/SessionService.php): `lib/Service/SessionService.php`
- **Notify push**

### Integrations

- [Search](https://github.com/nextcloud/deck/blob/main/lib/Service/SearchService.php): `lib/Service/SearchService.php`
- [Full-text indexing](https://github.com/nextcloud/deck/blob/main/lib/Service/FullTextSearchService.php): `lib/Service/FullTextSearchService.php`
- [Board import](https://github.com/nextcloud/deck/blob/main/lib/Service/Importer/BoardImportService.php): `lib/Service/Importer/BoardImportService.php`
- [Remote boards](https://github.com/nextcloud/deck/blob/main/lib/Service/ExternalBoardService.php): `lib/Service/ExternalBoardService.php`
- **Circles**
- [Dashboard widgets](https://github.com/nextcloud/deck/blob/main/lib/Dashboard/DeckWidgetUpcoming.php): `lib/Dashboard/DeckWidgetUpcoming.php`

### Other components

- **Deck user**

## Connections

- Deck user → Vue app: uses
- Vue app → Board interface: renders
- Board interface → Card interface: opens cards
- Vue app → Frontend APIs: loads boards
- Frontend APIs → Board endpoints: requests
- Board endpoints → Board controller: dispatches
- Board endpoints → Card controller: dispatches
- Board controller → Board service: calls
- Card controller → Card service: calls
- Card controller → Board service: looks up board
- Card controller → Remote boards: routes remote operations
- Board service → Domain mappers: persists and reads
- Card service → Domain mappers: persists and reads
- Stack service → Domain mappers: persists and reads
- Comment service → Domain mappers: uses domain data
- Attachment service → Domain mappers: uses domain data
- Domain mappers → Nextcloud database: reads and writes
- Board service → Board sharing: supports board access
- Board service → Circles: optional team integration
- Card service → Activity stream: records changes
- Live sessions → Notify push: queues updates
- Search → Full-text indexing: supports indexing
- Board import → Board service: creates imported boards
- Dashboard widgets → Board service: uses board data
