Hello!
I use Zabbix 2.0.3 in my environment and want to get the current problems via Zabbix API using another application (like a watcher), written on Java.
I created a table in my application and trying to populate it with unacknowledged problems and with acknowledged problems using separate queries.
Here are my JSON requests samples:
for unacknowledged problems:
for acknowledged problems:
Unfortunately, both queries returns incorrect values of acknowledgement to me for actual problems. I see that issues with a lowest priority and last changed date about 3 months ago are interpreted as acknowledged, but Zabbix Dashboard show that they're not acknowledged. Also, if i perform acknowledgment for "fresh" issues, Zabbix API does not provide any changes to me.
Is there are anybody who used the schema like that and know how fix this issue? Do I need to use another Zabbix API methods or it is known (and already registered in bugtracker) Zabbix bug?
Also, is anybody know how to get with Zabbix API the latest acknowledgement messages for actual issue?
I use Zabbix 2.0.3 in my environment and want to get the current problems via Zabbix API using another application (like a watcher), written on Java.
I created a table in my application and trying to populate it with unacknowledged problems and with acknowledged problems using separate queries.
Here are my JSON requests samples:
for unacknowledged problems:
Code:
{ "jsonrpc": "2.0",
"method": "trigger.get",
"params": {
"output": [
"triggerid",
"description",
"extend",
"lastchange",
"status",
"priority"
],
"monitored": true,
"expandDescription": 1,
"only_true": true,
"withUnacknowledgedEvents": true,
"hostids": ["10207","10243","10242"]
}, "auth":"3fa96915d9432af7396754df0dc76872", "id":1}
Code:
{ "jsonrpc": "2.0",
"method": "trigger.get",
"params": {
"output": [
"triggerid",
"description",
"extend",
"lastchange",
"status",
"priority"
],
"monitored": true,
"expandDescription": 1,
"only_true": true,
"withAcknowledgedEvents": true,
"hostids": ["10207","10243","10242"]
}, "auth":"3fa96915d9432af7396754df0dc76872", "id":1}
Is there are anybody who used the schema like that and know how fix this issue? Do I need to use another Zabbix API methods or it is known (and already registered in bugtracker) Zabbix bug?
Also, is anybody know how to get with Zabbix API the latest acknowledgement messages for actual issue?

Comment