Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-25153

Misleading API error message with host.get

XMLWordPrintable

    • Sprint candidates

      When using the API method host.get and there is an error regarding some parameter (for example "selectGroups") the following error message is returned:

      Invalid parameter "/output": value must be "extend".

      But as you can see in the request data there's no parameter "output":

      {
        "jsonrpc": "2.0",
        "method": "host.get",
        "params": {
          "filter": {
            "hostid": [
              "10336"
            ]
          },
          "selectGroups": "groupid"
        },
        "id": 5
      }

      In fact the error is an invalid value for the parameter "selectGroups". This is misleading and makes it hard to find the cause for such an error.

      Therefore this should be fixed so that the error messages really tell what's wrong. At least they shouldn't mention a wrong cause.

            zabbix.dev Zabbix Development Team
            pu Pascal Uhlmann
            Team C
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: