# ardalis/pluralsight-ddd-fundamentals architecture

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

- Interactive diagram: https://gitdiagram.com/ardalis/pluralsight-ddd-fundamentals
- Repository: https://github.com/ardalis/pluralsight-ddd-fundamentals

## Overview

This repository is a DDD course sample made of three related web applications: FrontDesk handles scheduling, ClinicManagement manages clinic records, and VetClinicPublic supports appointment confirmation by email. The main user journey is scheduling an appointment in FrontDesk, sending a confirmation through messaging to VetClinicPublic, and processing the client’s confirmation link. ClinicManagement supplies separately managed clinic data, with live synchronization documented between the applications. The excerpts show application setup and some messaging/repository behavior; several endpoint and integration details are represented only by the README or remain unverified.

Main entry points: [`FrontDesk/src/FrontDesk.Api/Endpoints`](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Api/Endpoints) (FrontDesk API), [`FrontDesk/src/FrontDesk.Blazor/Pages`](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Blazor/Pages) (FrontDesk UI), [`ClinicManagement/src/ClinicManagement.Api/Endpoints`](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Api/Endpoints) (Clinic API), [`FrontDesk/src/FrontDesk.Core/Handlers/RelayAppointmentScheduledService.cs`](https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/FrontDesk/src/FrontDesk.Core/Handlers/RelayAppointmentScheduledService.cs) (Appointment relay)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontdesk["FrontDesk scheduling"]
  node_frontdesk_ui["FrontDesk UI<br/>[Pages]"]
  node_scheduler["Scheduler UI<br/>[SchedulerComponent]"]
  node_frontdesk_services["FrontDesk services<br/>[Services]"]
  node_frontdesk_api["FrontDesk API<br/>[Endpoints]"]
  node_schedule_hub["Schedule hub<br/>[ScheduleHub.cs]"]
  node_frontdesk_store[("FrontDesk persistence<br/>[Data]")]
  node_frontdesk_consumer["Clinic sync consumers<br/>[MessageHandlers]"]
end

subgraph group_clinic["Clinic management"]
  node_clinic_ui["Clinic UI<br/>[Pages]"]
  node_clinic_services["Clinic services<br/>[Services]"]
  node_clinic_api["Clinic API<br/>[Endpoints]"]
  node_clinic_domain["Clinic records<br/>[Aggregates]"]
  node_clinic_store[("Clinic persistence<br/>[Data]")]
  node_clinic_events["Clinic events"]
end

subgraph group_public["Public confirmation"]
  node_public_site["Confirmation site"]
  node_email_handler["Email handler"]
  node_email_sender["Email sender"]
end

subgraph group_shared["Shared domain and messaging"]
  node_appointment_domain["Appointment domain<br/>[FrontDesk.Core]"]
  node_schedule_domain["Schedule domain<br/>[FrontDesk.Core]"]
  node_appointment_relay["Appointment relay"]
  node_message_bus["RabbitMQ bus"]
  node_shared_contracts["Integration contracts"]
end

node_staff(("Clinic staff"))
node_smtp["SMTP server"]
node_confirmation_client(("Appointment client"))

node_staff -->|"uses"| node_frontdesk_ui
node_frontdesk_ui -.->|"uses"| node_frontdesk_services
node_frontdesk_services -.->|"HTTP requests"| node_frontdesk_api
node_frontdesk_api -.->|"handles scheduling"| node_appointment_domain
node_frontdesk_api -.->|"persists records"| node_frontdesk_store
node_frontdesk_api -->|"maps hub"| node_schedule_hub
node_frontdesk_ui -.->|"uses"| node_scheduler
node_scheduler -->|"uses appointments"| node_schedule_domain
node_appointment_domain -->|"raises event"| node_appointment_relay
node_appointment_relay -->|"creates message"| node_shared_contracts
node_appointment_relay -->|"publishes"| node_message_bus
node_message_bus -.->|"delivers appointment"| node_public_site
node_staff -->|"uses"| node_clinic_ui
node_clinic_ui -.->|"uses"| node_clinic_services
node_clinic_services -.->|"HTTP requests"| node_clinic_api
node_clinic_api -.->|"handles records"| node_clinic_domain
node_clinic_api -.->|"persists records"| node_clinic_store
node_clinic_domain -.->|"publishes updates"| node_clinic_events
node_clinic_events -.->|"relayed through"| node_message_bus
node_message_bus -.->|"delivers updates"| node_frontdesk_consumer
node_frontdesk_consumer -->|"synchronizes records"| node_frontdesk_store
node_confirmation_client -->|"opens confirmation link"| node_public_site
node_public_site -->|"publishes confirmation"| node_message_bus
node_message_bus -.->|"delivers confirmation"| node_frontdesk_api
node_email_handler -->|"requests email"| node_email_sender
node_email_sender -.->|"sends mail"| node_smtp

click node_frontdesk_ui "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Blazor/Pages"
click node_scheduler "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Blazor/Shared/SchedulerComponent"
click node_frontdesk_services "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Blazor/Services"
click node_frontdesk_api "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Api/Endpoints"
click node_schedule_hub "https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/FrontDesk/src/FrontDesk.Api/Hubs/ScheduleHub.cs"
click node_appointment_domain "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Core"
click node_schedule_domain "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Core"
click node_appointment_relay "https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/FrontDesk/src/FrontDesk.Core/Handlers/RelayAppointmentScheduledService.cs"
click node_frontdesk_store "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Infrastructure/Data"
click node_clinic_ui "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Blazor/Pages"
click node_clinic_services "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Blazor/Services"
click node_clinic_api "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Api/Endpoints"
click node_clinic_domain "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Core/Aggregates"
click node_clinic_store "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Infrastructure/Data"
click node_public_site "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/VetClinicPublic/src/VetClinicPublic/Controllers"
click node_email_handler "https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/VetClinicPublic/src/VetClinicPublic/Services/ConfirmationEmailHandler.cs"
click node_email_sender "https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/VetClinicPublic/src/VetClinicPublic/Services/ConfirmationEmailSender.cs"
click node_frontdesk_consumer "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Api/MessageHandlers"
click node_clinic_events "https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Contracts"
click node_shared_contracts "https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/FrontDesk/src/FrontDesk.Contracts/AppointmentScheduledIntegrationEvent.cs"

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_frontdesk_ui,node_scheduler,node_frontdesk_services,node_frontdesk_api,node_schedule_hub,node_frontdesk_store,node_frontdesk_consumer,node_confirmation_client toneBlue
class node_clinic_ui,node_clinic_services,node_clinic_api,node_clinic_domain,node_clinic_store,node_clinic_events toneAmber
class node_public_site,node_email_handler,node_email_sender,node_smtp toneMint
class node_appointment_domain,node_schedule_domain,node_appointment_relay,node_message_bus,node_shared_contracts toneRose
class node_staff toneIndigo
```

## Components

### FrontDesk scheduling

- [FrontDesk UI](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Blazor/Pages): `FrontDesk/src/FrontDesk.Blazor/Pages`
- [Scheduler UI](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Blazor/Shared/SchedulerComponent): `FrontDesk/src/FrontDesk.Blazor/Shared/SchedulerComponent`
- [FrontDesk services](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Blazor/Services): `FrontDesk/src/FrontDesk.Blazor/Services`
- [FrontDesk API](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Api/Endpoints): `FrontDesk/src/FrontDesk.Api/Endpoints`
- [Schedule hub](https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/FrontDesk/src/FrontDesk.Api/Hubs/ScheduleHub.cs): `FrontDesk/src/FrontDesk.Api/Hubs/ScheduleHub.cs`
- [FrontDesk persistence](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Infrastructure/Data): `FrontDesk/src/FrontDesk.Infrastructure/Data`
- [Clinic sync consumers](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Api/MessageHandlers): `FrontDesk/src/FrontDesk.Api/MessageHandlers`

### Clinic management

- [Clinic UI](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Blazor/Pages): `ClinicManagement/src/ClinicManagement.Blazor/Pages`
- [Clinic services](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Blazor/Services): `ClinicManagement/src/ClinicManagement.Blazor/Services`
- [Clinic API](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Api/Endpoints): `ClinicManagement/src/ClinicManagement.Api/Endpoints`
- [Clinic records](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Core/Aggregates): `ClinicManagement/src/ClinicManagement.Core/Aggregates`
- [Clinic persistence](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Infrastructure/Data): `ClinicManagement/src/ClinicManagement.Infrastructure/Data`
- [Clinic events](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/ClinicManagement/src/ClinicManagement.Contracts): `ClinicManagement/src/ClinicManagement.Contracts`

### Public confirmation

- [Confirmation site](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/VetClinicPublic/src/VetClinicPublic/Controllers): `VetClinicPublic/src/VetClinicPublic/Controllers`
- [Email handler](https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/VetClinicPublic/src/VetClinicPublic/Services/ConfirmationEmailHandler.cs): `VetClinicPublic/src/VetClinicPublic/Services/ConfirmationEmailHandler.cs`
- [Email sender](https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/VetClinicPublic/src/VetClinicPublic/Services/ConfirmationEmailSender.cs): `VetClinicPublic/src/VetClinicPublic/Services/ConfirmationEmailSender.cs`

### Shared domain and messaging

- [Appointment domain](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Core): `FrontDesk/src/FrontDesk.Core`
- [Schedule domain](https://github.com/ardalis/pluralsight-ddd-fundamentals/tree/main/FrontDesk/src/FrontDesk.Core): `FrontDesk/src/FrontDesk.Core`
- [Appointment relay](https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/FrontDesk/src/FrontDesk.Core/Handlers/RelayAppointmentScheduledService.cs): `FrontDesk/src/FrontDesk.Core/Handlers/RelayAppointmentScheduledService.cs`
- **RabbitMQ bus**
- [Integration contracts](https://github.com/ardalis/pluralsight-ddd-fundamentals/blob/main/FrontDesk/src/FrontDesk.Contracts/AppointmentScheduledIntegrationEvent.cs): `FrontDesk/src/FrontDesk.Contracts/AppointmentScheduledIntegrationEvent.cs`

### Other components

- **Clinic staff**
- **SMTP server**
- **Appointment client**

## Connections

- Clinic staff → FrontDesk UI: uses (evidence: `README.md`)
- FrontDesk UI → FrontDesk services: uses
- FrontDesk services → FrontDesk API: HTTP requests
- FrontDesk API → Appointment domain: handles scheduling
- FrontDesk API → FrontDesk persistence: persists records
- FrontDesk API → Schedule hub: maps hub
- FrontDesk UI → Scheduler UI: uses
- Scheduler UI → Schedule domain: uses appointments (evidence: `FrontDesk/src/FrontDesk.Blazor/Shared/SchedulerComponent/SchedulerService.cs`)
- Appointment domain → Appointment relay: raises event (evidence: `FrontDesk/src/FrontDesk.Core/Handlers/RelayAppointmentScheduledService.cs`)
- Appointment relay → Integration contracts: creates message (evidence: `FrontDesk/src/FrontDesk.Core/Handlers/RelayAppointmentScheduledService.cs`)
- Appointment relay → RabbitMQ bus: publishes (evidence: `FrontDesk/src/FrontDesk.Core/Handlers/RelayAppointmentScheduledService.cs`)
- RabbitMQ bus → Confirmation site: delivers appointment (evidence: `README.md`)
- Clinic staff → Clinic UI: uses (evidence: `README.md`)
- Clinic UI → Clinic services: uses
- Clinic services → Clinic API: HTTP requests
- Clinic API → Clinic records: handles records
- Clinic API → Clinic persistence: persists records
- Clinic records → Clinic events: publishes updates (evidence: `README.md`)
- Clinic events → RabbitMQ bus: relayed through (evidence: `README.md`)
- RabbitMQ bus → Clinic sync consumers: delivers updates (evidence: `README.md`)
- Clinic sync consumers → FrontDesk persistence: synchronizes records (evidence: `FrontDesk/src/FrontDesk.Api/MessageHandlers/ClinicManagementClientConsumer.cs`)
- Appointment client → Confirmation site: opens confirmation link (evidence: `README.md`)
- Confirmation site → RabbitMQ bus: publishes confirmation (evidence: `VetClinicPublic/src/VetClinicPublic/Controllers/AppointmentController.cs`)
- RabbitMQ bus → FrontDesk API: delivers confirmation (evidence: `README.md`)
- Email handler → Email sender: requests email (evidence: `VetClinicPublic/src/VetClinicPublic/Services/ConfirmationEmailHandler.cs`)
- Email sender → SMTP server: sends mail
