Checkout
Derived from model/model.yaml. The checkout service is built on develop (IQVO/checkout at 51e0379, checked 2026-12-02), released at v0.1.4 and applied to the k3s cluster: the api and the A2A agent are deployed, the MCP server is registered in warehouse-infra and switched off. Every Err... name, REST route and CloudEvents type of this context named on this page exists in the service; where the built service differs from the model's design, the page says so (As built) or the context's Service and operations section lists it.
Checkout (checkout, code CK, tier storefront) is the purchase
saga: one transaction across price, payment and the network's promise
confirmation. Its single aggregate, CheckoutSession, walks from review to
placed order. The saga authorizes the payment first (compensatable: it can be
voided), then places the order (the pivot), then leaves the retriable steps to
events. While the place-order outcome is unknown the session sits in
PLACING, the semantic lock: there is no void and no new attempt until a
definitive answer arrives. The place-order step reaches the network's
customer-ordering through an Anti-Corruption Layer, the only place that
knows the network's wire names. The context holds a shopperId and a
shipToAddressId reference and never PII; its stored placement request is
PII-free, so it can be replayed byte for byte with the same
Idempotency-Key.
This context's pages
| Page | What it holds | ddd-crew tool it follows |
|---|---|---|
| Business Context | The problem, actors, decisions, relation to real storefronts, out of scope | (narrative) |
| Ubiquitous Language | Terms, code identifiers, terms not to confuse | Bounded Context Canvas (UL section) |
| Core Domain Chart | Why this context is Supporting | Core Domain Charts |
| Bounded Context Canvas | Purpose, classification, roles, inbound and outbound messages, decisions, metrics | Bounded Context Canvas v5 |
| Context Map | Every neighbour, direction and pattern | Context Mapping |
| Aggregate Design Canvas | CheckoutSession: states, invariants, commands | Aggregate Design Canvas v1.1 |
| Domain Events | Published CloudEvents, with an example envelope | Domain Message Flow Modelling (message catalogue) |
| Domain Message Flow | The happy path, a decline, a requote, an in-doubt placement | Domain Message Flow Modelling |
| EventStorming | Process-level boards with hotspots | EventStorming glossary & cheat sheet |
| Use Cases | One section per command: trigger, flow, errors, events, idempotency | (application layer, fleet convention) |
| Class Diagram | Domain model and hexagonal ports and adapters (the model's design, with the as-built packages) | (UML, fleet convention) |
| Entity Relationship | Postgres schema as built (migration 0001) | (fleet convention) |
| Sequence Diagrams | Adapter to Kafka for every command use case | (UML, fleet convention) |
Service and operations
- Service:
IQVO/checkoutondevelop(51e0379, checked 2026-12-02): binariescmd/api,cmd/mcp,cmd/a2a; REST contractapis/openapi.yaml, event contractapis/asyncapi.yaml, schema ininternal/adapters/outbound/postgres/migrations/(see Entity Relationship). 11 ADRs (0001 to 0011), listed in the ADR index. - Configuration: mandatory at boot (the service exits naming the missing variable):
DATABASE_URL,KAFKA_BROKERS,SHOPPING_CART_URL,DELIVERY_PROMISE_URL,PRICING_URL,CUSTOMER_PAYMENTS_URL,CUSTOMER_ORDERING_URL. There is no in-memory mode. Packaging: the Helm chartcharts/checkout(ondevelopand in v0.1.4) renders the api and, both default off, anmcpand ana2acomponent with their own Services, routes and probes. - Deployment: released at v0.1.4 (tag commit
74b552b, which carriescmd/api,cmd/mcp,cmd/a2aand the chart) and applied to the k3s cluster: warehouse-infradevelop(d12d05f, checked 2026-12-02) registers checkout interraform/apps.yaml(with a database) and configures it inhelm-values/checkout.yaml, with a dashboard and alert rules. REST goes through Kong at/api/checkout; the five sibling URLs point at the in-cluster services. The A2A agent is switched on (a2a.enabled: true) behind the route/api/a2a/checkoutthrough the Agent Router (Envoy Gatewayagent-router, warehouse-infra ADR 0014). The api and a2a pods were checked 2026-12-02 (1/1 each). The MCP server is not deployed: see MCP. - Observability: service ADR 0006, Adopt the fleet observability standard (logs, metrics, traces), Accepted (2026-10-26). Logs, metrics and traces leave over OTLP/gRPC (
OTEL_EXPORTER_OTLP_ENDPOINT, code defaultlocalhost:4317;OTEL_SERVICE_NAME); a collector that is down only drops telemetry. The Tier-2 business counter ischeckout.sessions.confirmed(unit{session}, ininternal/adapters/outbound/telemetry/session_metrics.go), with attributeoutcome=completed,declined,requote-required,failed,in-doubtorrefusedandreasonon the outcomes that are not a success. The warehouse-infra dashboardterraform/dashboards/contexts/checkout.jsonshows the gateway, the logs and the Go runtime; it does not query the counter. - MCP:
cmd/mcpis a read-only MCP server (service ADR 0005, A read-only MCP server, Accepted 2026-10-25): the official Go SDK over Streamable HTTP only,MCP_ADDR(default:8090),/mcpand an open/healthz, no auth (the in-cluster boundary is the access control). One tool,get_checkout_session: L1 inform (reads, changes nothing: the tool declaresreadOnlyHint,idempotentHintand a closedopenWorldHint, and no_metaauthority, so its level is read from the hint). It mirrorsGET /checkout-sessions/{sessionId}through the sameGetSessionuse case and returns the session's state, lines, shipment groups, binding total,authorizationId,orderId, re-quoted offers and failure code; opening and confirming a session have no tool. The chart'smcpcomponent (port 8090, route/api/mcp/checkoutthrough the Agent Router, rewritten to/mcp) is default off andhelm-values/checkout.yamlsets nomcpblock: the MCP server is registered in warehouse-infra and switched off, so it is not deployed. The repo pins notool_registry.golden.json; the tool is read frominternal/adapters/inbound/mcp/tools.go. - A2A:
cmd/a2ais a read-only A2A agent (service ADR 0007, A2A inbound adapter, Accepted 2026-10-30; first commitaa5248c): the official A2A Go SDK, JSON-RPC 2.0 over HTTP,A2A_ADDR(default:8093),A2A_AGENT_URLmandatory (the absolute URL the Agent Card advertises), the card at/.well-known/agent-card.jsonwithnamecheckout,versionfromSERVICE_VERSION, providerIQVO,streaming: falseand no security schemes; no auth. One skill,checkout_session_status(Where does a checkout session stand, L1 inform): the goal-shaped form ofget_checkout_session, answering a session's state and references through the sameGetSessionuse case; it persists nothing, and an unknownsessionIdanswers a 404 problem. A2A is delegation only: facts still travel as CloudEvents on Kafka, and the agent holds no write use case and no outbound client. Route/api/a2a/checkoutthrough the Agent Router (rewritten to/),a2a.enabled: truein warehouse-infra; applied to the k3s cluster, thecheckout-a2apod checked 2026-12-02.
Elsewhere
- REST contract:
storefront/apis/checkout/openapi.yaml(a copy of the service's spec on develop), rendered under the API reference. - The storefront-wide Context Map, Subdomain Classification and Ubiquitous Language.
- The Model Gap Register
tracks gap S1 (checkout numbers lines 1..n and groups by the quote's
groupNo), gap S2 (the binding total is the session'sPriceQuote), gap S3 (requote after authorization: pre-check, then void andREQUOTE_REQUIRED) and gap S4 (event order across topics, whichcustomer-paymentsparks and applies onCheckoutCompleted). - customer-ordering is the network
context behind the place-order step;
delivery-promise owns the offers the
session pre-checks. shopping-cart
supplies the cart the session opens from and closes it on
CheckoutCompleted; pricing issues the binding quote;customer-paymentsauthorizes, voids and later binds the order.