Config

synadm config

Modify synadm’s configuration.

Configuration details are generally always asked interactively. Command line options override the suggested defaults in the prompts.

synadm config [OPTIONS]

Options

-u, --user <user_>

Admin user allowed to access the Synapse admin API’s.

-t, --token <token>

The Admin user’s access token.

-b, --base-url <base_url>

The base URL Synapse is running on. Typically this is https://localhost:8008 or https://localhost:8448. If Synapse is configured to expose its admin API’s to the outside world it might as well be something like this: https://example.org:8448

-p, --admin-path <admin_path>

The path Synapse provides its admin API’s, usually the default fits most installations.

-m, --matrix-path <matrix_path>

The path Synapse provides the regular Matrix API’s, usually the default fits most installations.

-w, --timeout <timeout>

The time in seconds synadm should wait for responses from admin API’s or Matrix API’s. The default is 7 seconds.

-o, --output <output>

How synadm displays data by default. The ‘human’ mode gives a tabular or list view depending on the fetched data, but often needs a lot of horizontal space to display correctly. ‘json’ returns formatted json. ‘minified’ is minified json, suitable for scripting purposes. ‘pprint’ shows a formatted output with the help of Python’s built-in pprint module. ‘yaml’ is a compromise between human- and machine-readable output, it doesn’t need as much terminal width as ‘human’ does and is the default on fresh installations. The

default output format can always be overridden by using the global –output/-o switch (eg ‘synadm -o pprint user list’).

Options:

yaml | json | minified | human | pprint

-d, --server-discovery <server_discovery>

The method used for discovery of “the own homeserver name”. Since none of the currently existing Admin API endpoints provide this information, the federation API among other things is asked for help. If set to “well-known” the URI of the federation API is tried to be fetched via the well-known resource of the configured “Synapse base URL”. If set to “dns” the SRV record of the domain name found in the “Synapse base URL” is used to get that information. Once the federation URI is known, the homeserver name can be retrieved. In case “Synapse base URL” contains “localhost”, it’s assumed that the required federation API is listening on localhost:port already (the “keys” Matrix API endpoint). If that is failing as well, as a last resort solution, the homeserver name can just be saved to the configuration directly via the “homeserver” setting. Note that the fetching of the homeserver name is only executed when a synadm subcommand requires it (eg. like some of the media and user subcommands do), and the “homeserver” directive in the config is set to “auto-retrieval”.

Options:

well-known | dns

-n, --homeserver <homeserver>

Synapse homeserver hostname. Usually matrix.DOMAIN or DOMAIN. The default value ‘auto-retrieval’ will try to discover the name using the method set by –server-discovery.

-i, --ssl-verify

Whether or not SSL certificates should be verified. Set to False to allow self-signed certifcates.

Default:

False