Search by

archim / crm-contract

unixslayer

JSON Schemas of the messages of ArchIM's CRM module, for contract tests of the module and its consumers

v0.1.0 2026-12-03 19:05 UTC

This package is auto-updated.

Last update: 2026-12-03 19:10:52 UTC


README

The contract of the messages of ArchIM's CRM module (archim/crm): 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.crm.….json), and the definitions they share.
  • ArchIM\Contract\Crm\CrmContract: 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 CRM itself, to check what it sends and accepts, and by every consumer, to check what it reads from CRM and sends to it. A schema's relative $ref resolves against its $id (https://archim.bydomain/schema/crm/…), 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

License

Apache License 2.0: see the LICENSE file.