Add template and generated artifact contracts
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
# Template And Generated Artifact Capability Contracts
|
||||
|
||||
Core defines provider-neutral contracts for optional template libraries and
|
||||
generated artifact storage. Core does not render templates or store generated
|
||||
files itself.
|
||||
|
||||
## Templates
|
||||
|
||||
- `templates.catalog` lists typed, versioned template references and checks a
|
||||
consumer's available fields, usage, and output format.
|
||||
- `templates.renderer` accepts a `TemplateRenderRequest` containing pinned
|
||||
input data and returns immutable render evidence plus an artifact reference.
|
||||
|
||||
The DTOs contain identifiers, hashes, plain mappings, and scalar metadata. They
|
||||
do not expose Template ORM models or require Campaign, Distribution Lists,
|
||||
Addresses, Reporting, Forms, or Mail.
|
||||
|
||||
## Generated Artifacts
|
||||
|
||||
`files.artifact_store` accepts a `ManagedArtifactWriteRequest` and returns a
|
||||
`ManagedArtifactRef`. Producers supply bytes, a safe filename/content type,
|
||||
idempotency key, and non-secret provenance. Files owns path normalization,
|
||||
authorization, versions, storage, and download behavior.
|
||||
|
||||
Consumers must discover both contracts through the module registry and degrade
|
||||
only the unavailable path. A template renderer may return a bounded download
|
||||
when Files is absent. A caller must not infer successful external delivery from
|
||||
successful rendering or artifact persistence.
|
||||
Reference in New Issue
Block a user