mirror of
https://github.com/matrix-org/matrix-spec
synced 2026-03-25 12:34:10 +01:00
Spec unsigned.membership property, per MSC4115
This commit is contained in:
parent
5a86e384dd
commit
0697c82d41
1
changelogs/client_server/newsfragments/1847.feature
Normal file
1
changelogs/client_server/newsfragments/1847.feature
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
Add the new `unsigned.membership` property to events served over the client-server API, as per [MSC4115](https://github.com/matrix-org/matrix-spec-proposals/pull/4115).
|
||||||
|
|
@ -90,6 +90,7 @@ properties:
|
||||||
"origin_server_ts": 1632491098485,
|
"origin_server_ts": 1632491098485,
|
||||||
"unsigned": {
|
"unsigned": {
|
||||||
"age": 1257,
|
"age": 1257,
|
||||||
|
"membership": "leave"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
transaction_id:
|
transaction_id:
|
||||||
|
|
@ -112,3 +113,20 @@ properties:
|
||||||
this.
|
this.
|
||||||
title: EventContent
|
title: EventContent
|
||||||
type: object
|
type: object
|
||||||
|
membership:
|
||||||
|
description: |
|
||||||
|
The room membership of the user making the request, at the time of the event.
|
||||||
|
|
||||||
|
This property is the value of the `membership` property of the
|
||||||
|
requesting user's [`m.room.member`](#mroommember) state at the point
|
||||||
|
of the event, including any changes caused by the event. If the user
|
||||||
|
had yet to join the room at the time of the event (i.e, they have no
|
||||||
|
`m.room.member` state), this property is set to `leave`.
|
||||||
|
|
||||||
|
It is recommended that homeservers SHOULD populate this property
|
||||||
|
wherever practical, but they MAY omit it if necessary (for example,
|
||||||
|
if calculating the value is expensive, servers might choose to only
|
||||||
|
implement it in encrypted rooms).
|
||||||
|
type: string
|
||||||
|
example: join
|
||||||
|
x-addedInMatrixVersion: "1.11"
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@
|
||||||
"sender": "@example:example.org",
|
"sender": "@example:example.org",
|
||||||
"origin_server_ts": 1432735824653,
|
"origin_server_ts": 1432735824653,
|
||||||
"unsigned": {
|
"unsigned": {
|
||||||
"age": 1234
|
"age": 1234,
|
||||||
|
"membership": "join"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue