Hello all,
I'm trying to create a trigger with API, it's return:
Incorrect item key \"icmpping[187.117.123.107,100, 20, 256, 60]\" provided for trigger expression on \"187.117.123.107\"
resp = self.zapi.trigger.create({
'hostid': 10102,
'description': 'Host 187.117.123.107 PING problem',
'status' : 0,
'type' : 3,
'priority' : 3,
'expression' : '{187.117.123.107:icmpping[187.117.123.107,100, 20, 256, 60].last()}=0'
})
My hostname is same as IP address, 187.117.123.107.
Also created an item associated with this host using API call, it's working.
When I create a new trigger with the same expression in the web interface, it's working fine.
Thanks in advance.
Diego
I'm trying to create a trigger with API, it's return:
Incorrect item key \"icmpping[187.117.123.107,100, 20, 256, 60]\" provided for trigger expression on \"187.117.123.107\"
resp = self.zapi.trigger.create({
'hostid': 10102,
'description': 'Host 187.117.123.107 PING problem',
'status' : 0,
'type' : 3,
'priority' : 3,
'expression' : '{187.117.123.107:icmpping[187.117.123.107,100, 20, 256, 60].last()}=0'
})
My hostname is same as IP address, 187.117.123.107.
Also created an item associated with this host using API call, it's working.
When I create a new trigger with the same expression in the web interface, it's working fine.

Thanks in advance.
Diego
Comment