From 8003cb297722262cb65d9065261aa769ce7e3746 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 6 Sep 2025 18:11:17 +0000 Subject: [PATCH 1/3] Update README.md --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 1eebec2..8348497 100644 --- a/README.md +++ b/README.md @@ -261,13 +261,13 @@ Placeholders can be added by setting `VARIABLES` inside your Environment. ```yaml environment: VARIABLES: | - "NUMBER2": "002", - "GROUP_CHAT_1": [ - "user.id", - "000", - "001", - "group.id" - ] + "NUMBER2": "002", + "GROUP_CHAT_1": [ + "user.id", + "000", + "001", + "group.id" + ] ``` ### Recipients From 68ea8fac7f50fe6373fa28b0010ba5630fc90fc3 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 6 Sep 2025 18:14:15 +0000 Subject: [PATCH 2/3] Update README.md --- README.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 8348497..432b506 100644 --- a/README.md +++ b/README.md @@ -263,10 +263,7 @@ environment: VARIABLES: | "NUMBER2": "002", "GROUP_CHAT_1": [ - "user.id", - "000", - "001", - "group.id" + "user.id", "000", "001", "group.id" ] ``` @@ -310,7 +307,11 @@ Message Aliases can be added by setting `MESSAGE_ALIASES`: ```yaml environment: - MESSAGE_ALIASES: ' [{ "alias": "note", "priority": 4 }, { "alias": "test", "priority": 3 }] ' + MESSAGE_ALIASES: | + [ + { "alias": "note", "priority": 4 }, + { "alias": "test", "priority": 3 } + ] ``` ## Contributing From 63c9309c00b3fb7cf508d712ebb0a9577947912a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 7 Sep 2025 16:23:04 +0000 Subject: [PATCH 3/3] Update README.md --- README.md | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index 432b506..77cb37a 100644 --- a/README.md +++ b/README.md @@ -289,28 +289,29 @@ example: To improve compatibility with other services Secured Signal API provides aliases for the `message` attribute by default: -| Alias | Priority | -| ----------- | -------- | -| msg | 100 | -| content | 99 | -| description | 98 | -| text | 20 | -| body | 15 | -| summary | 10 | -| details | 9 | -| payload | 2 | -| data | 1 | - -Secured Signal API will use the highest priority Message Alias to extract the correct message from the Request Body. - -Message Aliases can be added by setting `MESSAGE_ALIASES`: +| Alias | Score | +| ----------- | ----- | +| msg | 100 | +| content | 99 | +| description | 98 | +| text | 20 | +| body | 15 | +| summary | 10 | +| details | 9 | +| payload | 2 | +| data | 1 | + +Secured Signal API will pick the best scoring Message Alias (if available) to extract the correct message from the Request Body. + +Message Aliases can be added by setting `MESSAGE_ALIASES` to a valid json array containing dictionaries of `alias`, the json key to be used for lookup (use `.` dots for using values from a nested dictionary and `[i]` to get values from an array): ```yaml environment: MESSAGE_ALIASES: | [ - { "alias": "note", "priority": 4 }, - { "alias": "test", "priority": 3 } + { "alias": "msg", "score": 80 }, + { "alias": "data.message", "score": 79 }, + { "alias": "array[0].message", "score": 78 }, ] ```