This is the documentation page for an unsupported version of Zabbix.
Is this not what you were looking for? Switch to the current version or choose one from the drop-down menu.



object drule.update(object/array discoveryRules)

This method allows to update existing discovery rules.


(object/array) Discovery rule properties to be updated.

The druleid property must be defined for each discovery rule, all other properties are optional. Only the passed properties will be updated, all others will remain unchanged.

Additionally to the standard discovery rule properties, the method accepts the following parameters.

Parameter Type Description
dchecks array Discovery checks to replace existing checks.

Return values

(object) Returns an object containing the IDs of the updated discovery rules under the druleids property.


Change the IP range of a discovery rule

Change the IP range of a discovery rule to "".


           "jsonrpc": "2.0",
           "method": "drule.update",
           "params": {
               "druleid": "6",
               "iprange": ""
           "auth": "038e1d7b1735c6a5436ee9eae095879e",
           "id": 1


           "jsonrpc": "2.0",
           "result": {
               "druleids": [
           "id": 1

See also


CDRule::update() in frontends/php/include/classes/api/services/CDRule.php.