Skip to content

Commit

Permalink
Add a .m.rule.tombstone default push rule for room upgrades
Browse files Browse the repository at this point in the history
As per [MSC1930](#1930)

There are no known changes to this proposal since it was accepted.
  • Loading branch information
turt2live committed May 24, 2019
1 parent 415212c commit ceaccff
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 2 deletions.
1 change: 1 addition & 0 deletions changelogs/client_server/newsfragments/2020.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add a ``.m.rule.tombstone`` default push rule for room ugprade notifications.
35 changes: 33 additions & 2 deletions specification/modules/push.rst
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ notification is delivered for a matching event. The following actions are define
This prevents each matching event from generating a notification
``coalesce``
This enables notifications for matching events but activates homeserver
specific behaviour to intelligently coalesce multiple events into a single
specific behaviour to intelligently coalesce multiple events into a single
notification. Not all homeservers may support this. Those that do not support
it should treat it as the ``notify`` action.
``set_tweak``
Expand Down Expand Up @@ -369,6 +369,37 @@ Definition:
}
``.m.rule.tombstone``
`````````````````````
Matches any event whose type is ``m.room.tombstone``. This is intended
to notify users of a room when it is upgraded, similar to what an
``@room`` notification would accomplish.

Definition:

.. code:: json
{
"rule_id": ".m.rule.tombstone",
"default": true,
"enabled": true,
"conditions": [
{
"kind": "event_match",
"key": "type",
"pattern": "m.room.tombstone"
}
],
"actions": [
"notify",
{
"set_tweak": "highlight",
"value": true
}
]
}
``.m.rule.roomnotif``
`````````````````````
Matches any message whose content is unencrypted and contains the
Expand Down Expand Up @@ -599,7 +630,7 @@ Definition:
Conditions
++++++++++

Override, Underride and Default Rules MAY have a list of 'conditions'.
Override, Underride and Default Rules MAY have a list of 'conditions'.
All conditions must hold true for an event in order to apply the ``action`` for
the event. A rule with no conditions always matches. Room, Sender, User and
Content rules do not have conditions in the same way, but instead have
Expand Down

0 comments on commit ceaccff

Please sign in to comment.