What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general.

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
More than 500,000 users rely on Paessler PRTG every day. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags


View all Tags

HTTP XML/REST: JSON

Votes:

0

I'm trying to monitor a JSON-output like this:

{ "version": "LinOTP 1.1.1.1", "jsonrpc": "2.0", "result": { "status": true, "value": { "Realms": { "myrealm": { "mygroup": 72 } } } }, "id": 1 } But I'm having some trouble finding the right value for "XML Node (and optional property)". version is working fine -> PRTG value is "LinOTP_1.1.1.1".

But how do I get PRTG to monitor the value 72 in this example? Shouldn't result/status/value/Realms/myrealm/mygroup be the right search filter here ("Node result/status/value/Realms/myrealm/mygroup not found in xml result.")?

json xml xpath

Created on May 13, 2016 1:48:28 PM



3 Replies

Votes:

0

Hi,
please try removing status for your query string:

result/value/Realms/myrealm/mygroup

Then it should work. :)
Best regards

Created on May 13, 2016 2:09:12 PM by  Konstantin Wolff [Paessler Support]



Votes:

0

Upps, you're right. But unfortunately it's still not working: Node result/value/Realms/myrealm/mygroup not found in xml result.

Created on May 13, 2016 2:14:05 PM



Votes:

0

Strange, when using your json this works for me well. Is the provided json the whole content returned by the webserver? (You also can test your query here http://www.jsonquerytool.com/ just switch to XPath for JSON in the dropdown on the upper right)

Created on May 13, 2016 2:19:25 PM by  Konstantin Wolff [Paessler Support]




Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.