From 36bedb6c6afeb652ac75b72db634dde05af2797f Mon Sep 17 00:00:00 2001 From: babolivier Date: Wed, 20 Oct 2021 11:04:56 +0000 Subject: deploy: 78d5896d19692e4b6cdbf09f807915e6b0929ce5 --- develop/modules/account_validity_callbacks.html | 2 ++ develop/modules/password_auth_provider_callbacks.html | 3 +++ develop/modules/presence_router_callbacks.html | 2 ++ develop/modules/spam_checker_callbacks.html | 11 +++++++++++ develop/modules/third_party_rules_callbacks.html | 4 ++++ 5 files changed, 22 insertions(+) (limited to 'develop/modules') diff --git a/develop/modules/account_validity_callbacks.html b/develop/modules/account_validity_callbacks.html index 1d6d0a734d..0eabf60bb7 100644 --- a/develop/modules/account_validity_callbacks.html +++ b/develop/modules/account_validity_callbacks.html @@ -189,6 +189,7 @@ Synapse instance. Account validity callbacks can be registered using the module register_account_validity_callbacks method.

The available account validity callbacks are:

is_user_expired

+

First introduced in Synapse v1.39.0

async def is_user_expired(user: str) -> Optional[bool]
 

Called when processing any authenticated request (except for logout requests). The module @@ -203,6 +204,7 @@ callback returns None, Synapse falls through to the next one. The v callback that does not return None will be used. If this happens, Synapse will not call any of the subsequent implementations of this callback.

on_user_registration

+

First introduced in Synapse v1.39.0

async def on_user_registration(user: str) -> None
 

Called after successfully registering a user, in case the module needs to perform extra diff --git a/develop/modules/password_auth_provider_callbacks.html b/develop/modules/password_auth_provider_callbacks.html index dbc38dfd12..115ded8534 100644 --- a/develop/modules/password_auth_provider_callbacks.html +++ b/develop/modules/password_auth_provider_callbacks.html @@ -188,6 +188,7 @@ their Synapse installation with an external authentication system. The callbacks registered by using the Module API's register_password_auth_provider_callbacks method.

Callbacks

auth_checkers

+

First introduced in Synapse v1.46.0

 auth_checkers: Dict[Tuple[str,Tuple], Callable]
 

A dict mapping from tuples of a login type identifier (such as m.login.password) and a @@ -223,6 +224,7 @@ optionally a callback). In that case, the return value of that callback will be and subsequent callbacks will not be fired. If every callback returns None, then the authentication fails.

check_3pid_auth

+

First introduced in Synapse v1.46.0

async def check_3pid_auth(
     medium: str, 
     address: str,
@@ -247,6 +249,7 @@ callback that does not return None will be used. If this happens, S
 any of the subsequent implementations of this callback. If every callback return None,
 the authentication is denied.

on_logged_out

+

First introduced in Synapse v1.46.0

async def on_logged_out(
     user_id: str,
     device_id: Optional[str],
diff --git a/develop/modules/presence_router_callbacks.html b/develop/modules/presence_router_callbacks.html
index ff95a5936f..43251d6828 100644
--- a/develop/modules/presence_router_callbacks.html
+++ b/develop/modules/presence_router_callbacks.html
@@ -189,6 +189,7 @@ registered using the module API's register_presence_router_callbacksCallbacks
 

The available presence router callbacks are:

get_users_for_states

+

First introduced in Synapse v1.42.0

async def get_users_for_states(
     state_updates: Iterable["synapse.api.UserPresenceState"],
 ) -> Dict[str, Set["synapse.api.UserPresenceState"]]
@@ -203,6 +204,7 @@ must return a dictionary that maps from Matrix user IDs (which can be local or r
 by the callbacks. If multiple callbacks return a dictionary containing the same key,
 Synapse concatenates the sets associated with this key from each dictionary. 

get_interested_users

+

First introduced in Synapse v1.42.0

async def get_interested_users(
     user_id: str
 ) -> Union[Set[str], "synapse.module_api.PRESENCE_ALL_USERS"]
diff --git a/develop/modules/spam_checker_callbacks.html b/develop/modules/spam_checker_callbacks.html
index f43444d402..2bb382af2a 100644
--- a/develop/modules/spam_checker_callbacks.html
+++ b/develop/modules/spam_checker_callbacks.html
@@ -189,6 +189,7 @@ Synapse instances. Spam checker callbacks can be registered using the module API
 

Callbacks

The available spam checker callbacks are:

check_event_for_spam

+

First introduced in Synapse v1.37.0

async def check_event_for_spam(event: "synapse.events.EventBase") -> Union[bool, str]
 

Called when receiving an event from a client or via federation. The module can return @@ -200,6 +201,7 @@ callback returns False, Synapse falls through to the next one. The callback that does not return False will be used. If this happens, Synapse will not call any of the subsequent implementations of this callback.

user_may_join_room

+

First introduced in Synapse v1.37.0

async def user_may_join_room(user: str, room: str, is_invited: bool) -> bool
 

Called when a user is trying to join a room. The module must return a bool to indicate @@ -214,6 +216,7 @@ callback returns True, Synapse falls through to the next one. The v callback that does not return True will be used. If this happens, Synapse will not call any of the subsequent implementations of this callback.

user_may_invite

+

First introduced in Synapse v1.37.0

async def user_may_invite(inviter: str, invitee: str, room_id: str) -> bool
 

Called when processing an invitation. The module must return a bool indicating whether @@ -224,6 +227,7 @@ callback returns True, Synapse falls through to the next one. The v callback that does not return True will be used. If this happens, Synapse will not call any of the subsequent implementations of this callback.

user_may_send_3pid_invite

+

First introduced in Synapse v1.45.0

async def user_may_send_3pid_invite(
     inviter: str,
     medium: str,
@@ -254,6 +258,7 @@ callback returns True, Synapse falls through to the next one. The v
 callback that does not return True will be used. If this happens, Synapse will not call
 any of the subsequent implementations of this callback.

user_may_create_room

+

First introduced in Synapse v1.37.0

async def user_may_create_room(user: str) -> bool
 

Called when processing a room creation request. The module must return a bool indicating @@ -263,6 +268,7 @@ callback returns True, Synapse falls through to the next one. The v callback that does not return True will be used. If this happens, Synapse will not call any of the subsequent implementations of this callback.

user_may_create_room_with_invites

+

First introduced in Synapse v1.44.0

async def user_may_create_room_with_invites(
     user: str,
     invites: List[str],
@@ -288,6 +294,7 @@ callback returns True, Synapse falls through to the next one. The v
 callback that does not return True will be used. If this happens, Synapse will not call
 any of the subsequent implementations of this callback.

user_may_create_room_alias

+

First introduced in Synapse v1.37.0

async def user_may_create_room_alias(user: str, room_alias: "synapse.types.RoomAlias") -> bool
 

Called when trying to associate an alias with an existing room. The module must return a @@ -298,6 +305,7 @@ callback returns True, Synapse falls through to the next one. The v callback that does not return True will be used. If this happens, Synapse will not call any of the subsequent implementations of this callback.

user_may_publish_room

+

First introduced in Synapse v1.37.0

async def user_may_publish_room(user: str, room_id: str) -> bool
 

Called when trying to publish a room to the homeserver's public rooms directory. The @@ -308,6 +316,7 @@ callback returns True, Synapse falls through to the next one. The v callback that does not return True will be used. If this happens, Synapse will not call any of the subsequent implementations of this callback.

check_username_for_spam

+

First introduced in Synapse v1.37.0

async def check_username_for_spam(user_profile: Dict[str, str]) -> bool
 

Called when computing search results in the user directory. The module must return a @@ -325,6 +334,7 @@ callback returns False, Synapse falls through to the next one. The callback that does not return False will be used. If this happens, Synapse will not call any of the subsequent implementations of this callback.

check_registration_for_spam

+

First introduced in Synapse v1.37.0

async def check_registration_for_spam(
     email_threepid: Optional[dict],
     username: Optional[str],
@@ -351,6 +361,7 @@ The value of the first callback that does not return RegistrationBehaviour
 be used. If this happens, Synapse will not call any of the subsequent implementations of
 this callback.

check_media_file_for_spam

+

First introduced in Synapse v1.37.0

async def check_media_file_for_spam(
     file_wrapper: "synapse.rest.media.v1.media_storage.ReadableFileWrapper",
     file_info: "synapse.rest.media.v1._base.FileInfo",
diff --git a/develop/modules/third_party_rules_callbacks.html b/develop/modules/third_party_rules_callbacks.html
index adf9d398f6..7d9f8f0aac 100644
--- a/develop/modules/third_party_rules_callbacks.html
+++ b/develop/modules/third_party_rules_callbacks.html
@@ -189,6 +189,7 @@ the module API's register_third_party_rules_callbacks method.

Callbacks

The available third party rules callbacks are:

check_event_allowed

+

First introduced in Synapse v1.39.0

async def check_event_allowed(
     event: "synapse.events.EventBase",
     state_events: "synapse.types.StateMap",
@@ -221,6 +222,7 @@ callback returns True, Synapse falls through to the next one. The v
 callback that does not return True will be used. If this happens, Synapse will not call
 any of the subsequent implementations of this callback.

on_create_room

+

First introduced in Synapse v1.39.0

async def on_create_room(
     requester: "synapse.types.Requester",
     request_content: dict,
@@ -240,6 +242,7 @@ room creation will be forbidden as soon as one of the callbacks raises an except
 this happens, Synapse will not call any of the subsequent implementations of this
 callback.

check_threepid_can_be_invited

+

First introduced in Synapse v1.39.0

async def check_threepid_can_be_invited(
     medium: str,
     address: str,
@@ -253,6 +256,7 @@ callback returns True, Synapse falls through to the next one. The v
 callback that does not return True will be used. If this happens, Synapse will not call
 any of the subsequent implementations of this callback.

check_visibility_can_be_modified

+

First introduced in Synapse v1.39.0

async def check_visibility_can_be_modified(
     room_id: str,
     state_events: "synapse.types.StateMap",
-- 
cgit 1.5.1