2018-08-11 15:50:56 +02:00
|
|
|
# Get global settings
|
|
|
|
|
2020-04-28 20:00:46 +02:00
|
|
|
{generate_api_description(/server_settings:get)}
|
2018-08-11 15:50:56 +02:00
|
|
|
|
|
|
|
## Usage examples
|
|
|
|
|
2018-09-17 16:27:32 +02:00
|
|
|
{start_tabs}
|
|
|
|
{tab|python}
|
2018-08-11 15:50:56 +02:00
|
|
|
|
2018-09-17 16:27:32 +02:00
|
|
|
{generate_code_example(python)|/server_settings:get|example}
|
|
|
|
|
|
|
|
{tab|curl}
|
2018-08-11 15:50:56 +02:00
|
|
|
|
2019-10-14 10:49:30 +02:00
|
|
|
{generate_code_example(curl)|/server_settings:get|example}
|
2018-08-11 15:50:56 +02:00
|
|
|
|
2018-09-17 16:27:32 +02:00
|
|
|
{end_tabs}
|
2018-08-11 15:50:56 +02:00
|
|
|
|
|
|
|
## Arguments
|
|
|
|
|
|
|
|
{generate_api_arguments_table|zulip.yaml|/server_settings:get}
|
|
|
|
|
|
|
|
## Response
|
|
|
|
|
|
|
|
#### Return values
|
|
|
|
|
|
|
|
* `authentication_methods`: object in which each key-value pair in the object
|
|
|
|
indicates whether the authentication method is enabled on this server.
|
|
|
|
* `zulip_version`: the version of Zulip running in the server.
|
2020-04-29 05:55:42 +02:00
|
|
|
* `zulip_feature_level`: an integer indicating what features are
|
2020-04-20 00:57:28 +02:00
|
|
|
available on the server. The feature level increases monotonically;
|
|
|
|
a value of N means the server supports all API features introduced
|
|
|
|
before feature level N. This is designed to provide a simple way
|
2020-04-29 05:55:42 +02:00
|
|
|
for client apps to decide whether the server supports a given
|
|
|
|
feature or API change. See the [changelog](/api/changelog) for
|
|
|
|
details on what each feature level means.
|
2020-04-20 00:57:28 +02:00
|
|
|
|
|
|
|
**Changes**. New in Zulip 2.2. We recommend using an implied value
|
|
|
|
of 0 for Zulip servers that do not send this field.
|
2018-08-11 15:50:56 +02:00
|
|
|
* `push_notifications_enabled`: whether mobile/push notifications are enabled.
|
2019-10-14 10:55:38 +02:00
|
|
|
* `is_incompatible`: whether the Zulip client that has sent a request to
|
|
|
|
this endpoint is deemed incompatible with the server.
|
2018-08-11 15:50:56 +02:00
|
|
|
* `email_auth_enabled`: setting for allowing users authenticate with an
|
|
|
|
email-password combination.
|
|
|
|
* `require_email_format_usernames`: whether usernames should have an
|
|
|
|
email address format. This is important for clients to know whether
|
|
|
|
the validate email address format in a login prompt; this value will
|
|
|
|
be false if the server has
|
|
|
|
[LDAP authentication][ldap-auth]
|
|
|
|
enabled with a username and password combination.
|
|
|
|
* `realm_uri`: the organization's canonical URI.
|
|
|
|
* `realm_name`: the organization's name (for display purposes).
|
2018-08-16 01:26:55 +02:00
|
|
|
* `realm_icon`: the URI of the organization's logo as a square image,
|
|
|
|
used for identifying the organization in small locations in the
|
|
|
|
mobile and desktop apps.
|
2018-08-11 15:50:56 +02:00
|
|
|
* `realm_description`: HTML description of the organization, as configured by
|
|
|
|
the [organization profile](/help/create-your-organization-profile).
|
2019-11-03 23:51:49 +01:00
|
|
|
* `external_authentication_methods`: list of dictionaries describing
|
|
|
|
the available external authentication methods (such as
|
|
|
|
google/github/SAML) enabled for this organization. Each dictionary
|
|
|
|
specifies the name and icon that should be displayed on the login
|
|
|
|
buttons (`display_name` and `display_icon`, where `display_icon` can
|
2019-11-05 00:08:27 +01:00
|
|
|
be `null`, if no icon is to be displayed), the URLs that
|
2019-11-03 23:51:49 +01:00
|
|
|
should be accessed to initiate login/signup using the method
|
|
|
|
(`login_url` and `signup_url`) and `name`, which is a unique,
|
|
|
|
stable, machine-readable name for the authentication method. The
|
|
|
|
list is sorted in the order in which these authentication methods
|
|
|
|
should be displayed.
|
2018-08-11 15:50:56 +02:00
|
|
|
|
2018-09-27 22:35:57 +02:00
|
|
|
[ldap-auth]: https://zulip.readthedocs.io/en/latest/production/authentication-methods.html#ldap-including-active-directory
|
2018-08-11 15:50:56 +02:00
|
|
|
|
|
|
|
Please note that not all of these attributes are guaranteed to appear in a
|
|
|
|
response, for two reasons:
|
|
|
|
|
|
|
|
* This endpoint has evolved over time, so responses from older Zulip servers
|
|
|
|
might be missing some keys (in which case a client should assume the
|
|
|
|
appropriate default).
|
|
|
|
* If a `/server_settings` request is made to the root domain of a
|
|
|
|
multi-subdomain server, like the root domain of zulipchat.com, the settings
|
|
|
|
that are realm-specific are not known and thus not provided.
|
|
|
|
|
|
|
|
#### Example response
|
|
|
|
|
|
|
|
A typical successful JSON response for a single-organization server may look like:
|
|
|
|
|
|
|
|
{generate_code_example|/server_settings:get|fixture(200)}
|