Hello Community -
I've read through previous posts and translated posts and still can not understand where I am going wrong. I've tried different bits and pieces to get a vendor API call (converted to JSON from csv) to LLD correctly and either it goes unsupported or I get random characters added to my item keys which then makes JSONPath not match. My current iteration has an API call through external check to a vendor url - that data is returned as CSV. I've tried converting within the script (PHP) to JSON and also using preprocessing CSVtoJSON within Zabbix (current). So currently after the API call my data looks as such
Now end goal is to have this JSON (which changes based on end points connected to the VPN), to walk the return daily, create a unique key based on "PepVPN_Name" and for every "PepVPN Name" an Item Prototype for "Download, UL, Total". I made a discovery rule (dependent item from php external check) with no preprocessing and one with JSONpath $.[*] - either way runs with no error logs. Both have LLD Macro for {#SPOKENAME} = "PepVPN Name" to use in item prototypes. Testing a "Total" prototype I have unique key[{#SPOKENAME}], preprocessing listed below and using the JSON above i get the correct return value with 'TEST". Yet on the host I get nothing created nor any errors to see what is wrong. I've tried so many permutations that I'm frankly lost as to what to try next.

Any direction is greatly appreciated!
The half working one is same discovery but after it creates the items but they go unsupported with a JSONpath error. From what I can tell the " is my problem which shows up in the unique key[{#SPOKENAME}], yet the display name in the item shows correctly/differently . Nothing ever shows up in host latest data even though items are created/enabled/unsupported.
I've read through previous posts and translated posts and still can not understand where I am going wrong. I've tried different bits and pieces to get a vendor API call (converted to JSON from csv) to LLD correctly and either it goes unsupported or I get random characters added to my item keys which then makes JSONPath not match. My current iteration has an API call through external check to a vendor url - that data is returned as CSV. I've tried converting within the script (PHP) to JSON and also using preprocessing CSVtoJSON within Zabbix (current). So currently after the API call my data looks as such
Code:
[
{
"PepVPN Name": "conn_to_PegaSDXPro-0-1",
"Download (MB)": "21848.00",
"Upload (MB)": "12417.00",
"Total (MB)": "34265.00"
},
{
"PepVPN Name": "conn_to_Peplink20",
"Download (MB)": "1404.00",
"Upload (MB)": "9082.00",
"Total (MB)": "10486.00"
},
{
"PepVPN Name": "conn_to_Peplink13",
"Download (MB)": "2383.00",
"Upload (MB)": "5312.00",
"Total (MB)": "7695.00"
},
{
"PepVPN Name": "conn_to_Peplink15",
"Download (MB)": "904.00",
"Upload (MB)": "1250.00",
"Total (MB)": "2154.00"
},
{
"PepVPN Name": "",
"Download (MB)": "281.00",
"Upload (MB)": "132.00",
"Total (MB)": "413.00"
},
{
"PepVPN Name": "conn_to_Peplink11",
"Download (MB)": "120.00",
"Upload (MB)": "199.00",
"Total (MB)": "319.00"
},
{
"PepVPN Name": "conn_to_Peplink10",
"Download (MB)": "153.00",
"Upload (MB)": "156.00",
"Total (MB)": "309.00"
},
{
"PepVPN Name": "conn_to_Peplink12",
"Download (MB)": "103.00",
"Upload (MB)": "142.00",
"Total (MB)": "245.00"
},
{
"PepVPN Name": "conn_to_Peplink18",
"Download (MB)": "78.00",
"Upload (MB)": "79.00",
"Total (MB)": "157.00"
},
{
"PepVPN Name": "conn_to_PegaFusionHub2",
"Download (MB)": "48.00",
"Upload (MB)": "47.00",
"Total (MB)": "95.00"
}
]
Any direction is greatly appreciated!
The half working one is same discovery but after it creates the items but they go unsupported with a JSONpath error. From what I can tell the " is my problem which shows up in the unique key[{#SPOKENAME}], yet the display name in the item shows correctly/differently . Nothing ever shows up in host latest data even though items are created/enabled/unsupported.
...
Comment