mirror of
https://github.com/element-hq/synapse.git
synced 2026-01-11 19:56:31 +00:00
Replace manual notes in documentation with admonitions
As they're generally prettier. Requires https://github.com/element-hq/synapse/pull/19356
This commit is contained in:
parent
e660cf2cc4
commit
d3045cd480
27 changed files with 171 additions and 138 deletions
|
|
@ -1,6 +1,7 @@
|
|||
# Account validity API
|
||||
|
||||
**Note:** This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
> [!NOTE]
|
||||
> This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
|
||||
This API allows a server administrator to manage the validity of an account. To
|
||||
use it, you must enable the account validity feature (under
|
||||
|
|
|
|||
|
|
@ -22,8 +22,9 @@ To receive soft failed events in APIs like `/sync` and `/messages`, set `return_
|
|||
to `true` in the admin client config. When `false`, the normal behaviour of these endpoints is to
|
||||
exclude soft failed events.
|
||||
|
||||
**Note**: If the policy server flagged the event as spam and that caused soft failure, that will be indicated
|
||||
in the event's `unsigned` content like so:
|
||||
> [!NOTE]
|
||||
> If the policy server flagged the event as spam and that caused soft failure, that will be indicated
|
||||
> in the event's `unsigned` content like so:
|
||||
|
||||
```json
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
# Shared-Secret Registration
|
||||
|
||||
**Note:** This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
> [!NOTE]
|
||||
> This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
|
||||
This API allows for the creation of users in an administrative and
|
||||
non-interactive way. This is generally used for bootstrapping a Synapse
|
||||
|
|
|
|||
|
|
@ -703,7 +703,8 @@ The parameters and response values have the same format as
|
|||
|
||||
## Version 2 (new version)
|
||||
|
||||
**Note**: This API is new, experimental and "subject to change".
|
||||
> [!NOTE]
|
||||
> This API is new, experimental and "subject to change".
|
||||
|
||||
This version works asynchronously, meaning you get the response from server immediately
|
||||
while the server works on that task in background. You can then request the status of the action
|
||||
|
|
@ -770,7 +771,8 @@ The JSON body must not be empty. The body must be at least `{}`.
|
|||
|
||||
## Status of deleting rooms
|
||||
|
||||
**Note**: This API is new, experimental and "subject to change".
|
||||
> [!NOTE]
|
||||
> This API is new, experimental and "subject to change".
|
||||
|
||||
It is possible to query the status of the background task for deleting rooms.
|
||||
The status can be queried up to 24 hours after completion of the task,
|
||||
|
|
@ -883,8 +885,9 @@ The following fields are returned in the JSON response body:
|
|||
- `error` - A string that shows an error message if `status` is `failed`.
|
||||
Otherwise this field is hidden.
|
||||
- `shutdown_room` - An object containing information about the result of shutting down the room.
|
||||
*Note:* The result is shown after removing the room members.
|
||||
The delete process can still be running. Please pay attention to the `status`.
|
||||
> [!NOTE]
|
||||
> The result is shown after removing the room members.
|
||||
> The delete process can still be running. Please pay attention to the `status`.
|
||||
- `kicked_users` - An array of users (`user_id`) that were kicked.
|
||||
- `failed_to_kick_users` - An array of users (`user_id`) that that were not kicked.
|
||||
- `local_aliases` - An array of strings representing the local aliases that were
|
||||
|
|
@ -894,8 +897,9 @@ The following fields are returned in the JSON response body:
|
|||
|
||||
## Undoing room deletions
|
||||
|
||||
*Note*: This guide may be outdated by the time you read it. By nature of room deletions being performed at the database level,
|
||||
the structure can and does change without notice.
|
||||
> [!NOTE]
|
||||
> This guide may be outdated by the time you read it. By nature of room deletions being performed at the database level,
|
||||
> the structure can and does change without notice.
|
||||
|
||||
First, it's important to understand that a room deletion is very destructive. Undoing a deletion is not as simple as pretending it
|
||||
never happened - work has to be done to move forward instead of resetting the past. In fact, in some cases it might not be possible
|
||||
|
|
@ -978,9 +982,10 @@ A response as follows will be returned:
|
|||
|
||||
## Deleting forward extremities
|
||||
|
||||
**WARNING**: Please ensure you know what you're doing and have read
|
||||
the related issue [#1760](https://github.com/matrix-org/synapse/issues/1760).
|
||||
Under no situations should this API be executed as an automated maintenance task!
|
||||
> [!WARNING]
|
||||
> Please ensure you know what you're doing and have read
|
||||
> the related issue [#1760](https://github.com/matrix-org/synapse/issues/1760).
|
||||
> Under no situations should this API be executed as an automated maintenance task!
|
||||
|
||||
If a room has lots of forward extremities, the extra can be
|
||||
deleted as follows:
|
||||
|
|
|
|||
|
|
@ -92,9 +92,10 @@ This does not include the size of any associated media associated with the room.
|
|||
|
||||
Returns an error on SQLite.
|
||||
|
||||
*Note:* This uses the planner statistics from PostgreSQL to do the estimates,
|
||||
which means that the returned information can vary widely from reality. However,
|
||||
it should be enough to get a rough idea of where database disk space is going.
|
||||
> [!NOTE]
|
||||
> This uses the planner statistics from PostgreSQL to do the estimates,
|
||||
> which means that the returned information can vary widely from reality. However,
|
||||
> it should be enough to get a rough idea of where database disk space is going.
|
||||
|
||||
|
||||
The API is:
|
||||
|
|
|
|||
|
|
@ -137,8 +137,9 @@ Body parameters:
|
|||
- `address` - **string**, required. The third-party ID itself, e.g. `alice@example.com` for `email` or
|
||||
`447470274584` (for a phone number with country code "44") and `19254857364` (for a phone number
|
||||
with country code "1") for `msisdn`.
|
||||
Note: If a threepid is removed from a user via this option, Synapse will also attempt to remove
|
||||
that threepid from any identity servers it is aware has a binding for it.
|
||||
> [!NOTE]
|
||||
> If a threepid is removed from a user via this option, Synapse will also attempt to remove
|
||||
> that threepid from any identity servers it is aware has a binding for it.
|
||||
- `external_ids` - **array**, optional. Allow setting the identifier of the external identity
|
||||
provider for SSO (Single sign-on). More details are in the configuration manual under the
|
||||
sections [sso](../usage/configuration/config_documentation.md#sso) and [oidc_providers](../usage/configuration/config_documentation.md#oidc_providers).
|
||||
|
|
@ -151,15 +152,14 @@ Body parameters:
|
|||
granting them access to the Admin API, among other things.
|
||||
- `deactivated` - **bool**, optional. If unspecified, deactivation state will be left unchanged.
|
||||
|
||||
Note:
|
||||
- For the password field there is no strict check of the necessity for its presence.
|
||||
It is possible to have active users without a password, e.g. when authenticating with OIDC is configured.
|
||||
You must check yourself whether a password is required when reactivating a user or not.
|
||||
- It is not possible to set a password if the config option `password_config.localdb_enabled` is set `false`.
|
||||
Users' passwords are wiped upon account deactivation, hence the need to set a new one here.
|
||||
|
||||
Note: a user cannot be erased with this API. For more details on
|
||||
deactivating and erasing users see [Deactivate Account](#deactivate-account).
|
||||
> [!NOTE]
|
||||
> - For the password field there is no strict check of the necessity for its presence.
|
||||
> It is possible to have active users without a password, e.g. when authenticating with OIDC is configured.
|
||||
> You must check yourself whether a password is required when reactivating a user or not.
|
||||
> - It is not possible to set a password if the config option `password_config.localdb_enabled` is set `false`.
|
||||
> Users' passwords are wiped upon account deactivation, hence the need to set a new one here.
|
||||
> - A user cannot be erased with this API. For more details on
|
||||
> deactivating and erasing users see [Deactivate Account](#deactivate-account).
|
||||
- `locked` - **bool**, optional. If unspecified, locked state will be left unchanged.
|
||||
- `user_type` - **string** or null, optional. If not provided, the user type will be
|
||||
not be changed. If `null` is given, the user type will be cleared.
|
||||
|
|
@ -259,12 +259,15 @@ The following parameters should be set in the URL:
|
|||
Can be provided multiple times. Possible values are `bot`, `support` or "empty string".
|
||||
"empty string" here means to exclude users without a type.
|
||||
- `locked` - string representing a bool - Is optional and if `true` will **include** locked users.
|
||||
Defaults to `false` to exclude locked users. Note: Introduced in v1.93.
|
||||
Defaults to `false` to exclude locked users.
|
||||
> [!NOTE]
|
||||
> Introduced in v1.93.
|
||||
|
||||
Caution. The database only has indexes on the columns `name` and `creation_ts`.
|
||||
This means that if a different sort order is used (`is_guest`, `admin`,
|
||||
`user_type`, `deactivated`, `shadow_banned`, `avatar_url` or `displayname`),
|
||||
this can cause a large load on the database, especially for large environments.
|
||||
> [!CAUTION]
|
||||
> The database only has indexes on the columns `name` and `creation_ts`.
|
||||
> This means that if a different sort order is used (`is_guest`, `admin`,
|
||||
> `user_type`, `deactivated`, `shadow_banned`, `avatar_url` or `displayname`),
|
||||
> this can cause a large load on the database, especially for large environments.
|
||||
|
||||
**Response**
|
||||
|
||||
|
|
@ -285,7 +288,9 @@ The following fields are returned in the JSON response body:
|
|||
- `avatar_url` - string - The user's avatar URL if they have set one.
|
||||
- `creation_ts` - integer - The user's creation timestamp in ms.
|
||||
- `last_seen_ts` - integer - The user's last activity timestamp in ms.
|
||||
- `locked` - bool - Status if that user has been marked as locked. Note: Introduced in v1.93.
|
||||
- `locked` - bool - Status if that user has been marked as locked.
|
||||
> [!NOTE]
|
||||
> Introduced in v1.93.
|
||||
- `next_token`: string representing a positive integer - Indication for pagination. See above.
|
||||
- `total` - integer - Total number of media.
|
||||
|
||||
|
|
@ -443,7 +448,8 @@ To unsuspend a user, use the same endpoint with a body of:
|
|||
|
||||
## Reset password
|
||||
|
||||
**Note:** This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
> [!NOTE]
|
||||
> This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
|
||||
Changes the password of another user. This will automatically log the user out of all their devices.
|
||||
|
||||
|
|
@ -468,7 +474,8 @@ The parameter `logout_devices` is optional and defaults to `true`.
|
|||
|
||||
## Get whether a user is a server administrator or not
|
||||
|
||||
**Note:** This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
> [!NOTE]
|
||||
> This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
|
||||
The api is:
|
||||
|
||||
|
|
@ -487,7 +494,8 @@ A response body like the following is returned:
|
|||
|
||||
## Change whether a user is a server administrator or not
|
||||
|
||||
**Note:** This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
> [!NOTE]
|
||||
> This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
|
||||
Note that you cannot demote yourself.
|
||||
|
||||
|
|
@ -614,8 +622,9 @@ The following should be set as query parameters in the URL:
|
|||
invites sent at or after the provided timestamp will be returned.
|
||||
This works by comparing the provided timestamp to the `received_ts`
|
||||
column in the `events` table.
|
||||
Note: https://currentmillis.com/ is a useful tool for converting dates
|
||||
into timestamps and vice versa.
|
||||
> [!NOTE]
|
||||
> https://currentmillis.com/ is a useful tool for converting dates
|
||||
> into timestamps and vice versa.
|
||||
|
||||
A response body like the following is returned:
|
||||
|
||||
|
|
@ -648,8 +657,9 @@ The following should be set as query parameters in the URL:
|
|||
invites sent at or after the provided timestamp will be returned.
|
||||
This works by comparing the provided timestamp to the `received_ts`
|
||||
column in the `events` table.
|
||||
Note: https://currentmillis.com/ is a useful tool for converting dates
|
||||
into timestamps and vice versa.
|
||||
> [!NOTE]
|
||||
> https://currentmillis.com/ is a useful tool for converting dates
|
||||
> into timestamps and vice versa.
|
||||
|
||||
A response body like the following is returned:
|
||||
|
||||
|
|
@ -836,11 +846,12 @@ The following parameters should be set in the URL:
|
|||
If neither `order_by` nor `dir` is set, the default order is newest media on top
|
||||
(corresponds to `order_by` = `created_ts` and `dir` = `b`).
|
||||
|
||||
Caution. The database only has indexes on the columns `media_id`,
|
||||
`user_id` and `created_ts`. This means that if a different sort order is used
|
||||
(`upload_name`, `last_access_ts`, `media_length`, `media_type`,
|
||||
`quarantined_by` or `safe_from_quarantine`), this can cause a large load on the
|
||||
database, especially for large environments.
|
||||
> [!CAUTION]
|
||||
> The database only has indexes on the columns `media_id`,
|
||||
> `user_id` and `created_ts`. This means that if a different sort order is used
|
||||
> (`upload_name`, `last_access_ts`, `media_length`, `media_type`,
|
||||
> `quarantined_by` or `safe_from_quarantine`), this can cause a large load on the
|
||||
> database, especially for large environments.
|
||||
|
||||
**Response**
|
||||
|
||||
|
|
@ -897,8 +908,9 @@ The following fields are returned in the JSON response body:
|
|||
* `deleted_media`: an array of strings - List of deleted `media_id`
|
||||
* `total`: integer - Total number of deleted `media_id`
|
||||
|
||||
**Note**: There is no `next_token`. This is not useful for deleting media, because
|
||||
after deleting media the remaining media have a new order.
|
||||
> [!NOTE]
|
||||
> There is no `next_token`. This is not useful for deleting media, because
|
||||
> after deleting media the remaining media have a new order.
|
||||
|
||||
**Parameters**
|
||||
|
||||
|
|
@ -909,7 +921,8 @@ delete largest/smallest or newest/oldest files first.
|
|||
|
||||
## Login as a user
|
||||
|
||||
**Note:** This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
> [!NOTE]
|
||||
> This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
|
||||
Get an access token that can be used to authenticate as that user. Useful for
|
||||
when admins wish to do actions on behalf of a user.
|
||||
|
|
@ -940,9 +953,10 @@ tell they have been logged in as.
|
|||
|
||||
To expire the token call the standard `/logout` API with the token.
|
||||
|
||||
Note: The token will expire if the *admin* user calls `/logout/all` from any
|
||||
of their devices, but the token will *not* expire if the target user does the
|
||||
same.
|
||||
> [!NOTE]
|
||||
> The token will expire if the *admin* user calls `/logout/all` from any
|
||||
> of their devices, but the token will *not* expire if the target user does the
|
||||
> same.
|
||||
|
||||
## Allow replacing master cross-signing key without User-Interactive Auth
|
||||
|
||||
|
|
@ -1598,5 +1612,3 @@ The following fields are returned in the JSON response body:
|
|||
the corresponding error that caused the redaction to fail
|
||||
|
||||
_Added in Synapse 1.116.0._
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -63,9 +63,10 @@ file:
|
|||
serve_server_wellknown: true
|
||||
```
|
||||
|
||||
**Note**: this *only* works if `https://<server_name>` is routed to Synapse, so is
|
||||
generally not suitable if Synapse is hosted at a subdomain such as
|
||||
`https://synapse.example.com`.
|
||||
> [!NOTE]
|
||||
> This *only* works if `https://<server_name>` is routed to Synapse, so is
|
||||
> generally not suitable if Synapse is hosted at a subdomain such as
|
||||
> `https://synapse.example.com`.
|
||||
|
||||
## SRV DNS record delegation
|
||||
|
||||
|
|
|
|||
|
|
@ -2,10 +2,11 @@
|
|||
|
||||
Synapse supports extending its functionality by configuring external modules.
|
||||
|
||||
**Note**: When using third-party modules, you effectively allow someone else to run
|
||||
custom code on your Synapse homeserver. Server admins are encouraged to verify the
|
||||
provenance of the modules they use on their homeserver and make sure the modules aren't
|
||||
running malicious code on their instance.
|
||||
> [!NOTE]
|
||||
> When using third-party modules, you effectively allow someone else to run
|
||||
> custom code on your Synapse homeserver. Server admins are encouraged to verify the
|
||||
> provenance of the modules they use on their homeserver and make sure the modules aren't
|
||||
> running malicious code on their instance.
|
||||
|
||||
## Using modules
|
||||
|
||||
|
|
|
|||
|
|
@ -14,10 +14,9 @@ _First introduced in Synapse v1.132.0_
|
|||
async def get_media_config_for_user(user_id: str) -> JsonDict | None
|
||||
```
|
||||
|
||||
**<span style="color:red">
|
||||
Caution: This callback is currently experimental . The method signature or behaviour
|
||||
may change without notice.
|
||||
</span>**
|
||||
> [!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).
|
||||
|
|
@ -44,10 +43,9 @@ _First introduced in Synapse v1.132.0_
|
|||
async def is_user_allowed_to_upload_media_of_size(user_id: str, size: int) -> bool
|
||||
```
|
||||
|
||||
**<span style="color:red">
|
||||
Caution: This callback is currently experimental . The method signature or behaviour
|
||||
may change without notice.
|
||||
</span>**
|
||||
> [!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.
|
||||
|
|
@ -73,10 +71,9 @@ _First introduced in Synapse v1.139.0_
|
|||
async def get_media_upload_limits_for_user(user_id: str, size: int) -> list[synapse.module_api.MediaUploadLimit] | None
|
||||
```
|
||||
|
||||
**<span style="color:red">
|
||||
Caution: This callback is currently experimental. The method signature or behaviour
|
||||
may change without notice.
|
||||
</span>**
|
||||
> [!CAUTION]
|
||||
> This callback is currently experimental. The method signature or behaviour
|
||||
> may change without notice.
|
||||
|
||||
Called when processing a request to store content in the media repository. This can be used to dynamically override
|
||||
the [media upload limits configuration](../usage/configuration/config_documentation.html#media_upload_limits).
|
||||
|
|
@ -108,10 +105,9 @@ _First introduced in Synapse v1.139.0_
|
|||
async def on_media_upload_limit_exceeded(user_id: str, limit: synapse.module_api.MediaUploadLimit, sent_bytes: int, attempted_bytes: int) -> None
|
||||
```
|
||||
|
||||
**<span style="color:red">
|
||||
Caution: This callback is currently experimental. The method signature or behaviour
|
||||
may change without notice.
|
||||
</span>**
|
||||
> [!CAUTION]
|
||||
> This callback is currently experimental. The method signature or behaviour
|
||||
> may change without notice.
|
||||
|
||||
Called when a user attempts to upload media that would exceed a
|
||||
[configured media upload limit](../usage/configuration/config_documentation.html#media_upload_limits).
|
||||
|
|
|
|||
|
|
@ -14,10 +14,9 @@ _First introduced in Synapse v1.132.0_
|
|||
async def get_ratelimit_override_for_user(user: str, limiter_name: str) -> synapse.module_api.RatelimitOverride | None
|
||||
```
|
||||
|
||||
**<span style="color:red">
|
||||
Caution: This callback is currently experimental . The method signature or behaviour
|
||||
may change without notice.
|
||||
</span>**
|
||||
> [!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
|
||||
|
|
|
|||
|
|
@ -164,8 +164,9 @@ await user_may_send_3pid_invite(
|
|||
)
|
||||
```
|
||||
|
||||
**Note**: If the third-party identifier is already associated with a matrix user ID,
|
||||
[`user_may_invite`](#user_may_invite) will be used instead.
|
||||
> [!NOTE]
|
||||
> If the third-party identifier is already associated with a matrix user ID,
|
||||
> [`user_may_invite`](#user_may_invite) will be used instead.
|
||||
|
||||
The callback must return one of:
|
||||
- `synapse.module_api.NOT_SPAM`, to allow the operation. Other callbacks may still
|
||||
|
|
@ -287,10 +288,9 @@ _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"]
|
||||
```
|
||||
|
||||
**<span style="color:red">
|
||||
Caution: This callback is currently experimental . The method signature or behaviour
|
||||
may change without notice.
|
||||
</span>**
|
||||
> [!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.
|
||||
|
||||
|
|
@ -463,7 +463,8 @@ The value of the first callback that does not return `synapse.module_api.NOT_SPA
|
|||
be used. If this happens, Synapse will not call any of the subsequent implementations of
|
||||
this callback.
|
||||
|
||||
*Note:* This will not be called when a user registers.
|
||||
> [!NOTE]
|
||||
> This will not be called when a user registers.
|
||||
|
||||
|
||||
## Example
|
||||
|
|
|
|||
|
|
@ -19,10 +19,9 @@ async def check_event_allowed(
|
|||
) -> tuple[bool, dict | None]
|
||||
```
|
||||
|
||||
**<span style="color:red">
|
||||
This callback is very experimental and can and will break without notice. Module developers
|
||||
are encouraged to implement `check_event_for_spam` from the spam checker category instead.
|
||||
</span>**
|
||||
> [!WARNING]
|
||||
> This callback is very experimental and can and will break without notice. Module developers
|
||||
> are encouraged to implement `check_event_for_spam` from the spam checker category instead.
|
||||
|
||||
Called when processing any incoming event, with the event and a `StateMap`
|
||||
representing the current state of the room the event is being sent into. A `StateMap` is
|
||||
|
|
@ -258,10 +257,9 @@ If multiple modules implement this callback, Synapse runs them all in order.
|
|||
|
||||
_First introduced in Synapse v1.56.0_
|
||||
|
||||
**<span style="color:red">
|
||||
This callback is deprecated in favour of the `on_add_user_third_party_identifier` callback, which
|
||||
features the same functionality. The only difference is in name.
|
||||
</span>**
|
||||
> [!WARNING]
|
||||
> This callback is deprecated in favour of the `on_add_user_third_party_identifier` callback, which
|
||||
> features the same functionality. The only difference is in name.
|
||||
|
||||
```python
|
||||
async def on_threepid_bind(user_id: str, medium: str, address: str) -> None:
|
||||
|
|
|
|||
|
|
@ -190,8 +190,9 @@ oidc_providers:
|
|||
3. Create an application for synapse in Authentik and link it to the provider.
|
||||
4. Note the slug of your application, Client ID and Client Secret.
|
||||
|
||||
Note: RSA keys must be used for signing for Authentik, ECC keys do not work.
|
||||
Note: The provider must have a signing key set and must not use an encryption key.
|
||||
> [!NOTE]
|
||||
> RSA keys must be used for signing for Authentik; ECC keys do not work.
|
||||
> The provider must have a signing key set and must not use an encryption key.
|
||||
|
||||
Synapse config:
|
||||
```yaml
|
||||
|
|
|
|||
|
|
@ -1,8 +1,7 @@
|
|||
<h2 style="color:red">
|
||||
This page of the Synapse documentation is now deprecated. For up to date
|
||||
documentation on setting up or writing a presence router module, please see
|
||||
<a href="modules.md">this page</a>.
|
||||
</h2>
|
||||
> [!WARNING]
|
||||
> This page of the Synapse documentation is now deprecated. For up to date
|
||||
> documentation on setting up or writing a presence router module, please see
|
||||
> [this page](modules.md).
|
||||
|
||||
# Presence Router Module
|
||||
|
||||
|
|
|
|||
|
|
@ -21,9 +21,10 @@ best practices. ⚠️
|
|||
|
||||
## Installing Synapse
|
||||
|
||||
Note: Synapse uses a number of platform dependencies such as Python and PostgreSQL,
|
||||
and aims to follow supported upstream versions. See the [deprecation
|
||||
policy](../deprecation_policy.md) for more details.
|
||||
> [!NOTE]
|
||||
> Synapse uses a number of platform dependencies such as Python and PostgreSQL,
|
||||
> and aims to follow supported upstream versions. See the [deprecation
|
||||
> policy](../deprecation_policy.md) for more details.
|
||||
|
||||
### Prebuilt packages
|
||||
|
||||
|
|
@ -314,8 +315,9 @@ sudo dnf group install "Development Tools"
|
|||
|
||||
##### Red Hat Enterprise Linux / Rocky Linux / Oracle Linux
|
||||
|
||||
*Note: The term "RHEL" below refers to Red Hat Enterprise Linux, Oracle Linux and Rocky Linux.
|
||||
The distributions are 1:1 binary compatible.*
|
||||
> [!NOTE]
|
||||
> The term "RHEL" below refers to Red Hat Enterprise Linux, Oracle Linux and Rocky Linux.
|
||||
> The distributions are 1:1 binary compatible.
|
||||
|
||||
It's recommended to use the latest Python versions.
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,7 @@
|
|||
<h2 style="color:red">
|
||||
This page of the Synapse documentation is now deprecated. For up to date
|
||||
documentation on setting up or writing a spam checker module, please see
|
||||
<a href="modules.md">this page</a>.
|
||||
</h2>
|
||||
> [!WARNING]
|
||||
> This page of the Synapse documentation is now deprecated. For up to date
|
||||
> documentation on setting up or writing a spam checker module, please see
|
||||
> [this page](modules.md).
|
||||
|
||||
# Handling spam in Synapse
|
||||
|
||||
|
|
|
|||
|
|
@ -123,8 +123,10 @@ connection errors.
|
|||
|
||||
The client should keep track of the token in the last RDATA command
|
||||
received for each stream so that on reconnection it can start streaming
|
||||
from the correct place. Note: not all RDATA have valid tokens due to
|
||||
batching. See `RdataCommand` for more details.
|
||||
from the correct place.
|
||||
|
||||
> [!NOTE]
|
||||
> Not all RDATA have valid tokens due to batching. See `RdataCommand` for more details.
|
||||
|
||||
### Example
|
||||
|
||||
|
|
|
|||
|
|
@ -156,8 +156,9 @@ Here are a few things to try:
|
|||
user=username:password
|
||||
```
|
||||
|
||||
**Note**: these settings will not take effect unless `use-auth-secret`
|
||||
and `static-auth-secret` are disabled.
|
||||
> [!NOTE]
|
||||
> These settings will not take effect unless `use-auth-secret`
|
||||
> and `static-auth-secret` are disabled.
|
||||
|
||||
Restart coturn after changing the configuration file.
|
||||
|
||||
|
|
|
|||
|
|
@ -2256,10 +2256,11 @@ default templates, see
|
|||
|
||||
## 3pid verification changes
|
||||
|
||||
**Note: As of this release, users will be unable to add phone numbers or
|
||||
email addresses to their accounts, without changes to the Synapse
|
||||
configuration. This includes adding an email address during
|
||||
registration.**
|
||||
> [!NOTE]
|
||||
> As of this release, users will be unable to add phone numbers or
|
||||
> email addresses to their accounts, without changes to the Synapse
|
||||
> configuration. This includes adding an email address during
|
||||
> registration.
|
||||
|
||||
It is possible for a user to associate an email address or phone number
|
||||
with their account, for a number of reasons:
|
||||
|
|
|
|||
|
|
@ -49,9 +49,11 @@ This API allows pausing background updates.
|
|||
Background updates should *not* be paused for significant periods of time, as
|
||||
this can affect the performance of Synapse.
|
||||
|
||||
*Note*: This won't persist over restarts.
|
||||
> [!NOTE]
|
||||
> This won't persist over restarts.
|
||||
|
||||
*Note*: This won't cancel any update query that is currently running. This is
|
||||
> [!NOTE]
|
||||
> This won't cancel any update query that is currently running. This is
|
||||
usually fine since most queries are short lived, except for `CREATE INDEX`
|
||||
background updates which won't be cancelled once started.
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,8 @@
|
|||
|
||||
This API allows a server administrator to manage Synapse's federation with other homeservers.
|
||||
|
||||
Note: This API is new, experimental and "subject to change".
|
||||
> [!NOTE]
|
||||
> This API is new, experimental and "subject to change".
|
||||
|
||||
## List of destinations
|
||||
|
||||
|
|
@ -62,9 +63,10 @@ The following query parameters are available:
|
|||
- `dir` - Direction of room order. Either `f` for forwards or `b` for backwards. Setting
|
||||
this value to `b` will reverse the above sort order. Defaults to `f`.
|
||||
|
||||
*Caution:* The database only has an index on the column `destination`.
|
||||
This means that if a different sort order is used,
|
||||
this can cause a large load on the database, especially for large environments.
|
||||
> [!CAUTION]
|
||||
> The database only has an index on the column `destination`.
|
||||
> This means that if a different sort order is used,
|
||||
> this can cause a large load on the database, especially for large environments.
|
||||
|
||||
**Response**
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
# Registration Tokens
|
||||
|
||||
**Note:** This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
> [!NOTE]
|
||||
> This API is disabled when MSC3861 is enabled. [See #15582](https://github.com/matrix-org/synapse/pull/15582)
|
||||
|
||||
This API allows you to manage tokens which can be used to authenticate
|
||||
registration requests, as proposed in
|
||||
|
|
|
|||
|
|
@ -255,7 +255,8 @@ line to `/etc/default/matrix-synapse`:
|
|||
|
||||
LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libjemalloc.so.2
|
||||
|
||||
*Note*: You may need to set `PYTHONMALLOC=malloc` to ensure that `jemalloc` can accurately calculate memory usage. By default, Python uses its internal small-object allocator, which may interfere with jemalloc's ability to track memory consumption correctly. This could prevent the [cache_autotuning](../configuration/config_documentation.md#caches) feature from functioning as expected, as the Python allocator may not reach the memory threshold set by `max_cache_memory_usage`, thus not triggering the cache eviction process.
|
||||
> [!NOTE]
|
||||
> You may need to set `PYTHONMALLOC=malloc` to ensure that `jemalloc` can accurately calculate memory usage. By default, Python uses its internal small-object allocator, which may interfere with jemalloc's ability to track memory consumption correctly. This could prevent the [cache_autotuning](../configuration/config_documentation.md#caches) feature from functioning as expected, as the Python allocator may not reach the memory threshold set by `max_cache_memory_usage`, thus not triggering the cache eviction process.
|
||||
|
||||
This made a significant difference on Python 2.7 - it's unclear how
|
||||
much of an improvement it provides on Python 3.x.
|
||||
|
|
|
|||
|
|
@ -20,8 +20,9 @@ So for example, if Synapse were to calculate the active users on the 15th July a
|
|||
A user is **never** considered active if they are either:
|
||||
- Part of the trial day cohort (described below)
|
||||
- Owned by an application service.
|
||||
- Note: This **only** covers users that are part of an application service `namespaces.users` registration. The namespace
|
||||
must also be marked as `exclusive`.
|
||||
> [!NOTE]
|
||||
> This **only** covers users that are part of an application service `namespaces.users` registration. The namespace
|
||||
> must also be marked as `exclusive`.
|
||||
|
||||
Otherwise, any request to Synapse will mark the user as active. Please note that registration will not mark a user as active *unless*
|
||||
they register with a 3pid that is included in the config field `mau_limits_reserved_threepids`.
|
||||
|
|
|
|||
|
|
@ -130,7 +130,8 @@ SELECT e.room_id, r.name, COUNT(e.event_id) cnt
|
|||
```
|
||||
|
||||
## Show top 20 users on homeserver by sent events (messages) at last month:
|
||||
Caution. This query does not use any indexes, can be slow and create load on the database.
|
||||
> [!CAUTION]
|
||||
> This query does not use any indexes, can be slow and create load on the database.
|
||||
```sql
|
||||
SELECT COUNT(*), sender
|
||||
FROM events
|
||||
|
|
|
|||
|
|
@ -96,8 +96,9 @@ The following configuration options, in the `registration` section, are related:
|
|||
it more difficult for them to refresh in time, which may force them to need to
|
||||
re-authenticate using login credentials).
|
||||
|
||||
**Note:** All four options above only apply when tokens are created (by logging in or refreshing).
|
||||
Changes to these settings do not apply retroactively.
|
||||
> [!NOTE]
|
||||
> All four options above only apply when tokens are created (by logging in or refreshing).
|
||||
> Changes to these settings do not apply retroactively.
|
||||
|
||||
|
||||
### Using refresh token expiry to log out inactive sessions
|
||||
|
|
@ -113,9 +114,10 @@ account.
|
|||
`refreshable_access_token_lifetime` and this section assumes that to be the case
|
||||
for simplicity.)
|
||||
|
||||
Note: this will only affect sessions using refresh tokens. You may wish to
|
||||
set a short `nonrefreshable_access_token_lifetime` to prevent this being bypassed
|
||||
by clients that do not support refresh tokens.
|
||||
> [!NOTE]
|
||||
> This will only affect sessions using refresh tokens. You may wish to
|
||||
> set a short `nonrefreshable_access_token_lifetime` to prevent this being bypassed
|
||||
> by clients that do not support refresh tokens.
|
||||
|
||||
|
||||
#### Choosing values that guarantee permitting some inactivity
|
||||
|
|
|
|||
|
|
@ -459,8 +459,9 @@ and be listed in the [`instance_map`](usage/configuration/config_documentation.m
|
|||
config.
|
||||
* Have the main process declared on the [`instance_map`](usage/configuration/config_documentation.md#instance_map) as well.
|
||||
|
||||
Note: The same worker can handle multiple streams, but unless otherwise documented,
|
||||
each stream can only have a single writer.
|
||||
> [!NOTE]
|
||||
> The same worker can handle multiple streams, but unless otherwise documented,
|
||||
> each stream can only have a single writer.
|
||||
|
||||
For example, to move event persistence off to a dedicated worker, the shared
|
||||
configuration would include:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue