Sofia on Nostr: i wish a matrix client other than nheko supported the mutual rooms MSC lol, synapse ...
i wish a matrix client other than nheko supported the mutual rooms MSC lol, synapse (the most popular server implementation) supports it so if more clients did most people could use it even though it's technically not standard yet
my client definitely will, but until then i just use a tiny script that calls the endpoints directly lol, here it is if anyone is interested (it's a one liner)
{ for room in $(curl --get -H 'Authorization: Bearer token-goes-here' --data-urlencode "user_id=$1"
https://example.com/_matrix/client/unstable/uk.half-shot.msc2666/user/mutual_rooms | jq -r '.joined[]'); do curl -H 'Authorization: Bearer token-goes-here' "
https://example.com/_matrix/client/v3/rooms/$room/state/m.room.name"; | jq -r .name; done; } 2>/dev/null
some info:
rooms without a name, which mainly means dms, will output null (which is fine since you can just assume it's a dm)
the other user's id is the only parameter
instead of example.com you should use the domain your server's API uses (which is *not* necessarily the same as its canonical domain), for example matrix.org's is matrix-client.matrix.org
replace token-goes-here with your actual access token (obviously)
jq and curl are required
Published at
2024-11-17 06:55:31Event JSON
{
"id": "45e284d7ac681fd5c877d53477e4623362b2ff80400ae68959f67ff64c58cf18",
"pubkey": "da3590dad794cc0fe991842a28892024956662e1049a8d0e9f0045cd90afdf28",
"created_at": 1731826531,
"kind": 1,
"tags": [
[
"proxy",
"https://rape.pet/objects/69ecfb95-4fe9-451e-815a-a957bd0c795c",
"activitypub"
]
],
"content": "i wish a matrix client other than nheko supported the mutual rooms MSC lol, synapse (the most popular server implementation) supports it so if more clients did most people could use it even though it's technically not standard yet\n\nmy client definitely will, but until then i just use a tiny script that calls the endpoints directly lol, here it is if anyone is interested (it's a one liner)\n\n{ for room in $(curl --get -H 'Authorization: Bearer token-goes-here' --data-urlencode \"user_id=$1\" https://example.com/_matrix/client/unstable/uk.half-shot.msc2666/user/mutual_rooms | jq -r '.joined[]'); do curl -H 'Authorization: Bearer token-goes-here' \"https://example.com/_matrix/client/v3/rooms/$room/state/m.room.name\" | jq -r .name; done; } 2\u003e/dev/null\n\nsome info:\nrooms without a name, which mainly means dms, will output null (which is fine since you can just assume it's a dm)\n\nthe other user's id is the only parameter\n\ninstead of example.com you should use the domain your server's API uses (which is *not* necessarily the same as its canonical domain), for example matrix.org's is matrix-client.matrix.org\n\nreplace token-goes-here with your actual access token (obviously)\n\njq and curl are required",
"sig": "03095b3132f3b9c622d9710ada20e5164d109a25b9074a75952200539c3b982bf2ab148b7084de7bd7ca53760454c528942c8a325194262e3d0198772f5c15f3"
}