You are viewing documentation for the development version, it may be incomplete.
Join our translation project and help translate Zabbix documentation into your native language.

29 URL

Description

These parameters and the possible property values for the respective dashboard widget field objects allow to configure the URL widget in dashboard.create and dashboard.update methods.

Widget fields properties are not validated during the creation or update of a dashboard. This allows users to modify built-in widgets and create custom widgets, but also introduces the risk of creating or updating widgets incorrectly. To ensure the successful creation or update of the URL widget, please refer to the parameter behavior outlined in the tables below.

Parameters

The following parameters are supported for the URL widget.

Parameter type name value
Refresh interval 0 rf_rate 0 - (default) No refresh;
10 - 10 seconds;
30 - 30 seconds;
60 - 1 minute;
120 - 2 minutes;
600 - 10 minutes;
900 - 15 minutes.
URL 1 url Valid URL string.

Parameter behavior:
- required
Override host 1 override_hostid._reference ABCDE._hostid - set a compatible widget (with its Reference parameter set to "ABCDE") as the data source for hosts;
DASHBOARD._hostid - set the dashboard Host selector as the data source for hosts.

This parameter is not supported if configuring the widget on a template dashboard.

Examples

The following examples aim to only describe the configuration of the dashboard widget field objects for the URL widget. For more information on configuring a dashboard, see dashboard.create.

Configuring a URL widget

Configure a URL widget that displays the home page of Zabbix manual.

Request:

{
           "jsonrpc": "2.0",
           "method": "dashboard.create",
           "params": {
               "name": "My dashboard",
               "display_period": 30,
               "auto_start": 1,
               "pages": [
                   {
                       "widgets": [
                           {
                               "type": "url",
                               "name": "URL",
                               "x": 0,
                               "y": 0,
                               "width": 36,
                               "height": 5,
                               "view_mode": 0,
                               "fields": [
                                   {
                                       "type": 1,
                                       "name": "url",
                                       "value": "https://www.zabbix.com/documentation/7.2/en"
                                   }
                               ]
                           }
                       ]
                   }
               ],
               "userGroups": [
                   {
                       "usrgrpid": 7,
                       "permission": 2
                   }
               ],
               "users": [
                   {
                       "userid": 1,
                       "permission": 3
                   }
               ]
           },
           "id": 1
       }

Response:

{
           "jsonrpc": "2.0",
           "result": {
               "dashboardids": [
                   "3"
               ]
           },
           "id": 1
       }

See also