From 1ab35a0a7825199a2d65e1c5a16524cd45a98721 Mon Sep 17 00:00:00 2001 From: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com> Date: Tue, 10 Jun 2025 11:13:47 +0100 Subject: Mark new module APIs as experimental (#18536) --- docs/modules/media_repository_callbacks.md | 10 ++++++++++ docs/modules/ratelimit_callbacks.md | 5 +++++ docs/modules/spam_checker_callbacks.md | 5 +++++ 3 files changed, 20 insertions(+) (limited to 'docs/modules') diff --git a/docs/modules/media_repository_callbacks.md b/docs/modules/media_repository_callbacks.md index 0cee3384bb..fc37130439 100644 --- a/docs/modules/media_repository_callbacks.md +++ b/docs/modules/media_repository_callbacks.md @@ -14,6 +14,11 @@ _First introduced in Synapse v1.132.0_ async def get_media_config_for_user(user_id: str) -> Optional[JsonDict] ``` +** +Caution: This callback is currently experimental . The method signature or behaviour +may change without notice. +** + Called when processing a request from a client for the [media config endpoint](https://spec.matrix.org/latest/client-server-api/#get_matrixclientv1mediaconfig). @@ -39,6 +44,11 @@ _First introduced in Synapse v1.132.0_ async def is_user_allowed_to_upload_media_of_size(user_id: str, size: int) -> bool ``` +** +Caution: This callback is currently experimental . The method signature or behaviour +may change without notice. +** + Called before media is accepted for upload from a user, in case the module needs to enforce a different limit for the particular user. diff --git a/docs/modules/ratelimit_callbacks.md b/docs/modules/ratelimit_callbacks.md index 3386220e37..30d94024fa 100644 --- a/docs/modules/ratelimit_callbacks.md +++ b/docs/modules/ratelimit_callbacks.md @@ -14,6 +14,11 @@ _First introduced in Synapse v1.132.0_ async def get_ratelimit_override_for_user(user: str, limiter_name: str) -> Optional[synapse.module_api.RatelimitOverride] ``` +** +Caution: This callback is currently experimental . The method signature or behaviour +may change without notice. +** + Called when constructing a ratelimiter of a particular type for a user. The module can return a `messages_per_second` and `burst_count` to be used, or `None` if the default settings are adequate. The user is represented by their Matrix user ID diff --git a/docs/modules/spam_checker_callbacks.md b/docs/modules/spam_checker_callbacks.md index 6dfa2a7b25..39d7cbc000 100644 --- a/docs/modules/spam_checker_callbacks.md +++ b/docs/modules/spam_checker_callbacks.md @@ -254,6 +254,11 @@ _First introduced in Synapse v1.132.0_ async def user_may_send_state_event(user_id: str, room_id: str, event_type: str, state_key: str, content: JsonDict) -> Union["synapse.module_api.NOT_SPAM", "synapse.module_api.errors.Codes"] ``` +** +Caution: This callback is currently experimental . The method signature or behaviour +may change without notice. +** + Called when processing a request to [send state events](https://spec.matrix.org/latest/client-server-api/#put_matrixclientv3roomsroomidstateeventtypestatekey) to a room. The arguments passed to this callback are: -- cgit 1.5.1