powersync-docs/docs/api/systeme/configuration.md
Patrick Schurig b26274595c
Some checks failed
Build & Deploy docs / build-deploy (push) Failing after 10m17s
feat: référence API JsonRPC générée depuis introspect.json
- Nouveau générateur scripts/gen_api_reference.py : 19 namespaces →
  docs/api/metier/ (10) + docs/api/systeme/ (9) + notifications.md +
  types.md (96 types · 55 enums · 4 flags) + SUMMARY.md literate-nav
- Badges permissionScope (perm-none/control/configure/admin) dans extra.css
- Guide docs/integrations/jsonrpc-api.md (connexion TCP/WS, auth, conventions énergie)
- mkdocs.yml : Référence API dans la nav, REST→JsonRPC renommé
- mkdocs build --strict : 0 warnings · --check idempotent

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-04 08:15:37 +02:00

796 lines
18 KiB
Markdown

# Configuration
<!-- BEGIN GENERATED: __api_Configuration__ -->
## Méthodes
### Configuration.CreateAndDownloadBackup
<span class="badge perm-admin">ADMIN</span>
Create a backup of the current configuration and generate a download entry for the dedicated transfer connection.
**Paramètres :**
_Aucun paramètre._
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
| `downloadId` | `String` | |
| `fileName` | `String` | |
| `size` | `Int` | |
---
### Configuration.CreateBackup
<span class="badge perm-admin">ADMIN</span>
Create a backup of the current configuration. It will be stored in the configured destination directory. Also the maxCout configuration will be considered.
**Paramètres :**
_Aucun paramètre._
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.DeleteBackupFile
<span class="badge perm-admin">ADMIN</span>
Delete an existing configuration backup file.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `fileName` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.DeleteMqttPolicy
<span class="badge perm-admin">ADMIN</span>
Delete a MQTT policy from the broker.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `clientId` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.DeleteMqttServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Delete a MQTT Server interface of the server.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.DeleteTcpServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Delete a TCP interface of the server. Note: if you are deleting the configuration for the interface you are currently connected to, the connection will be dropped.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.DeleteTunnelProxyServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Delete a Tunnel Proxy Server interface of the server. Note: if you are deleting the configuration for the interface you are currently connected to, the connection will be dropped.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.DeleteWebServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Delete a WebServer interface of the server.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.DeleteWebSocketServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Delete a WebSocket Server interface of the server. Note: if you are deleting the configuration for the interface you are currently connected to, the connection will be dropped.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.DownloadBackupFile
<span class="badge perm-admin">ADMIN</span>
Generate a download entry for an existing configuration backup file.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `fileName` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
| `downloadId` | `String` | optionnel |
| `fileName` | `String` | optionnel |
| `size` | `Int` | optionnel |
---
### Configuration.GetAvailableLanguages
<span class="badge perm-none">PUBLIC</span>
Returns a list of locale codes available for the server. i.e. en_US, de_AT
**Paramètres :**
_Aucun paramètre._
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `languages` | `String`[] | |
---
### Configuration.GetBackupFiles
<span class="badge perm-admin">ADMIN</span>
Get the list of configuration backup files from the configured destination directory.
**Paramètres :**
_Aucun paramètre._
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `backupFiles` | [BackupFile](../types.md#backupfile)[] | |
---
### Configuration.GetConfigurations
<span class="badge perm-none">PUBLIC</span>
Get all configuration parameters of the server.
**Paramètres :**
_Aucun paramètre._
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `backupConfigurations` | `{'autoBackupEnabled': 'Bool', 'autoBackupInterval': 'Int', 'destinationDirectory': 'String', 'maxCount': 'Uint'}` | |
| `basicConfiguration` | `{'d:language': 'String', 'd:location': {'latitude': 'Double', 'longitude': 'Double', 'name': 'String'}, 'd:serverTime': 'Uint', 'd:timeZone': 'String', 'debugServerEnabled': 'Bool', 'serverName': 'String', 'serverUuid': 'Uuid'}` | |
| `mqttServerConfigurations` | [ServerConfiguration](../types.md#serverconfiguration)[] | |
| `tcpServerConfigurations` | [ServerConfiguration](../types.md#serverconfiguration)[] | |
| `tunnelProxyServerConfigurations` | [TunnelProxyServerConfiguration](../types.md#tunnelproxyserverconfiguration)[] | |
| `webServerConfigurations` | [WebServerConfiguration](../types.md#webserverconfiguration)[] | |
| `webSocketServerConfigurations` | [ServerConfiguration](../types.md#serverconfiguration)[] | |
---
### Configuration.GetMqttPolicies
<span class="badge perm-admin">ADMIN</span>
Get all MQTT broker policies.
**Paramètres :**
_Aucun paramètre._
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `mqttPolicies` | [MqttPolicy](../types.md#mqttpolicy)[] | |
---
### Configuration.GetMqttServerConfigurations
<span class="badge perm-admin">ADMIN</span>
Get all MQTT Server configurations.
**Paramètres :**
_Aucun paramètre._
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `mqttServerConfigurations` | [ServerConfiguration](../types.md#serverconfiguration)[] | |
---
### Configuration.GetTimeZones
<span class="badge perm-none">PUBLIC</span>
Get the list of available timezones.
**Paramètres :**
_Aucun paramètre._
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `timeZones` | `String`[] | |
---
### Configuration.RestoreBackupFile
<span class="badge perm-admin">ADMIN</span>
Restore an existing configuration backup file. Clients should warn the user before calling this method because the current configuration data will be wiped, the server will restart immediately afterwards and it will come back up using the restored backup.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `fileName` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetBackupConfiguration
<span class="badge perm-admin">ADMIN</span>
Set the backup configuration. The destination directory is the location where the archives will be saved, the maxCount is the number of backups which will be kept. If maxCount is 0, all backups will be kept. The autoBackupEnabled property controls periodic configuration backups and autoBackupInterval defines the interval in hours.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `autoBackupEnabled` | `Bool` | |
| `autoBackupInterval` | `Int` | |
| `destinationDirectory` | `String` | |
| `maxCount` | `Uint` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetDebugServerEnabled
<span class="badge perm-admin">ADMIN</span>
Enable or disable the debug server.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `enabled` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetLanguage
<span class="badge perm-admin">ADMIN</span>
Sets the server language to the given language. See also: "GetAvailableLanguages"
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `language` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetLocation
<span class="badge perm-admin">ADMIN</span>
Sets the server location.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `location` | `{'latitude': 'Double', 'longitude': 'Double', 'name': 'String'}` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetMqttPolicy
<span class="badge perm-admin">ADMIN</span>
Configure a MQTT broker policy. If the ID is an existing one, the existing policy will be modified, otherwise a new one will be added.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `policy` | [MqttPolicy](../types.md#mqttpolicy) | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetMqttServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Configure a MQTT Server interface on the MQTT broker. If the ID is an existing one, the existing config will be modified, otherwise a new one will be added. Setting authenticationEnabled to true will require MQTT clients to use credentials set in the MQTT broker policies.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configuration` | [ServerConfiguration](../types.md#serverconfiguration) | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetServerName
<span class="badge perm-admin">ADMIN</span>
Set the name of the server. Default is nymea.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `serverName` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetTcpServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Configure a TCP interface of the server. If the ID is an existing one, the existing config will be modified, otherwise a new one will be added. Note: if you are changing the configuration for the interface you are currently connected to, the connection will be dropped.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configuration` | [ServerConfiguration](../types.md#serverconfiguration) | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetTimeZone
<span class="badge perm-admin">ADMIN</span>
Set the time zone of the server. See also: "GetTimeZones"
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `timeZone` | `String` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetTunnelProxyServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Configure a Tunnel Proxy Server interface of the server. If the ID is an existing one, the existing config will be modified, otherwise a new one will be added. Note: if you are changing the configuration for the interface you are currently connected to, the connection will be dropped.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configuration` | [TunnelProxyServerConfiguration](../types.md#tunnelproxyserverconfiguration) | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetWebServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Configure a WebServer interface of the server. If the ID is an existing one, the existing config will be modified, otherwise a new one will be added.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configuration` | [WebServerConfiguration](../types.md#webserverconfiguration) | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.SetWebSocketServerConfiguration
<span class="badge perm-admin">ADMIN</span>
Configure a WebSocket Server interface of the server. If the ID is an existing one, the existing config will be modified, otherwise a new one will be added. Note: if you are changing the configuration for the interface you are currently connected to, the connection will be dropped.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configuration` | [ServerConfiguration](../types.md#serverconfiguration) | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
---
### Configuration.UploadAndRestoreBackup
<span class="badge perm-admin">ADMIN</span>
Create an upload session for a configuration backup archive. The uploaded file will be stored temporarily under /tmp, the current configuration will be wiped after the upload finishes and the server will restart immediately using the restored backup. Clients should warn the user before calling this method because all current configuration data will be lost.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `fileName` | `String` | |
| `size` | `Int` | |
**Retour :**
| Champ | Type | Notes |
| --- | --- | --- |
| `configurationError` | [ConfigurationError](../types.md#configurationerror) | |
| `fileName` | `String` | optionnel |
| `size` | `Int` | optionnel |
| `transferId` | `String` | optionnel |
| `transferToken` | `String` | optionnel |
---
## Notifications
### Configuration.BackupConfigurationChanged
Emitted whenever the backup configuration changes.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `autoBackupEnabled` | `Bool` | |
| `autoBackupInterval` | `Int` | |
| `destinationDirectory` | `String` | |
| `maxCount` | `Uint` | |
---
### Configuration.BackupFilesChanged
Emitted whenever the list of backup files changes.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `backupFiles` | [BackupFile](../types.md#backupfile)[] | |
---
### Configuration.BasicConfigurationChanged
Emitted whenever the basic configuration of this server changes.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `basicConfiguration` | `{'d:language': 'String', 'd:location': {'latitude': 'Double', 'longitude': 'Double', 'name': 'String'}, 'd:serverTime': 'Uint', 'd:timeZone': 'String', 'debugServerEnabled': 'Bool', 'serverName': 'String', 'serverUuid': 'Uuid'}` | |
---
### Configuration.MqttPolicyChanged
Emitted whenever a MQTT broker policy is changed.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `policy` | [MqttPolicy](../types.md#mqttpolicy) | |
---
### Configuration.MqttPolicyRemoved
Emitted whenever a MQTT broker policy is removed.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `clientId` | `String` | |
---
### Configuration.MqttServerConfigurationChanged
Emitted whenever the MQTT broker configuration is changed.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `mqttServerConfiguration` | [ServerConfiguration](../types.md#serverconfiguration) | |
---
### Configuration.MqttServerConfigurationRemoved
Emitted whenever a MQTT server configuration is removed.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
---
### Configuration.TcpServerConfigurationChanged
Emitted whenever the TCP server configuration changes.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `tcpServerConfiguration` | [ServerConfiguration](../types.md#serverconfiguration) | |
---
### Configuration.TcpServerConfigurationRemoved
Emitted whenever a TCP server configuration is removed.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
---
### Configuration.TunnelProxyServerConfigurationChanged
Emitted whenever the tunnel proxy server configuration changes.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `tunnelProxyServerConfiguration` | [TunnelProxyServerConfiguration](../types.md#tunnelproxyserverconfiguration) | |
---
### Configuration.TunnelProxyServerConfigurationRemoved
Emitted whenever a tunnel proxy server configuration is removed.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
---
### Configuration.WebServerConfigurationChanged
Emitted whenever the web server configuration changes.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `webServerConfiguration` | [WebServerConfiguration](../types.md#webserverconfiguration) | |
---
### Configuration.WebServerConfigurationRemoved
Emitted whenever a Web server configuration is removed.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
---
### Configuration.WebSocketServerConfigurationChanged
Emitted whenever the web socket server configuration changes.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `webSocketServerConfiguration` | [ServerConfiguration](../types.md#serverconfiguration) | |
---
### Configuration.WebSocketServerConfigurationRemoved
Emitted whenever a WebSocket server configuration is removed.
**Paramètres :**
| Champ | Type | Notes |
| --- | --- | --- |
| `id` | `String` | |
---
<!-- END GENERATED -->