Allow sending ephemeral data to application services (#2018)
As per MSC2409. Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
This commit is contained in:
parent
846cc49eb2
commit
96b32f68f9
4 changed files with 65 additions and 0 deletions
|
@ -32,6 +32,13 @@ properties:
|
|||
description: |-
|
||||
The localpart of the user associated with the application service. Events will be sent to the AS if this user is the target of the event, or
|
||||
is a joined member of the room where the event occurred.
|
||||
receive_ephemeral:
|
||||
type: boolean
|
||||
x-addedInMatrixVersion: "1.13"
|
||||
description: |-
|
||||
Whether the application service wants to [receive ephemeral data](/application-service-api/#pushing-ephemeral-data).
|
||||
|
||||
Defaults to `false` if not present.
|
||||
namespaces:
|
||||
type: object
|
||||
title: Namespaces
|
||||
|
|
|
@ -46,6 +46,15 @@ paths:
|
|||
schema:
|
||||
type: object
|
||||
example: {
|
||||
"ephemeral": [
|
||||
{
|
||||
"$ref": "../../event-schemas/examples/m.receipt.yaml",
|
||||
"room_id": "!jEsUZKDJdhlrceRyVU:example.org"
|
||||
},
|
||||
{
|
||||
"$ref": "../../event-schemas/examples/m.presence.yaml"
|
||||
},
|
||||
],
|
||||
"events": [
|
||||
{
|
||||
"$ref": "../../event-schemas/examples/m.room.member.yaml"
|
||||
|
@ -61,6 +70,21 @@ paths:
|
|||
description: A list of events, formatted as per the Client-Server API.
|
||||
items:
|
||||
$ref: ../client-server/definitions/client_event.yaml
|
||||
ephemeral:
|
||||
type: array
|
||||
x-addedInMatrixVersion: "1.13"
|
||||
description: |-
|
||||
A list of ephemeral data, if the `receive_ephemeral` setting was enabled in the
|
||||
[registration](/application-service-api/#registration) file.
|
||||
|
||||
There are only three event types that can currently occur in this list: `m.presence`,
|
||||
`m.typing`, and `m.receipt`. Room-scoped ephemeral data (`m.typing` and
|
||||
`m.receipt`) MUST include a `room_id` property to identify the room that they
|
||||
were sent in.
|
||||
|
||||
This property can be omitted if it would be empty.
|
||||
items:
|
||||
$ref: ../../event-schemas/schema/core-event-schema/event.yaml
|
||||
required:
|
||||
- events
|
||||
description: Transaction information
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue