Add a navigation view
POST https://ccextractor.zulipchat.com/api/v1/navigation_views
Adds a new custom left sidebar navigation view configuration
for the current user.
This can be used both to configure built-in navigation views,
or to add new navigation views.
Changes: New in Zulip 11.0 (feature level 390).
Usage examples
#!/usr/bin/env python3
import zulip
# Pass the path to your zuliprc file here.
client = zulip.Client(config_file="~/zuliprc")
# Add a navigation view
request = {
    "fragment": "narrow/is/alerted",
    "is_pinned": True,
    "name": "Alert Word",
}
result = client.call_endpoint(
    url="navigation_views",
    method="POST",
    request=request,
)
print(result)
 
curl -sSX POST https://ccextractor.zulipchat.com/api/v1/navigation_views \
    -u BOT_EMAIL_ADDRESS:BOT_API_KEY \
    --data-urlencode fragment=narrow/is/alerted \
    --data-urlencode is_pinned=true \
    --data-urlencode 'name=Alert Words'
 
 
 
Parameters
    fragment string required  
    
        Example: "narrow/is/alerted"
    
    A unique identifier for the view, used to determine navigation
behavior when clicked.
Clients should use this value to navigate to the corresponding URL hash.
 
    is_pinned boolean required  
    
        Example: true
    
    Determines whether the view appears directly in the sidebar or
is hidden in the "More Views" menu.
- true- Pinned and visible in the sidebar.
- false- Hidden and accessible via the "More Views" menu.
 
    name string | null optional  
    
        Example: "Alert Words"
    
    The user-facing name for custom navigation views. Omit this
field for built-in views.
 
Response
Example response(s)
Changes: As of Zulip 7.0 (feature level 167), if any
parameters sent in the request are not supported by this
endpoint, a successful JSON response will include an
ignored_parameters_unsupported array.
A typical successful JSON response may look like:
{
    "msg": "",
    "result": "success"
}
{
    "code": "BAD_REQUEST",
    "msg": "fragment cannot be blank",
    "result": "error"
}