adubkov / py-zabbix

Python modules for zabbix.
GNU General Public License v2.0
413 stars 157 forks source link

How use py-zabbix with parameters: filter, search #40

Open Prototype-X opened 8 years ago

Prototype-X commented 8 years ago

The manual is no information. Example request: { "jsonrpc": "2.0", "method": "item.get", "params": { "output": "extend", "hostids": "10084", "search": { "key_": "system" }, "sortfield": "name" }, "auth": "038e1d7b1735c6a5436ee9eae095879e", "id": 1 }

Request: { "jsonrpc": "2.0", "method": "host.get", "params": { "output": "extend", "filter": { "host": [ "Zabbix server", "Linux server" ] } }, "auth": "038e1d7b1735c6a5436ee9eae095879e", "id": 1 }

adubkov commented 8 years ago

You can find plenty examples of py-zabbix in one of my previous projects: zabbixcli I will add more examples in py-zabbix docs later.