Update notification settings
This endpoint is used to edit the user's global notification settings.
See this endpoint for
per-stream notification settings.
PATCH https://zulip.dioco.io/api/v1/settings/notifications
Usage examples
#!/usr/bin/env python3
import zulip
# Pass the path to your zuliprc file here.
client = zulip.Client(config_file="~/zuliprc")
# Enable push notifications even when online
request = {
'enable_offline_push_notifications': True,
'enable_online_push_notifications': True,
}
result = client.update_notification_settings(request)
print(result)
curl -sSX PATCH https://zulip.dioco.io/api/v1/settings/notifications \
-u BOT_EMAIL_ADDRESS:BOT_API_KEY \
-d 'enable_offline_push_notifications=true' \
-d 'enable_online_push_notifications=true'
Parameters
enable_stream_desktop_notifications optional
Example: True
Enable visual desktop notifications for stream messages.
enable_stream_email_notifications optional
Example: True
Enable email notifications for stream messages.
enable_stream_push_notifications optional
Example: True
Enable mobile notifications for stream messages.
enable_stream_audible_notifications optional
Example: True
Enable audible desktop notifications for stream messages.
notification_sound optional
Example: "ding"
enable_desktop_notifications optional
Example: True
Enable visual desktop notifications for private messages and @-mentions.
enable_sounds optional
Example: True
Enable audible desktop notifications for private messages and
@-mentions.
enable_offline_email_notifications optional
Example: True
Enable email notifications for private messages and @-mentions received
when the user is offline.
enable_offline_push_notifications optional
Example: True
Enable mobile notification for private messages and @-mentions received
when the user is offline.
enable_online_push_notifications optional
Example: True
Enable mobile notification for private messages and @-mentions received
when the user is online.
enable_digest_emails optional
Example: True
Enable digest emails when the user is away.
enable_login_emails optional
Example: True
Enable email notifications for new logins to account.
message_content_in_email_notifications optional
Example: True
Include the message's content in missed messages email notifications.
pm_content_in_desktop_notifications optional
Example: True
Include content of private messages in desktop notifications.
wildcard_mentions_notify optional
Example: True
Whether wildcard mentions (E.g. @all) should send notifications
like a personal mention.
desktop_icon_count_display optional
Example: 1
Unread count summary (appears in desktop sidebar and browser tab)
- 1 - All unreads
- 2 - Private messages and mentions
- 3 - None
realm_name_in_notifications optional
Example: True
Include organization name in subject of missed message emails.
presence_enabled optional
Example: True
Display the presence status to other users when online.
Response
Return values
The server will return the settings that have been changed after the request,
with their new value. Please note that this doesn't necessarily mean that it
will return all the settings passed as parameters in the request, but only
those ones that were different than the already existing setting.
Example response
A typical successful JSON response may look like:
{
"enable_offline_push_notifications": true,
"enable_online_push_notifications": true,
"msg": "",
"result": "success"
}