Fix matrix api joinRoom() for remote rooms #60

Open
Elliu wants to merge 6 commits from Elliu/out-of-your-element:fix-remote-join into main

6 commits

Author SHA1 Message Date
f6c749acca Add "please try invite" message when joinRoom in /api/link-space fails 2025-08-31 20:11:38 +09:00
ecb4ae0315 Fill in more of reg for other people to test with 2025-08-31 19:44:36 +09:00
37da02d13a Fix /api/link-space joinRoom() for remote spaces 2025-08-31 19:44:36 +09:00
74172f3d3d Update tests for new types and code path 2025-08-31 19:44:36 +09:00
af79c96aeb Cleanup 2025-08-31 19:44:36 +09:00
91d62e7b28 Fix matrix api joinRoom() for remote rooms
When using self-service mode and trying to link with a remote matrix
room (room not in the same HS as the bridge user), then we need to add
the "via" HSs to join the room with, or else it fails.

We get it from the "m.space.child" in the "children_state" of the space
hierarchy.

It seems like the "via" information can also be stored in the
"m.space.parent" in the states of the room, but hopefully this shouldn't
be needed in sane implementations
2025-08-31 19:44:36 +09:00