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

Rest Sensor - follow redirects

Votes:

0

I'm trying to get the REST Sensor to work with Nest, using Postman it works perfectly. I have the Authorisation code and the URL. With PRTG I get "expected status 200 OK but got 401 Unauthorized.". From reading the nest site this is likely to be that PRTG isn't following the redirect URL given back to it for the initial response.

https://developer-api.nest.com/devices/thermostats is the URL Sending either Authorisation settings or a custom header with the Bearer code fails.

https://developers.nest.com/reference/error-messages towards the bottom (under 401) implies Nest are using redirection: https://developers.nest.com/guides/api/how-to-handle-redirects supports this.

Does the REST sensor follow redirects? And is there a way of making this work?

Thanks!

http-xml-rest-value prtg rest

Created on Nov 18, 2018 6:56:56 PM



3 Replies

Votes:

0

As of right now, the sensor is not following redirects, unfortunately. It's successor will, but it will take quite some time until it's finished. I'm afraid that you'll need to use PowerShell and Invoke-WebRequest to query the Nest Thermostat(s) for now.


PRTG Scheduler | PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Nov 19, 2018 11:36:09 AM by  Stephan Linke [Paessler Support]



Votes:

0

Thanks for the clarification.

As a work-around I'm using the curl command in a scheduled task to pull the json file every few minutes and upload that to a local webserver. I'm them querying this with PRTG. Works quite nicely, but not elegantly.

Created on Nov 19, 2018 8:07:01 PM



Votes:

0

Glad you got a workaround going :) If it works and saved you time, elegance doesn't matter :)


PRTG Scheduler | PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Nov 20, 2018 6:21:07 AM by  Stephan Linke [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.