diff options
author | Brendan Abolivier <babolivier@matrix.org> | 2019-12-03 19:19:45 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-12-03 19:19:45 +0000 |
commit | 54dd5dc12b0ac5c48303144c4a73ce3822209488 (patch) | |
tree | 50df8025be2caac9a957a920caf73c0b4c01e392 /synapse/api | |
parent | write some docs for the quarantine_media api (#6458) (diff) | |
download | synapse-54dd5dc12b0ac5c48303144c4a73ce3822209488.tar.xz |
Add ephemeral messages support (MSC2228) (#6409)
Implement part [MSC2228](https://github.com/matrix-org/matrix-doc/pull/2228). The parts that differ are: * the feature is hidden behind a configuration flag (`enable_ephemeral_messages`) * self-destruction doesn't happen for state events * only implement support for the `m.self_destruct_after` field (not the `m.self_destruct` one) * doesn't send synthetic redactions to clients because for this specific case we consider the clients to be able to destroy an event themselves, instead we just censor it (by pruning its JSON) in the database
Diffstat (limited to 'synapse/api')
-rw-r--r-- | synapse/api/constants.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/synapse/api/constants.py b/synapse/api/constants.py index e3f086f1c3..69cef369a5 100644 --- a/synapse/api/constants.py +++ b/synapse/api/constants.py @@ -147,3 +147,7 @@ class EventContentFields(object): # Labels for the event, cf https://github.com/matrix-org/matrix-doc/pull/2326 LABELS = "org.matrix.labels" + + # Timestamp to delete the event after + # cf https://github.com/matrix-org/matrix-doc/pull/2228 + SELF_DESTRUCT_AFTER = "org.matrix.self_destruct_after" |