Application service API - Transaction endpoint
-
/_matrix/app/v1/transactions/{txnId}
Method: PUT
Use case: Allow Matrix homeserver to send event to be proccessed by the Twake backend
Implementation: If Matrix homeserver received any event which is adressed to one of the rooms listed in yaml configuration file, then it is the application server which will handle it and not the Matrix homeserver. To redirect events, Matrix homeserver will use this endpoint. Then application server should know how to handle any type of room events. For our use case maybe we can restrict this list of events to:- m.room.create: application server will store the room in the database connected to the Matrix homeserver
- m.room.join_rules: use case is for
restrict
(maybeprivate
) room so the application server will associate a rule based on m.room.membership, user should belongs to one or several specific rooms to join the room created with application server. This rule will be store in Matrix homeserver database - m.room.member: application server will check that the user in the request body verified the rule associated to the room, if it is the case then the user is allowed to join the room
- m.room.message: application server should handle messages write on this channel (seems to be an heavy task)
Edited by Jordy CABANNES