# nextcloud/calendar architecture

> Architecture diagram of the GitHub repository nextcloud/calendar, 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/calendar
- Repository: https://github.com/nextcloud/calendar

## Overview

Nextcloud Calendar is a web calendar for viewing, creating, editing, and syncing events, with sharing, invitations, availability, reminders, tasks, attachments, and integrations. The main workflow starts in the calendar UI, uses client services and stores to load or change calendar data through Nextcloud’s CalDAV backend, and presents the result in calendar views or editors. Separate flows support public appointment booking and collaborative meeting proposals. Paths and wiring reflect the tree, README, and sampled excerpts; some capability links are documented rather than verified in sampled implementation.

Main entry points: [`lib/Controller/BookingController.php`](https://github.com/nextcloud/calendar/blob/main/lib/Controller/BookingController.php) (Booking controller), [`src/App.vue`](https://github.com/nextcloud/calendar/blob/main/src/App.vue) (Calendar app), [`lib/Service/Appointments/BookingService.php`](https://github.com/nextcloud/calendar/blob/main/lib/Service/Appointments/BookingService.php) (Booking service), [`lib/Service/Proposal/ProposalService.php`](https://github.com/nextcloud/calendar/blob/main/lib/Service/Proposal/ProposalService.php) (Proposal service)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_calendar["Calendar experience"]
  node_app["Calendar app<br/>[App.vue]"]
  node_calendar_view["Calendar views<br/>[Calendar.vue]"]
  node_event_editor["Event editor<br/>[EditFull.vue]"]
  node_public_view["Public and embed views<br/>[ProposalPublic.vue]"]
end

subgraph group_client["Client data layer"]
  node_calendar_service["CalDAV service<br/>[caldavService.js]"]
  node_calendar_store["Calendar stores<br/>[calendars.js]"]
  node_event_store["Event stores<br/>[calendarObjects.js]"]
  node_availability["Free/busy services<br/>[freeBusyService.js]"]
  node_contacts["Contact services"]
  node_settings["Calendar settings<br/>[settings.js]"]
end

subgraph group_appointments["Appointment booking"]
  node_booking_pages["Booking pages<br/>[Booking.vue]"]
  node_booking_ui["Booking confirmation<br/>[Confirmation.vue]"]
  node_booking_api["Booking controller"]
  node_booking_service["Booking service<br/>[BookingService.php]"]
  node_availability_generator["Slot generation"]
  node_appointment_config["Appointment configuration"]
  node_booking_store[("Booking records<br/>[BookingMapper.php]")]
  node_mail["Booking email<br/>[MailService.php]"]
end

subgraph group_proposals["Meeting proposals"]
  node_proposal_ui["Proposal editor<br/>[ProposalEditor.vue]"]
  node_proposal_service_client["Proposal client service<br/>[proposalService.ts]"]
  node_proposal_controller["Proposal controller"]
  node_proposal_service["Proposal service"]
  node_proposal_store[("Proposal records<br/>[ProposalMapper.php]")]
end

subgraph group_platform["Nextcloud platform"]
end

node_user(("Calendar user"))
node_caldav["Nextcloud CalDAV"]
node_contacts_platform["Nextcloud contacts"]
node_talk["Nextcloud Talk"]
node_email_service["Nextcloud mail"]

node_user -->|"opens"| node_app
node_app -->|"renders"| node_calendar_view
node_calendar_view -->|"reads events"| node_event_store
node_event_editor -->|"changes events"| node_event_store
node_event_store -->|"loads and saves"| node_calendar_service
node_calendar_store -->|"loads calendars"| node_calendar_service
node_calendar_service -->|"syncs events"| node_caldav
node_calendar_view -->|"requests availability"| node_availability
node_availability -->|"queries free/busy"| node_caldav
node_event_editor -->|"finds invitees"| node_contacts
node_contacts -->|"searches contacts"| node_contacts_platform
node_app -->|"reads preferences"| node_settings
node_user -->|"opens booking link"| node_booking_pages
node_booking_pages -->|"requests slots"| node_booking_api
node_booking_api -->|"loads configuration"| node_appointment_config
node_booking_api -->|"generates slots"| node_availability_generator
node_booking_api -->|"books or confirms"| node_booking_service
node_booking_service -->|"persists bookings"| node_booking_store
node_booking_service -->|"sends notifications"| node_mail
node_mail -->|"delivers email"| node_email_service
node_booking_api -->|"returns outcome"| node_booking_ui
node_user -->|"creates or responds"| node_proposal_ui
node_proposal_ui -->|"submits proposal"| node_proposal_service_client
node_proposal_service_client -->|"calls proposal API"| node_proposal_controller
node_proposal_controller -->|"handles proposal"| node_proposal_service
node_proposal_service -->|"reads and writes"| node_proposal_store
node_proposal_service -->|"updates calendar blockers"| node_caldav
node_proposal_service -->|"sends proposal notices"| node_email_service
node_booking_service -.->|"creates room"| node_talk
node_app -->|"renders public modes"| node_public_view

click node_app "https://github.com/nextcloud/calendar/blob/main/src/App.vue"
click node_calendar_view "https://github.com/nextcloud/calendar/blob/main/src/views/Calendar.vue"
click node_event_editor "https://github.com/nextcloud/calendar/blob/main/src/views/EditFull.vue"
click node_public_view "https://github.com/nextcloud/calendar/blob/main/src/views/Proposal/ProposalPublic.vue"
click node_calendar_service "https://github.com/nextcloud/calendar/blob/main/src/services/caldavService.js"
click node_calendar_store "https://github.com/nextcloud/calendar/blob/main/src/store/calendars.js"
click node_event_store "https://github.com/nextcloud/calendar/blob/main/src/store/calendarObjects.js"
click node_availability "https://github.com/nextcloud/calendar/blob/main/src/services/freeBusyService.js"
click node_contacts "https://github.com/nextcloud/calendar/blob/main/src/services/autocompleteService.ts"
click node_settings "https://github.com/nextcloud/calendar/blob/main/src/store/settings.js"
click node_booking_pages "https://github.com/nextcloud/calendar/blob/main/src/views/Appointments/Booking.vue"
click node_booking_ui "https://github.com/nextcloud/calendar/blob/main/src/views/Appointments/Confirmation.vue"
click node_booking_api "https://github.com/nextcloud/calendar/blob/main/lib/Controller/BookingController.php"
click node_booking_service "https://github.com/nextcloud/calendar/blob/main/lib/Service/Appointments/BookingService.php"
click node_availability_generator "https://github.com/nextcloud/calendar/blob/main/lib/Service/Appointments/AvailabilityGenerator.php"
click node_appointment_config "https://github.com/nextcloud/calendar/blob/main/lib/Service/Appointments/AppointmentConfigService.php"
click node_booking_store "https://github.com/nextcloud/calendar/blob/main/lib/Db/BookingMapper.php"
click node_mail "https://github.com/nextcloud/calendar/blob/main/lib/Service/Appointments/MailService.php"
click node_proposal_ui "https://github.com/nextcloud/calendar/blob/main/src/views/Proposal/ProposalEditor.vue"
click node_proposal_service_client "https://github.com/nextcloud/calendar/blob/main/src/services/proposalService.ts"
click node_proposal_controller "https://github.com/nextcloud/calendar/blob/main/lib/Controller/ProposalController.php"
click node_proposal_service "https://github.com/nextcloud/calendar/blob/main/lib/Service/Proposal/ProposalService.php"
click node_proposal_store "https://github.com/nextcloud/calendar/blob/main/lib/Db/ProposalMapper.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_calendar_view,node_event_editor,node_public_view,node_user toneBlue
class node_calendar_service,node_calendar_store,node_event_store,node_availability,node_contacts,node_settings toneAmber
class node_booking_pages,node_booking_ui,node_booking_api,node_booking_service,node_availability_generator,node_appointment_config,node_booking_store,node_mail toneMint
class node_proposal_ui,node_proposal_service_client,node_proposal_controller,node_proposal_service,node_proposal_store toneRose
class node_caldav,node_contacts_platform,node_talk,node_email_service toneIndigo
```

## Components

### Calendar experience

- [Calendar app](https://github.com/nextcloud/calendar/blob/main/src/App.vue): `src/App.vue`
- [Calendar views](https://github.com/nextcloud/calendar/blob/main/src/views/Calendar.vue): `src/views/Calendar.vue`
- [Event editor](https://github.com/nextcloud/calendar/blob/main/src/views/EditFull.vue): `src/views/EditFull.vue`
- [Public and embed views](https://github.com/nextcloud/calendar/blob/main/src/views/Proposal/ProposalPublic.vue): `src/views/Proposal/ProposalPublic.vue`

### Client data layer

- [CalDAV service](https://github.com/nextcloud/calendar/blob/main/src/services/caldavService.js): `src/services/caldavService.js`
- [Calendar stores](https://github.com/nextcloud/calendar/blob/main/src/store/calendars.js): `src/store/calendars.js`
- [Event stores](https://github.com/nextcloud/calendar/blob/main/src/store/calendarObjects.js): `src/store/calendarObjects.js`
- [Free/busy services](https://github.com/nextcloud/calendar/blob/main/src/services/freeBusyService.js): `src/services/freeBusyService.js`
- [Contact services](https://github.com/nextcloud/calendar/blob/main/src/services/autocompleteService.ts): `src/services/autocompleteService.ts`
- [Calendar settings](https://github.com/nextcloud/calendar/blob/main/src/store/settings.js): `src/store/settings.js`

### Appointment booking

- [Booking pages](https://github.com/nextcloud/calendar/blob/main/src/views/Appointments/Booking.vue): `src/views/Appointments/Booking.vue`
- [Booking confirmation](https://github.com/nextcloud/calendar/blob/main/src/views/Appointments/Confirmation.vue): `src/views/Appointments/Confirmation.vue`
- [Booking controller](https://github.com/nextcloud/calendar/blob/main/lib/Controller/BookingController.php): `lib/Controller/BookingController.php`
- [Booking service](https://github.com/nextcloud/calendar/blob/main/lib/Service/Appointments/BookingService.php): `lib/Service/Appointments/BookingService.php`
- [Slot generation](https://github.com/nextcloud/calendar/blob/main/lib/Service/Appointments/AvailabilityGenerator.php): `lib/Service/Appointments/AvailabilityGenerator.php`
- [Appointment configuration](https://github.com/nextcloud/calendar/blob/main/lib/Service/Appointments/AppointmentConfigService.php): `lib/Service/Appointments/AppointmentConfigService.php`
- [Booking records](https://github.com/nextcloud/calendar/blob/main/lib/Db/BookingMapper.php): `lib/Db/BookingMapper.php`
- [Booking email](https://github.com/nextcloud/calendar/blob/main/lib/Service/Appointments/MailService.php): `lib/Service/Appointments/MailService.php`

### Meeting proposals

- [Proposal editor](https://github.com/nextcloud/calendar/blob/main/src/views/Proposal/ProposalEditor.vue): `src/views/Proposal/ProposalEditor.vue`
- [Proposal client service](https://github.com/nextcloud/calendar/blob/main/src/services/proposalService.ts): `src/services/proposalService.ts`
- [Proposal controller](https://github.com/nextcloud/calendar/blob/main/lib/Controller/ProposalController.php): `lib/Controller/ProposalController.php`
- [Proposal service](https://github.com/nextcloud/calendar/blob/main/lib/Service/Proposal/ProposalService.php): `lib/Service/Proposal/ProposalService.php`
- [Proposal records](https://github.com/nextcloud/calendar/blob/main/lib/Db/ProposalMapper.php): `lib/Db/ProposalMapper.php`

### Other components

- **Calendar user**
- **Nextcloud CalDAV**
- **Nextcloud contacts**
- **Nextcloud Talk**
- **Nextcloud mail**

## Connections

- Calendar user → Calendar app: opens
- Calendar app → Calendar views: renders
- Calendar views → Event stores: reads events
- Event editor → Event stores: changes events
- Event stores → CalDAV service: loads and saves
- Calendar stores → CalDAV service: loads calendars
- CalDAV service → Nextcloud CalDAV: syncs events
- Calendar views → Free/busy services: requests availability
- Free/busy services → Nextcloud CalDAV: queries free/busy
- Event editor → Contact services: finds invitees
- Contact services → Nextcloud contacts: searches contacts
- Calendar app → Calendar settings: reads preferences
- Calendar user → Booking pages: opens booking link
- Booking pages → Booking controller: requests slots
- Booking controller → Appointment configuration: loads configuration
- Booking controller → Slot generation: generates slots
- Booking controller → Booking service: books or confirms
- Booking service → Booking records: persists bookings
- Booking service → Booking email: sends notifications
- Booking email → Nextcloud mail: delivers email
- Booking controller → Booking confirmation: returns outcome
- Calendar user → Proposal editor: creates or responds
- Proposal editor → Proposal client service: submits proposal
- Proposal client service → Proposal controller: calls proposal API
- Proposal controller → Proposal service: handles proposal
- Proposal service → Proposal records: reads and writes
- Proposal service → Nextcloud CalDAV: updates calendar blockers
- Proposal service → Nextcloud mail: sends proposal notices
- Booking service → Nextcloud Talk: creates room
- Calendar app → Public and embed views: renders public modes
