Storefront has been decoupled into micro-frontends with a dedicated commerce app and shared shell.

Read the architecture guide →

ADR-005: Authenticate and govern MCP requests

The MCP endpoint requires an authenticated caller with the read scope and applies authorization filters and default-deny tool governance.

November 4, 2026AcceptedSecurity

1. Context & Problem

The shared AI integration boundary exposes CatalogDomainv1.0.0CatalogCore BookWorm subdomain that makes books discoverable, purchasable, and consistently described across the customer journ...Ownercatalog-experience-teamDiagramOpen docs and ReviewsDomainv1.0.0ReviewsCaptures individual customer feedback for books, publishes rating changes for Catalog discovery, and provides privacy-sc...Ownercatalog-experience-teamDiagramOpen docs data to multiple internal AI clients. Because this capability is reachable over the network, it needs both caller identity verification and an explicit server-side permission boundary so a client cannot run capabilities simply because they exist on the server.

Relying only on which tools a client application chooses to load is not an adequate security control. A client could be misconfigured, or a caller could attempt to invoke a capability directly after discovering what the server offers.

2. Business Value

  • Defense in depth: Prevents unauthorized callers or misconfigured AI clients from invoking capabilities they should not access.
  • Least-privilege access: Ensures AI applications can only discover and run approved read-only capabilities aligned with their role.
  • Safer growth: Allows new AI clients and capabilities to be introduced without relying on implicit network trust.
  • Clear accountability: Separates identity verification and policy enforcement failures from upstream catalog or review data issues.

3. How It Works

Every incoming request to MCP ServerServicev1.0.0MCP ServerInternal stateless Streamable HTTP MCP service that exposes read-only Catalog lookup tools and reusable AI prompts. PublishesListBooksGrpc, GetBookDetailsGrpc +2Ownerai-capabilities-teamDiagramRepositoryOpen docs passes through a strict two-layer security boundary before any book or review data is accessed:

  1. Caller authentication and read permission check: Callers must present valid credentials verified through Identity ProviderSystemv1.0.0Identity ProviderExternal identity infrastructure that authenticates BookWorm users and provides OAuth-compatible identity verification f...Ownerplatform-engineering-teamDiagramOpen docs showing they are authorized to read MCP capabilities. Internal consumers such as Chat APIServicev1.0.0Chat APIInternal HTTP host for BookWorm's interactive multi-agent chat workflow, agent discovery, and session persistence. Ownerai-capabilities-teamDiagramRepositoryOpen docs and Rating APIServicev1.0.0Rating APIInternal HTTP and A2A gRPC service for collecting, listing, deleting, and summarizing customer feedback for Catalog book...PublishesFeedbackCreatedIntegrationEvent, FeedbackDeletedIntegrationEventSubscribesCreateFeedback, DeleteFeedback +3APIsOpenAPI, AsyncAPIOwnercatalog-experience-teamDiagramRepositoryOpen docs obtain these credentials using service-to-service credential exchange.
  2. Server-side capability governance: Even after a caller is authenticated, the server enforces a default-deny policy on tool invocations. Only explicitly approved tool categories are permitted, and unsafe tool patterns are blocked at the server boundary.

Client applications still configure which subset of tools they intend to use, while capability discovery only advertises what exists—it never grants permission to run a tool.

4. Trade-offs & Lessons Learned

  • Availability and latency dependency: Token verification and governance checks are now on the critical path for every AI tool call. Operations teams must monitor authentication and policy failures separately from upstream CatalogDomainv1.0.0CatalogCore BookWorm subdomain that makes books discoverable, purchasable, and consistently described across the customer journ...Ownercatalog-experience-teamDiagramOpen docs and ReviewsDomainv1.0.0ReviewsCaptures individual customer feedback for books, publishes rating changes for Catalog discovery, and provides privacy-sc...Ownercatalog-experience-teamDiagramOpen docs API health.
  • Onboarding and review overhead: New AI clients cannot connect immediately; they must first be provisioned with service authentication and read permissions. Whenever tools or categories change, server allow rules and client tool configurations must be reviewed together.
  • Rejected alternatives:
    • Allowing unauthenticated internal-network access: Network placement alone does not identify who is calling or limit which tools can be run.
    • Relying only on client-side tool declarations: Client configuration controls intended usage, not server enforcement against misconfiguration or direct calls.
    • Allowing every authenticated caller to run all tools: Proving identity does not mean every caller should have unrestricted access to every capability.

5. Technical Reference