Ad Widget

Collapse

API - delete many items

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • hAh0L13
    Junior Member
    • Nov 2018
    • 9

    #1

    API - delete many items

    Hello

    I want to delete a lot of items, created by standart LLD in the "Template OS Windows". How can i do it automatically? I disable LLD rule in the template and the item prototypes in this rule. Now i am trying to get items, based on prototypes, for all hosts using the API (pyzabbix):

    hosts = zapi.do_request('item.get',
    {
    "templateids": "10081",
    "output": "extend",
    "selectItemDiscovery": [
    {
    "itemdiscoveryid": "23163"
    }
    ]
    })

    But it seems that "selectItemDiscovery" does not work. Google can't help me. Maybe anyone can explain my mistake?
Working...