Skip to main content

Inbound Receiving

inbound-receiving is a Supporting bounded context in the warehouse-systems fleet (GitHub org IQVO). It answers one question:

What was announced, when does the truck arrive, and what actually came off it?

It owns the inbound dock workflow up to, and not including, stock placement: the supplier's advance ship notice (ASN), the carrier's booked dock appointment and the counted receipt with the discrepancies found when it closes. It decides nothing about where received goods go: Good lines are handed to inventory-storage as events and stow stays an RF action there (ADR 0003).

Where it sits​

PropertyValue
Subdomain classificationSupporting (ADR 0001)
Tierwms (CloudEvents type prefix com.warehouse.wms.inbound-receiving.*; the fourth wms context after facility-layout, inventory-storage and product-master)
Language / styleGo backend, hexagonal architecture (ports and adapters)
DeployablesFour Go binaries in one image: cmd/api (REST :8080, outbox relay, local-copy consumers), cmd/mcp (read-only MCP :8090, ADR 0005), cmd/inbound-projector and cmd/inbound-reports (analytics read side, admin :8091 and reports :8092, ADR 0006); plus the web/ micro-frontend remote inbound_mfe
Inbound adaptersREST, MCP (Streamable HTTP), two Kafka consumers that feed local copies (known_skus, dock_doors) and the analytics-topic consumer of the projector
Outbound adaptersPostgres, the Kafka outbox relay, and a separate analytical Postgres (ANALYTICS_DATABASE_URL) for the read side
IntegrationKafka CloudEvents 1.0 (structured mode), transactional outbox for publishing to warehouse.inbound-receiving.events and, under the same CloudEvents id, to the internal analytics topic
AuthNone on REST or MCP (fleet-wide revert of 2026-09-11)

:::note Study project Like the rest of the warehouse-systems fleet, this is a personal study project exploring Domain-Driven Design, hexagonal architecture and AI-agent harness engineering. It is not production software and carries no support guarantee. :::

:::info What ships on develop Besides the REST service, develop ships the read-only MCP server (cmd/mcp, ADR 0005), the analytics read side (cmd/inbound-projector and cmd/inbound-reports over a separate analytical database, ADR 0006), the web/ remote inbound_mfe that warehouse-console mounts, one container image (Dockerfile) and the Helm chart charts/inbound-receiving. warehouse-infra deploys all of it on its develop. The pages of this site describe what the code on develop does today. Every edge in the context map is built, except that the dock-appointment source of warehouse-planning moves to dock-scheduling (ADR 0019, stage D). :::

What this context owns​

Three aggregates, each its own consistency boundary (ADR 0002):

  • Asn (identity: ASN number): the supplier's announcement. Lines [{lineNo, sku, expectedQty}], numbered 1..n, unique SKUs. State Registered -> Receiving -> Closed, or Registered -> Cancelled.
  • DockAppointment (identity: appt-<uuid>): a carrier's door window covering one or more ASNs. Owned by dock-scheduling since ADR 0019; here a read-only local copy (Booked / Cancelled) that OpenReceipt validates against. The copy follows dock-scheduling's reschedules and door reassignments (ADR 0020), so a new receipt takes the current door.
  • Receipt (identity: rcpt-<uuid>): the counted receiving of one ASN, opened against a snapshot of the ASN. Per line it counts Good and Damaged units; closing it computes the Short, Over and Damaged discrepancies.

They reference each other by id, never by object. Every aggregate carries a version that starts at 1, grows by one per accepted change and guards the repository write.

It does not own stock or placement (inventory-storage), yard and trailer management, returns, putaway directives, quality inspection and quarantine, supplier master data, purchase orders or EDI parsing (ADR 0001, "Explicitly out of scope").

Where to go next​

Disclaimer

This project is a domain-driven design study. It is not associated with, endorsed by or affiliated with any company, and it uses no company's code, data, logos or trademarks. All names, figures and examples are illustrative or synthetic.