---
title: Business capabilities and journey map
summary: The core capabilities BookWorm delivers and how customer journeys cross the catalog, shopping, ordering, reviews, and platform domains.
version: 1.0.0
type: guides
order: 2
badges:
  - content: Guide
    backgroundColor: blue
    textColor: blue
---

BookWorm organizes its online bookstore around six business capabilities aligned to bounded contexts rather than UI screens. Separating capabilities by business ownership lets product discovery, basket management, order processing, customer reviews, AI guidance, and operational messaging evolve independently while delivering one seamless shopping experience.

## Context and motivation

When an e-commerce platform structures code around frontend screens, product rules, basket state, checkout pricing, and order status collapse into one coupled layer. A minor change to search filtering or email formatting then risks corrupting committed orders. BookWorm prevents this coupling by assigning each business capability a single owning context and connecting journeys across explicit HTTP, gRPC, MCP, A2A, and Kafka contracts.

## How it works

This journey map shows how a customer moves through Storefront and Commerce while interacting with each underlying bounded context.

<MermaidFileLoader file="mermaids/02-business-capabilities-diagram-1.mmd" />

### Capability ownership map

| Capability                         | Owning bounded context     | Primary edge app             | Purpose                                                                                                     |
| :--------------------------------- | :------------------------- | :--------------------------- | :---------------------------------------------------------------------------------------------------------- |
| **Product discovery and metadata** | [[domain\|catalog]]        | Storefront, Backoffice       | Maintain canonical titles, authors, categories, publishers, pricing, availability, and hybrid vector search |
| **Basket and checkout intent**     | [[domain\|shopping]]       | Commerce                     | Manage mutable customer baskets and initiate checkout handoff                                               |
| **Order lifecycle management**     | [[domain\|ordering]]       | Commerce, Backoffice         | Record accepted purchases with locked prices and manage `New` → `Completed` / `Cancelled` transitions       |
| **Customer feedback and ratings**  | [[domain\|reviews]]        | Storefront, Backoffice       | Store individual customer ratings and comments in Cosmos DB and publish summary updates to Catalog          |
| **Conversational guidance**        | [[domain\|conversational]] | Storefront                   | Route customer requests through privacy-filtered AI agents for book discovery and policy answers            |
| **Scheduling and notifications**   | [[domain\|platform]]       | Quartz Dashboard (`/quartz`) | Trigger scheduled vector indexing and deliver transactional order emails without owning business state      |

### Five end-to-end customer journeys

- **Discovery and selection:** Shoppers browse and search titles in **Storefront** (`@bookworm/storefront`). Catalog is the single source of truth for book details, pricing, and availability; see [[flow|product-ingestion]] and Search and discovery.
- **Basket and checkout:** Authenticated shoppers manage items in **Commerce** (`@bookworm/commerce`) under `/basket` and submit checkout under `/checkout/*`. Shopping holds temporary intent in Redis, while Ordering validates current Catalog pricing and creates an authoritative `Order`; see [[flow|user-checkout]].
- **Order confirmation and processing:** Ordering manages the accepted order lifecycle, while Finance orchestrates post-checkout basket cleanup and triggers Notification email commands over Kafka; see [[flow|order-lifecycle]] and [[flow|notification-delivery]].
- **Reviews and trust signals:** Shoppers submit ratings and comments to Rating API (`Reviews`), which persists individual `Feedback` records in Cosmos DB and publishes Kafka events so Catalog refreshes its derived `Rating summary`; see [[flow|feedback-publication]].
- **Conversational assistance:** Shoppers ask book discovery or store-policy questions via Storefront's CopilotKit chat runtime (`/ag-ui`), routed by `Microsoft-Decision-1` through read-only MCP tools and remote A2A review analysis; see [[flow|agent-orchestration]].

## Design trade-offs

| Decision                                                  | Benefits                                                                                 | Costs and limits                                                           |
| :-------------------------------------------------------- | :--------------------------------------------------------------------------------------- | :------------------------------------------------------------------------- |
| **Eventually consistent derived views**                   | Catalog browsing stays fast and available even if Reviews or `Catalog Ingestion` is busy | Rating summaries and Qdrant search vectors can briefly trail source writes |
| **Operational delivery separated from business outcomes** | SMTP outages or email retries never corrupt or roll back accepted `Order` records        | Operators must monitor Notification delivery independently of Order status |
| **Capability boundaries over screen-oriented services**   | Teams evolve pricing, checkout, and AI agents independently                              | Cross-context journeys require explicit contracts and Pact verification    |

## Alternatives considered

- **Screen-oriented Backend-for-Frontend (BFF) monolith:** Simplifies initial CRUD screens but merges pre-order baskets, committed orders, and product catalogs into one blast radius.
- **Synchronous cross-domain writes:** Guarantees immediate rating and vector consistency but couples Catalog availability directly to Reviews and Microsoft Foundry latency.

## Related documentation

- [[doc|development/001-developer-onboarding]] — Contributor onboarding and platform introduction.
- [[doc|development/000-local-quickstart]] — Step-by-step tutorial to run BookWorm on your machine.
- [[domain|bookworm]] — Strategic DDD map and deployable services.
- Domain principles and boundaries — Ownership rules and pre-change boundary gate.
