archim / product-contract
JSON Schemas of the messages of ArchIM's Product module, for contract tests of the module and its consumers
Requires
- php: ^8.5
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-12-03 19:11:05 UTC
README
The contract of the messages of ArchIM's Product module
(archim/product): a JSON Schema (2020-12) for every message it publishes or accepts from other deployments,
each with its title, description and examples. It contains no code of the module and has no dependencies.
What it provides
schema/public-event/: one schema per public event, named after it (public.product.….json), and the definitions they share.ArchIM\Contract\Product\ProductContract: the directories as constants, so that tests find the schemas wherever the package is installed.
How it is used
Only in tests, so it is required in require-dev: by Product itself, to check what it sends and accepts, and by every
consumer, to check what it reads from Product and sends to it. A schema's relative $ref resolves against its $id
(https://archim.bydomain/schema/product/…), which a validator maps to the schema's own directory.
A schema changes only compatibly (a new optional field); a breaking change is a message with a new name.
Documentation
- Product in the target model: what each message means.
- Public events and the decision on contract packages.
License
Apache License 2.0: see the LICENSE file.