diff options
author | Andrew Morgan <1342360+anoadragon453@users.noreply.github.com> | 2022-02-01 14:13:38 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-01 14:13:38 +0000 |
commit | 64ec45fc1b0856dc7daacca7d3ab75d50bd89f84 (patch) | |
tree | 84b2a6733967600b468a72785da19f43a9b40299 /synapse/appservice/__init__.py | |
parent | Don't mention 3.6 EOL under misc (diff) | |
download | synapse-64ec45fc1b0856dc7daacca7d3ab75d50bd89f84.tar.xz |
Send to-device messages to application services (#11215)
Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
Diffstat (limited to 'synapse/appservice/__init__.py')
-rw-r--r-- | synapse/appservice/__init__.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/synapse/appservice/__init__.py b/synapse/appservice/__init__.py index 8c9ff93b2c..7dbebd97b5 100644 --- a/synapse/appservice/__init__.py +++ b/synapse/appservice/__init__.py @@ -351,11 +351,13 @@ class AppServiceTransaction: id: int, events: List[EventBase], ephemeral: List[JsonDict], + to_device_messages: List[JsonDict], ): self.service = service self.id = id self.events = events self.ephemeral = ephemeral + self.to_device_messages = to_device_messages async def send(self, as_api: "ApplicationServiceApi") -> bool: """Sends this transaction using the provided AS API interface. @@ -369,6 +371,7 @@ class AppServiceTransaction: service=self.service, events=self.events, ephemeral=self.ephemeral, + to_device_messages=self.to_device_messages, txn_id=self.id, ) |