[ZBXNEXT-2768] Parameter to expand {ITEM.VALUE} macro for event.get API Created: 2015 Apr 08  Updated: 2017 May 31

Status: Open
Project: ZABBIX FEATURE REQUESTS
Component/s: API (A)
Affects Version/s: 2.2.9, 2.4.4
Fix Version/s: None

Type: Change Request Priority: Major
Reporter: Kodai Terashima Assignee: Unassigned
Resolution: Unresolved Votes: 5
Labels: api, event, macro, trigger
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

event.get API method cannot get its expanded name directly, need to get objectid and get expanded name using trigger.get.

However, trigger.get with expandDescription expands {ITEM.VALUE} same as {ITEM.LASTVALUE}. There is no way to get correct event info from API like frontend events screen.



 Comments   
Comment by Oleksii Zagorskyi [ 2015 Apr 08 ]

See also ZBX-6491

Comment by Oleksii Zagorskyi [ 2016 Apr 05 ]

I've tested, and looks like even after the ZBX-6491 fix, the {ITEM.VALUE} is expanded same as {ITEM.LASTVALUE} using the trigger.get API method.

So current request is still actual.

I feel that the trigger.get method needs an additional parameter which will define how to expand the {ITEM.VALUE} macro.
Because API can be used for both tasks:

  • managing configuration using own frontend - should be expanded as {ITEM.LASTVALUE}
  • displaying current problems - should be expanded as {ITEM.VALUE}

But currently there no way control the macro substitution.

Comment by richlv [ 2017 Apr 22 ]

note that there are two things desired - trigger name expansion for event.get and ITEM.VALUE expansion support. this might have to be split in two feature requests, if not implemented in one go.

Generated at Wed Apr 24 21:09:29 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.