feat(templates): add localized push templates and actions

Share template keys across email and push with independent editors and revisions. Render localized actions and preserve version-one delivery.

Ref: IT-1627
This commit is contained in:
2026-10-31 09:38:05 +02:00
parent d4ee8fc0c8
commit aba4173827
79 changed files with 3906 additions and 104 deletions
+23
View File
@@ -1,5 +1,14 @@
# Supported incoming message types
Current push version selection (owner decision 2026-10-31): the AMQP type remains
Notification.SendPush.v1. Its data.version defaults to 1 when omitted. Version 1
retains title/body, optional route defaulting to /home, and the original identity,
token and expiry validation; no template fields are required. Explicit version 2
requires templateKey/languageCode/templateData and renders buttons. Unknown versions
are rejected with an unsupported-version error. Version 1 emits version=1/route=/home
to FCM; version 2 emits version=2/actions. The historical no-legacy note below is
superseded by this decision. See channel-template-model.md for the current contract.
The Worker uses `SupportedMessageType` for its two incoming commands:
| AMQP MessageType (unchanged) | Public enum | Consumer queue |
@@ -24,3 +33,17 @@ correlation validation remains unchanged.
The Push Channels change removes the draft Firebase project/access-token fields from
SendPushMessageData. The enum and AMQP header stay unchanged; see
[push channels](android-push.md) for producer compatibility and rollout order.
## New templated push payload (IT-1627, owner decision 2026-10-31)
The push command now supplies templateKey, languageCode and templateData with
bindings and action metadata, replacing ready-made title/body/route. No legacy
payload acceptance branch is provided. Action keys are consumer-owned, with only
objectId in their metadata; labels are localized in the template. See
[channel templates](channel-template-model.md#push-template-actions-and-rendering--2026-10-31)
for the exact shape, validation and client integration still required.
Version-selection regression coverage: omitted/explicit version 1 legacy input and
its original FCM fields, explicit version 2 section buttons, unknown-version errors,
and both channel test modes passed. See channel-template-model.md for runtime and
review evidence and the remaining installed-client validation gap.