Disable / turn off direct messages #7073
Comments
Yes, you can do this by forbidding users on the server to issue invites; only to join rooms. The antispam module API in synapse has a can_invite hook which you can return false in. |
Brilliant - thank you very much. |
@george-angel Can you describe how you did that? Did @ara4n mean "block_invites:true" in mjolnir.AntiSpam or something else? |
@Chatcloud we didn't end up using this, but looking through past commits this is the code used in the PoC: spam.py:
|
@Chatcloud - I have used a similar variation of the above spam file as well, but in our case we preferred to set "create_room" to false for non-admin users as this would prevent a DM from being created as well (a DM is effectively a room with only 2 people in it). This would mean that users can still invite other users to a room they are members in, BUT the caveat is that your admins will have to then create/manage the rooms and their members directly. |
@phewitt-uw that sounds good. Thank you! |
Description:
Hello, we have a rather specific use-case where we would like to use matrix internally for teams in the company, but we would like to only allow room conversations, no direct messages (apart from few select members may be).
Is this at all possible? Happy to hear any hacky solution you might have.
Currently we are looking to use Slack and to drop packages on the firewall where URI matches structures of a DM.
So yes, you could say we are flexible.
The text was updated successfully, but these errors were encountered: